mindspore.mint.distributed.is_available
- mindspore.mint.distributed.is_available()[source]
Checks if distributed module is available.
Note
Always returns True because MindSpore always has distributed ability on all platforms.
- Returns
bool, whether this distributed module is available.
- Supported Platforms:
Ascend
Examples
Note
Before running the following examples, you need to configure the communication environment variables.
For Ascend devices, it is recommended to use the msrun startup method without any third-party or configuration file dependencies. Please see the msrun start up for more details.
>>> import mindspore as ms >>> from mindspore.mint.distributed import is_available >>> ms.set_device(device_target="Ascend") >>> is_available()