parameters: (sgv, control_outputs)
docstring: Detach all the external control outputs of the subgraph sgv.
  
    Args:
      sgv: the subgraph view to be detached. This argument is converted to a
        subgraph using the same rules as the function subgraph.make_view.
      control_outputs: a util.ControlOutputs instance.
docstring_summary: Detach all the external control outputs of the subgraph sgv.
docstring_tokens: Detach all the external control outputs of the subgraph sgv .
function: def detach_control_outputs(sgv, control_outputs):
    """Detach all the external control outputs of the subgraph sgv.
  
    Args:
      sgv: the subgraph view to be detached. This argument is converted to a
        subgraph using the same rules as the function subgraph.make_view.
      control_outputs: a util.ControlOutputs instance.
    """
    if not isinstance(control_outputs, util.ControlOutputs):
      raise TypeError("Expected a util.ControlOutputs, got: {}",
                      type(control_outputs))
    control_outputs.update()
    sgv = subgraph.make_view(sgv)
    for op in sgv.ops:
      for cop in control_outputs.get(op):
        if cop not in sgv.ops:
          reroute.remove_control_inputs(cop, op)
function_tokens: def detach_control_outputs ( sgv , control_outputs ) : if not isinstance ( control_outputs , util . ControlOutputs ) : raise TypeError ( "Expected a util.ControlOutputs, got: {}" , type ( control_outputs ) ) control_outputs . update ( ) sgv = subgraph . make_view ( sgv ) for op in sgv . ops : for cop in control_outputs . get ( op ) : if cop not in sgv . ops : reroute . remove_control_inputs ( cop , op )