Skip to content

Commit

Permalink
Merge pull request #16449 from panyx0718/imperative3
Browse files Browse the repository at this point in the history
fix imperative varbase creation
  • Loading branch information
panyx0718 authored Mar 26, 2019
2 parents 85e1cc1 + becf799 commit 0fff666
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/paddle/fluid/framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,8 +403,8 @@ def __init__(self,
self._ivar = core.VarBase(
name, dtype if dtype else core.VarDesc.VarType.FP32,
list(shape) if shape else [],
_current_expected_place(), True
if persistable else False, stop_gradient)
_current_expected_place(), stop_gradient, True
if persistable else False)
if persistable:
_imperative_tracer().trace_var(name, self)
else:
Expand Down

0 comments on commit 0fff666

Please sign in to comment.