Skip to content

Commit 1ad81e1

Browse files
committed
fix the comment of less_than
test=develop test=document_preview
1 parent 32a594d commit 1ad81e1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

python/paddle/fluid/layers/control_flow.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -953,7 +953,9 @@ def less_than(x, y, force_cpu=None, cond=None):
953953
Examples:
954954
.. code-block:: python
955955
956-
out = fluid.layers.less_than(x=label, y=limit)
956+
label = fluid.layers.data(name='y', shape=[1], dtype='int64')
957+
limit = fluid.layers.fill_constant(shape=[1], dtype='int64', value=5)
958+
cond = fluid.layers.less_than(x=label, y=limit)
957959
"""
958960
helper = LayerHelper("less_than", **locals())
959961
if cond is None:

0 commit comments

Comments
 (0)