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

[BUG] - Tutorials should use modern syntax/coding style - torch.rand #2338

Closed
svekars opened this issue May 23, 2023 · 6 comments · Fixed by #2458
Closed

[BUG] - Tutorials should use modern syntax/coding style - torch.rand #2338

svekars opened this issue May 23, 2023 · 6 comments · Fixed by #2458
Assignees
Labels
bug docathon-h1-2023 A label for the docathon in H1 2023 easy

Comments

@svekars
Copy link
Contributor

svekars commented May 23, 2023

Add Link

Multiple links - see below.

Describe the bug

For example: You should use torch.rand(device='cuda') instead of torch.rand(device=torch.device('cuda'))

Instances of this issue:

Describe your environment

  • PyTorch 2.0
@svekars svekars added the bug label May 23, 2023
@malfet
Copy link
Contributor

malfet commented May 23, 2023

Another good idea: promote use of torch.set_default_device in tutorials, instead of global device variable, which seems to be a common pattern.

@svekars svekars added easy docathon-h1-2023 A label for the docathon in H1 2023 labels May 31, 2023
@onurtore
Copy link
Contributor

/assigntome

@Killpit
Copy link

Killpit commented Jun 6, 2023

/assigntome

@github-actions
Copy link

github-actions bot commented Jun 6, 2023

The issue is already assigned. Please pick an opened and unnasigned issue with the docathon-h1-2023 label.

@svekars
Copy link
Contributor Author

svekars commented Jun 8, 2023

@onurtore are you planing to work on this issue or should we reassign?

@onurtore
Copy link
Contributor

onurtore commented Jun 8, 2023

@onurtore are you planing to work on this issue or should we reassign?

Hello,
I am working on it.

@onurtore onurtore mentioned this issue Jun 10, 2023
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug docathon-h1-2023 A label for the docathon in H1 2023 easy
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants