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

是否应该用paddle.randint取代random.randint? #68055

Open
Wong4j opened this issue Sep 6, 2024 · 0 comments
Open

是否应该用paddle.randint取代random.randint? #68055

Wong4j opened this issue Sep 6, 2024 · 0 comments
Assignees
Labels
NVIDIA PFCC Paddle Framework Contributor Club,https://github.com/PaddlePaddle/community/tree/master/pfcc status/new-issue 新建 type/bug-report 报bug

Comments

@Wong4j
Copy link
Collaborator

Wong4j commented Sep 6, 2024

bug描述 Describe the Bug

我在使用paddle.vision.transforms.RandomCrop的时候,固定seed,但crop的结果仍然是随机的。发现这是因为 transforms.py中用了random.randint来生成随机数。
一般用户只会记得去设置paddle.seed和np.random.seed,并不知道Layer内部调用了random。所以建议用paddle来生成随机数。

其他补充信息 Additional Supplementary Information

No response

@paddle-bot paddle-bot bot added the PFCC Paddle Framework Contributor Club,https://github.com/PaddlePaddle/community/tree/master/pfcc label Sep 6, 2024
@jeng1220 jeng1220 added the NVIDIA label Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NVIDIA PFCC Paddle Framework Contributor Club,https://github.com/PaddlePaddle/community/tree/master/pfcc status/new-issue 新建 type/bug-report 报bug
Projects
None yet
Development

No branches or pull requests

3 participants