Skip to content

Conversation

@smallv0221
Copy link
Contributor

PR types

Bug fixes

PR changes

APIs

Describe

Fix dropout static when axis != None

@paddle-bot-old
Copy link

Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.


#get mask shape
input_shape = x.shape
input_shape_tensor = paddle.shape(x)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

为了减小对性能的影响,是否区分动静态图呢

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

是说动态图的时候可以少走一个op是么

x=input, p=0.7, axis=1, training=True, mode='upscale_in_train')

in_np = np.ones([40, 40]).astype("float32")
in_np2 = np.ones([1, 250000000]).astype("float32")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

因为这个指定axis的分支不会走dropout op,感觉加的单测不用和去dropout OP比较,能跑下来就行,这个大size的单测可能会带来其他问题

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@guoshengCS guoshengCS merged commit f25fda3 into PaddlePaddle:develop Nov 26, 2021
smallv0221 added a commit to smallv0221/Paddle that referenced this pull request Nov 26, 2021
* fix dropout static when axis != None * update dropout test * add dropout test * fix test * Update test_dropout_op.py * Update test_dropout_op.py * fix testcase * fix testcase * Update test_dropout_op.py * fix testcase * fix testcase * optimize perf * add new test * fix testcase
XiaoguangHu01 pushed a commit that referenced this pull request Nov 29, 2021
* fix dropout static when axis != None * update dropout test * add dropout test * fix test * Update test_dropout_op.py * Update test_dropout_op.py * fix testcase * fix testcase * Update test_dropout_op.py * fix testcase * fix testcase * optimize perf * add new test * fix testcase
Zjq9409 pushed a commit to Zjq9409/Paddle that referenced this pull request Dec 10, 2021
* fix dropout static when axis != None * update dropout test * add dropout test * fix test * Update test_dropout_op.py * Update test_dropout_op.py * fix testcase * fix testcase * Update test_dropout_op.py * fix testcase * fix testcase * optimize perf * add new test * fix testcase
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants