mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2025-10-05 16:48:03 +08:00
[feature]2.2 custom_allreduce support cudagraph recapture (#4307)
* custom_allreduce support cudagraph recapture * delete code * add shut_down/restart default group
This commit is contained in:
@@ -25,6 +25,7 @@ from paddle.distributed.communication.group import Group
|
||||
from fastdeploy.distributed.custom_all_reduce import cuda_wrapper
|
||||
from fastdeploy.model_executor.ops.gpu import (
|
||||
all_reduce,
|
||||
clear_ipc_handles,
|
||||
dispose,
|
||||
get_graph_buffer_ipc_meta,
|
||||
init_custom_all_reduce,
|
||||
@@ -220,6 +221,9 @@ class CustomAllreduce:
|
||||
else:
|
||||
return self.all_reduce(input, input, registered=False)
|
||||
|
||||
def clear_ipc_handles(self):
|
||||
clear_ipc_handles(self._ptr)
|
||||
|
||||
def close(self):
|
||||
if self._ptr:
|
||||
dispose(self._ptr)
|
||||
|
Reference in New Issue
Block a user