Skip to content

Commit 33db826

Browse files
committed
Polish code
test=develop
1 parent 447a680 commit 33db826

File tree

1 file changed

+2
-1
lines changed
  • python/paddle/fluid/layers

1 file changed

+2
-1
lines changed

python/paddle/fluid/layers/nn.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7513,7 +7513,8 @@ def hash(input, hash_size, num_hash=1, name=None):
75137513
out = fluid.layers.hash(input=x, len(word_dict))
75147514
"""
75157515
helper = LayerHelper('hash', **locals())
7516-
out = helper.create_tmp_variable(helper.input_dtype(), stop_gradient=True)
7516+
out = helper.create_variable_for_type_inference(
7517+
helper.input_dtype(), stop_gradient=True)
75177518
helper.append_op(
75187519
type='hash',
75197520
inputs={'X': input},

0 commit comments

Comments
 (0)