Skip to content

Conversation

ilia-kats
Copy link
Contributor

Apparently, the torch.Tensor() constructor ignores device contexts, e.g. running

with torch.device("cuda"):
    print(torch.Tensor().device)

still returns cpu.

@ilia-kats
Copy link
Contributor Author

The CI is failing in files that this PR does not touch. Let me know if I should still fix it.

@ordabayevy
Copy link
Member

Thanks for the fix! Could you merge the dev branch that should fix the CI errors.

Apparently, the torch.Tensor() constructor ignores device contexts
@ordabayevy ordabayevy merged commit ff6ae1c into pyro-ppl:dev Oct 24, 2024
9 checks passed
ilia-kats added a commit to bioFAM/mofaflex that referenced this pull request May 26, 2025
Fixes training on GPU with AnnData dicts where a view has nonidentical
genes for different groups. See pyro-ppl/pyro#3405
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants