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

Error when tracking ParameterBeam through segment that is on CPU? #68

Closed
jank324 opened this issue Sep 8, 2023 · 2 comments · Fixed by #69
Closed

Error when tracking ParameterBeam through segment that is on CPU? #68

jank324 opened this issue Sep 8, 2023 · 2 comments · Fixed by #69
Labels
bug Something isn't working question Further information is requested

Comments

@jank324
Copy link
Member

jank324 commented Sep 8, 2023

I found this in the ParameterBeam part of the Element.__call__ function:

if self.device != "cpu":
    raise DeviceError

I think this doesn't make any sense (though I'm not sure). We should look into this at some point.

@jank324 jank324 added bug Something isn't working question Further information is requested labels Sep 8, 2023
@jank324
Copy link
Member Author

jank324 commented Sep 8, 2023

Also ... this is checked after the actual calculations, which would have thrown an error about device mismatches already. We should really fix this!

@cr-xu
Copy link
Member

cr-xu commented Sep 8, 2023

I think initially the reasoning was that it doesn't make sense to shift the ParameterBeam to GPU, because the overhead would be more time-consuming than the actual tracking. But yes, it shouldn't really through an error now, I'll just fix this.

@cr-xu cr-xu linked a pull request Sep 8, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants