Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

【PaddlePaddle Hackathon】1、在 Paddle 中新增 AdaptiveLogSoftmaxWithLoss #37024

Closed
wants to merge 12 commits into from

Conversation

gsq7474741
Copy link
Contributor

PR types

New features

PR changes

APIs

Describe

@paddle-bot-old
Copy link

paddle-bot-old bot commented Nov 7, 2021

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

@gsq7474741
Copy link
Contributor Author

@TCChenlong

@TCChenlong TCChenlong requested a review from zhiboniu November 8, 2021 01:06
@gsq7474741
Copy link
Contributor Author

@zhiboniu 您好,请问iscan的报错怎么看呀,点进ditails看不到

@gsq7474741
Copy link
Contributor Author

@zhiboniu 已更新

@gsq7474741 gsq7474741 requested a review from zhiboniu November 14, 2021 05:14
@gsq7474741 gsq7474741 requested a review from zhiboniu November 19, 2021 02:11
class TestNNAdaptiveLogSoftmaxWithLossAPI(unittest.TestCase):
def setUp(self):
paddle.disable_static()
paddle.seed(10)
Copy link
Contributor

@zhiboniu zhiboniu Nov 29, 2021

Choose a reason for hiding this comment

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

把seed去掉random就不会挂了

Copy link
Contributor Author

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.

@zhiboniu 已更新

@paddle-bot-old
Copy link

paddle-bot-old bot commented Dec 7, 2021

Sorry to inform you that c934522's CIs have passed for more than 7 days. To prevent PR conflicts, you need to re-run all CIs manually.

@gsq7474741 gsq7474741 requested a review from zhiboniu December 8, 2021 09:47
# argmax outside of shortlist
asfm = nn.AdaptiveLogSoftmaxWithLoss(
8, 10, [4, 8], div_value=2., head_bias=True)
asfm.head.weight.detach().abs()
Copy link
Contributor

@zhiboniu zhiboniu Dec 10, 2021

Choose a reason for hiding this comment

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

参考上面两个对话,你当前还是没有能验证实现的正确性。
以test_linear.py为例,可以按如下步骤完成:
1)固定可学习参数权重值为1。
2)获得模型推理结果概率分布,不仅仅是argmax值。
3)使用numpy实现推理公式。
4)使用同一个随机输入验证paddle输出概率分布与numpy计算结果相同。

@paddle-bot-old paddle-bot-old bot added the contributor External developers label Sep 1, 2022
@paddle-bot-old paddle-bot-old bot closed this Jan 11, 2023
@paddle-bot
Copy link

paddle-bot bot commented Jan 11, 2023

很抱歉,经过我们的反复讨论,你的PR暂未达到合入标准,请阅读飞桨原生算子开发规范,你可以重新提交新的PR,我们先将此PR关闭,感谢你的贡献。
Sorry to inform you that through our discussion, your PR fails to meet the merging standard (Reference: Paddle Custom Operator Design Doc). You can also submit an new one. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants