mindspore.ops.communication.isend =================================== .. image:: https://mindspore-website.obs.cn-north-4.myhuaweicloud.com/website-images/master/resource/_static/logo_source.svg :target: https://atomgit.com/mindspore/mindspore/blob/master/docs/api/api_python/ops/mindspore.ops.communication.isend.rst :alt: 查看源文件 .. py:function:: mindspore.ops.communication.isend(tensor, dst=0, group=None, tag=0) 异步将张量发送到指定的目标rank。 .. note:: 当前仅支持PyNative模式,不支持Graph模式。 参数: - **tensor** (Tensor) - 要发送的张量。 - **dst** (int, 可选) - 标识目标rank(全局rank)的整数。默认值: ``0``。 - **group** (str,可选) - 通信组名称。默认值: ``None`` ,即Ascend平台表示为 ``"hccl_world_group"`` 。 - **tag** (int, 可选) - 标识发送/接收消息标签的整数。消息将被具有相同 `tag` 的Receive操作接收。默认值: ``0``。当前为预留参数。 返回: CommHandle,它是一个异步工作句柄。 异常: - **TypeError** - `tensor` 不是Tensor,`dst` 不是int或 `group` 不是str。 - **ValueError** - 如果 `dst` 进程rank id与当前进程相同。 样例: .. note:: .. include:: ../mint/mindspore.mint.comm_note.txt 该样例需要在2卡环境下运行。