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

Fix infer.csis to ignore gradient when parameter not used, which has a gradient of None #2828

Merged
merged 1 commit into from
Apr 28, 2021

Conversation

fshipy
Copy link
Contributor

@fshipy fshipy commented Apr 28, 2021

Fixes #2827

If some parameters are not used to produce the outputs, the gradients can be None. In this case, an error will be raised because of the addition between None and Tensor.

@fshipy fshipy changed the title infer.csis ignore gradient when parameter not used, which has a gradient of None Fix infer.csis to ignore gradient when parameter not used, which has a gradient of None Apr 28, 2021
Copy link
Member

@fritzo fritzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for reporting and fixing this @fshipy!

@fritzo fritzo merged commit 8246685 into pyro-ppl:dev Apr 28, 2021
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.

[bug] CSIS error when parameters are not fully used
2 participants