parameters: (self, op_fetches)
return_statement: return fetches
docstring: Check that op_fetches have valid ops.
docstring_summary: Check that op_fetches have valid ops.
docstring_tokens: Check that op_fetches have valid ops .
function: def _process_op_fetches(self, op_fetches):
      """Check that op_fetches have valid ops."""
      if op_fetches is None:
        return []
  
      if not isinstance(op_fetches, (list, tuple)):
        op_fetches = [op_fetches]
  
      fetches = []
      for fetch in op_fetches:
        if isinstance(fetch, ops.Operation):
          fetches.append(fetch)
        elif isinstance(fetch, ops.Tensor):
          fetches.append(fetch.op)
        else:
          logging.warning('Ignoring the given op_fetch:%s, which is not an op.' %
                          fetch)
      return fetches
function_tokens: def _process_op_fetches ( self , op_fetches ) : if op_fetches is None : return [ ] if not isinstance ( op_fetches , ( list , tuple ) ) : op_fetches = [ op_fetches ] fetches = [ ] for fetch in op_fetches : if isinstance ( fetch , ops . Operation ) : fetches . append ( fetch ) elif isinstance ( fetch , ops . Tensor ) : fetches . append ( fetch . op ) else : logging . warning ( 'Ignoring the given op_fetch:%s, which is not an op.' % fetch ) return fetches