def _split_tensor_name(name):
  """Return tuple (op, port) with the op and int port for the tensor name."""
  op_port = name.split(":", 2)
  if len(op_port) == 1:
    return op_port, 0
  else:
    return op_port[0], int(op_port[1])