A function that returns the Horovod rank of the calling process. Returns: An integer scalar with the Horovod rank of the calling process.
(self)
| 224 | return cross_size |
| 225 | |
| 226 | def rank(self): |
| 227 | """A function that returns the Horovod rank of the calling process. |
| 228 | |
| 229 | Returns: |
| 230 | An integer scalar with the Horovod rank of the calling process. |
| 231 | """ |
| 232 | rank = self.MPI_LIB_CTYPES.horovod_rank() |
| 233 | if rank == -1: |
| 234 | raise ValueError( |
| 235 | 'Horovod has not been initialized; use hvd.init().') |
| 236 | return rank |
| 237 | |
| 238 | def local_rank(self): |
| 239 | """A function that returns the local Horovod rank of the calling process, within the |
no outgoing calls