parameters: (self,
                 sgv,
                 dst_graph,
                 dst_scope,
                 src_scope="",
                 reuse_dst_scope=False)
return_statement: return sgv_, res_info
docstring: Execute the transformation.
  
      Args:
        sgv: the source subgraph-view.
        dst_graph: the destination graph.
        dst_scope: the destination scope.
        src_scope: the source scope, which specify the path from which the
          relative path of the transformed nodes are computed. For instance, if
          src_scope is a/ and dst_scoped is b/, then the node a/x/y will have a
          relative path of x/y and will be transformed into b/x/y.
        reuse_dst_scope: if True the dst_scope is re-used if it already exists.
          Otherwise, the scope is given a unique name based on the one given
          by appending an underscore followed by a digit (default).
      Returns:
        A tuple `(sgv, info)` where:
          `sgv` is the transformed subgraph view;
          `info` is an instance of Transformer.ResultInfo containing
          information about the transform, including mapping between
          original and transformed tensors and operations.
      Raises:
        ValueError: if the arguments are invalid.
docstring_summary: Execute the transformation.
docstring_tokens: Execute the transformation .
function: def __call__(self,
                 sgv,
                 dst_graph,
                 dst_scope,
                 src_scope="",
                 reuse_dst_scope=False):
      """Execute the transformation.
  
      Args:
        sgv: the source subgraph-view.
        dst_graph: the destination graph.
        dst_scope: the destination scope.
        src_scope: the source scope, which specify the path from which the
          relative path of the transformed nodes are computed. For instance, if
          src_scope is a/ and dst_scoped is b/, then the node a/x/y will have a
          relative path of x/y and will be transformed into b/x/y.
        reuse_dst_scope: if True the dst_scope is re-used if it already exists.
          Otherwise, the scope is given a unique name based on the one given
          by appending an underscore followed by a digit (default).
      Returns:
        A tuple `(sgv, info)` where:
          `sgv` is the transformed subgraph view;
          `info` is an instance of Transformer.ResultInfo containing
          information about the transform, including mapping between
          original and transformed tensors and operations.
      Raises:
        ValueError: if the arguments are invalid.
      """
      sgv = subgraph.make_view(sgv)
      if not isinstance(dst_graph, tf_ops.Graph):
        raise TypeError("Expected a tf.Graph, got: {}".format(type(dst_graph)))
  
      src_scope = util.scope_finalize(src_scope)
      dst_scope = util.scope_finalize(dst_scope)
  
      # Potentially create new scope if reuse_dst_scope is False
      if dst_scope and not reuse_dst_scope:
        dst_scope = util.scope_finalize(dst_graph.unique_name(dst_scope[:-1]))
  
      # Create temporary info used during this transform call
      self._info = Transformer._Info(self, sgv, dst_graph, dst_scope, src_scope)
  
      # Transform the graph starting from the output tensors.
      for output_t in self._info.sgv.outputs:
        self._transform_t(output_t)
  
      # Some ops might have been missed by the previous walk, namely, the roots
      # without any outputs. So the walk is now finalized from those roots.
      remaining_ops = [op for op in self._info.sgv.ops
                       if op not in self._info.transformed_ops]
      remaining_roots = [
          op for op in remaining_ops
          if not op.outputs and not self._info.control_outputs.get(op)
      ]
      for op in remaining_roots:
        self._transform_op(op)
  
      sgv_ = self._transform_sgv(sgv)
  
      res_info = Transformer.ResultInfo(self._info)
      self._info = None
      return sgv_, res_info
function_tokens: def __call__ ( self , sgv , dst_graph , dst_scope , src_scope = "" , reuse_dst_scope = False ) : sgv = subgraph . make_view ( sgv ) if not isinstance ( dst_graph , tf_ops . Graph ) : raise TypeError ( "Expected a tf.Graph, got: {}" . format ( type ( dst_graph ) ) ) src_scope = util . scope_finalize ( src_scope ) dst_scope = util . scope_finalize ( dst_scope ) # Potentially create new scope if reuse_dst_scope is False if dst_scope and not reuse_dst_scope : dst_scope = util . scope_finalize ( dst_graph . unique_name ( dst_scope [ : - 1 ] ) ) # Create temporary info used during this transform call self . _info = Transformer . _Info ( self , sgv , dst_graph , dst_scope , src_scope ) # Transform the graph starting from the output tensors. for output_t in self . _info . sgv . outputs : self . _transform_t ( output_t ) # Some ops might have been missed by the previous walk, namely, the roots # without any outputs. So the walk is now finalized from those roots. remaining_ops = [ op for op in self . _info . sgv . ops if op not in self . _info . transformed_ops ] remaining_roots = [ op for op in remaining_ops if not op . outputs and not self . _info . control_outputs . get ( op ) ] for op in remaining_roots : self . _transform_op ( op ) sgv_ = self . _transform_sgv ( sgv ) res_info = Transformer . ResultInfo ( self . _info ) self . _info = None return sgv_ , res_info