diff --git a/python/paddle/fluid/layers/nn.py b/python/paddle/fluid/layers/nn.py index adde9cbd19ffa1a74090b71434a45fa663a39c3b..760f5ce58bf268919667db1c0623ce2096d2bdae 100755 --- a/python/paddle/fluid/layers/nn.py +++ b/python/paddle/fluid/layers/nn.py @@ -8311,7 +8311,7 @@ def gather(input, index, overwrite=True): output = fluid.layers.gather(x, index) """ if in_dygraph_mode(): - return core.ops.gather(input, index, None) + return core.ops.gather(input, index, None, 'overwrite', overwrite) check_variable_and_dtype( input, 'x',