class_docstr: Describes a set of TPU devices.
  
  Represents both the shape of the physical mesh, and the mapping between
  TensorFlow TPU devices to physical mesh coordinates.
class_docstr_tok: ["Describes","a","set","of","TPU","devices",".","Represents","both","the","shape","of","the","physical","mesh",",","and","the","mapping","between","TensorFlow","TPU","devices","to","physical","mesh","coordinates","."]
docstr: Returns the number of TensorFlow tasks in the TPU slice.
docstr_tok: ["Returns","the","number","of","TensorFlow","tasks","in","the","TPU","slice","."]
code: def num_tasks(self):
      """Returns the number of TensorFlow tasks in the TPU slice."""
      return self._device_coordinates.shape[0]
  
imports: import numpy
  from tensorflow.core.protobuf.tpu import topology_pb2
  from tensorflow.python.util.tf_export import tf_export
label_desc: Use image node_id 12 for calling the Topology obj's underlying member method code with example usage: obj.num_tasks() and returns: self