diff --git a/python/paddle/tensor/math.py b/python/paddle/tensor/math.py index 4ac434eb2c2fa7fcd2dd1981ff03ccc523106393..ed2bbe03a366054dfe7d798310c7fa5d419b44a8 100755 --- a/python/paddle/tensor/math.py +++ b/python/paddle/tensor/math.py @@ -1616,7 +1616,7 @@ def clip(x, min=None, max=None, name=None): helper = LayerHelper('clip', **locals()) output = helper.create_variable_for_type_inference( - dtype=helper.input_dtype()) + dtype=helper.input_dtype('x')) helper.append_op( type='clip', inputs=inputs, outputs={'Out': [output]}, attrs=attrs)