未验证 提交 b5ec9ca0 编写于 作者: A Allen Guo 提交者: GitHub

upgrade to sdk2.5.1 (#42950)

* upgrade to sdk2.5.1
上级 d4cdfa55
......@@ -74,11 +74,7 @@ void IpuBackend::WeightsToHost() { executor_->WeightsToHost(); }
void IpuBackend::Detach() { executor_->Detach(); }
void IpuBackend::Reset() {
executor_->Detach();
compiler_.reset();
executor_.reset();
}
void IpuBackend::Reset() { executor_->Reset(); }
void IpuBackend::SetScope(const framework::Scope& scope) {
scope_ = &scope;
......
......@@ -88,11 +88,7 @@ class PdIArray final : public popart::IArray {
} // namespace
Executor::~Executor() {
Detach();
session_.reset();
executor_resources_.reset();
}
Executor::~Executor() { Reset(); }
void Executor::Prepare(const std::string &proto) {
VLOG(10) << "enter Executor::Prepare";
......@@ -299,6 +295,12 @@ void Executor::Detach() {
}
}
void Executor::Reset() {
Detach();
session_.reset();
executor_resources_.reset();
}
void Executor::SetWeightsIO() {
auto opt_type = compiler_resources_->optimizer_type;
VLOG(10) << "SetWeightsIO for " << opt_type;
......
......@@ -63,6 +63,9 @@ class Executor {
// Detach IPU
void Detach();
// Reset session
void Reset();
// Scope
void SetScope(const Scope *scope) { scope_ = scope; }
......
......@@ -128,6 +128,11 @@ class IPUOpTest(IPUTest):
cls.fetch_list: List[str] = None
cls.output_dict: Optional[Dict] = {}
def tearDown(self):
# Manual reset when using ipumodel
if self.use_ipumodel():
paddle.framework.core.IpuBackend.get_instance().reset()
@property
def fp16_enabled(self):
return True
......
......@@ -6,7 +6,7 @@
# run a container
# docker run --ulimit memlock=-1:-1 --net=host --cap-add=IPC_LOCK --device=/dev/infiniband/ --ipc=host --rm -it paddlepaddle/paddle:latest-dev-ipu bash
FROM graphcore/poplar-extbaidu:2.5.0-ubuntu-18.04-20220407
FROM graphcore/poplar:2.5.1
MAINTAINER PaddlePaddle Authors <paddle-dev@baidu.com>
# ENV variables
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册