diff --git a/python/paddle/incubate/hapi/text/text.py b/python/paddle/incubate/hapi/text/text.py index c5cd4ae56328697d7a5b78aa556c7a1dc21a87b7..1424ce0381ac22e3fc15db854e653e0c2632cf22 100644 --- a/python/paddle/incubate/hapi/text/text.py +++ b/python/paddle/incubate/hapi/text/text.py @@ -254,7 +254,8 @@ class BasicLSTMCell(RNNCell): # TODO(guosheng): find better way to resolve constants in __init__ self._forget_bias = layers.create_global_var( shape=[1], dtype=dtype, value=forget_bias, persistable=True) - self._forget_bias.stop_gradient = True + # TODO(guosheng): refine this if recurrent_op removes gradient require + self._forget_bias.stop_gradient = False self._dtype = dtype self._input_size = input_size