-
Notifications
You must be signed in to change notification settings - Fork 31
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
No normal gradient (and others I believe) from DSS class #8
Comments
Hi, I have same problem as you. And I found another problem https://github.com/yifita/DSS/issues/9 |
I implemented my own dRho computation. I cannot guarantee it is correct, but it hasn't messed anything up for me so far. I replaced lines 276-287 from the rasterize function with this:
Then I removed all "detach()" when computing rho. Hope this helps others! |
Thank you @bango123 ! |
Hello @yifita! Thank you for releasing this code base and your paper is really high quality btw. I am doing a research project which is reconstructing from point based geometry and your work seemed like a perfect fit for it. So I put in the time to really understand your work and code implementation. From your paper, it looks like these are the derivatives wanted (after approximating dh/dn = 0): However, as you probably already know, it looks like adding \bar{rho} w.r.t to points and normals (i.e. dI/ \bar{rho}) makes very little difference to the gradients. I am guessing that is because your approximated gradient for dI/dh is so much larger in magnitude. tl;dr wanted to learn about your code/paper, so I tried to fix something. The "fix" appears to make little difference. |
I am interested in using this repo for my research and have been digging through the DSS rendering code. I found that when using the SmapeLoss in a toy rendering problem with a single point and single normal (similar to Figure 6 of your paper) the gradient of the loss with respect to the normal came back as None. After some more digging, I notice that in the render() function line 855-859 the projPoints, cameraPoints, and cameraNormals have their gradients detached when computing rho. Therefore, it looks like the partial derivatives drho/dn and drho/dp from equations 8 and 9 of your paper are not being computed.
Also I dug into the DSS rasterize backward function and it looks like dRho is always returned as None. It looks like only dI/dw and (dI/dh)*(dh/dp) from equations 8 and 9 are returned.
It would be very helpful if I could get assistance with recovering these gradients or clarifying my understanding of the code.
Thank you!
The text was updated successfully, but these errors were encountered: