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

Tutorial 11 : Runtime error in train_flow function #54

Closed
sy-eng opened this issue Aug 30, 2022 · 2 comments
Closed

Tutorial 11 : Runtime error in train_flow function #54

sy-eng opened this issue Aug 30, 2022 · 2 comments

Comments

@sy-eng
Copy link

sy-eng commented Aug 30, 2022

Thank you for your great tutorials!

I tried tutorial 11 on my laptop (it has no gpu.)
and I got a runtime error in train_flow function.
Its error message said map_location in torch.load should be set.
So I modified
ckpt = torch.load(pretrained_filename)
to
ckpt = torch.load(pretrained_filename, map_location=device).

I guess this modification is good for PCs without gpu.

Thank you.

@phlippe
Copy link
Owner

phlippe commented Aug 30, 2022

Hi @sy-eng, thanks for pointing this out and already preparing the solution! The new commit should now support loading the NFs on CPU. Thanks!

@phlippe phlippe closed this as completed Aug 30, 2022
@sy-eng
Copy link
Author

sy-eng commented Aug 30, 2022

Thank you!

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

No branches or pull requests

2 participants