From 07ee40c6e9496025b695721833575addc1e5ff26 Mon Sep 17 00:00:00 2001 From: dzhwinter Date: Tue, 19 Feb 2019 11:22:04 +0800 Subject: [PATCH] fix default value. test=develop --- python/paddle/fluid/compiler.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/paddle/fluid/compiler.py b/python/paddle/fluid/compiler.py index b24cec044..403ceda87 100644 --- a/python/paddle/fluid/compiler.py +++ b/python/paddle/fluid/compiler.py @@ -178,9 +178,9 @@ class CompiledProgram(object): # FIXME(dzhwinter): enable_inplace should be after memory_optimize # if turn on python memory optimize, turn off the inplace_pass. if self._build_strategy.memory_optimize is None: - self._build_strategy.memory_optimize = False if main._is_mem_optimized else True + self._build_strategy.memory_optimize = False if self._program._is_mem_optimized else True if self._build_strategy.enable_inplace is None: - self._build_strategy.enable_inplace = False if main._is_mem_optimized else True + self._build_strategy.enable_inplace = False if self._program._is_mem_optimized else True if self._build_strategy.num_trainers > 1 and trainers_endpoints: assert self._build_strategy.num_trainers == len( -- GitLab