From d2ba20bdbc8d2a489fcda754dca436ab36b623d8 Mon Sep 17 00:00:00 2001 From: anzhengqi Date: Wed, 9 Sep 2020 20:54:53 +0800 Subject: [PATCH] continue to send remain data when release gpu resource --- mindspore/ccsrc/runtime/device/gpu/gpu_buffer_mgr.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/mindspore/ccsrc/runtime/device/gpu/gpu_buffer_mgr.cc b/mindspore/ccsrc/runtime/device/gpu/gpu_buffer_mgr.cc index ba3578a0b..b03882695 100644 --- a/mindspore/ccsrc/runtime/device/gpu/gpu_buffer_mgr.cc +++ b/mindspore/ccsrc/runtime/device/gpu/gpu_buffer_mgr.cc @@ -19,6 +19,10 @@ #include #include "utils/log_adapter.h" #include "utils/ms_utils.h" +#include "pybind11/pybind11.h" +#include "pybind11/stl.h" + +namespace py = pybind11; namespace mindspore { namespace device { @@ -167,6 +171,7 @@ inline bool GpuBufferMgr::isCreated(unsigned int device_id, const std::string &c } bool GpuBufferMgr::CloseNotify() { + py::gil_scoped_release release; bool result = true; // lock scope { -- GitLab