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

Add diagnostic AOV for invalid samples #1815

Closed
luisbarrancos opened this issue Jan 27, 2018 · 13 comments
Closed

Add diagnostic AOV for invalid samples #1815

luisbarrancos opened this issue Jan 27, 2018 · 13 comments
Labels
Milestone

Comments

@luisbarrancos
Copy link
Member

Sometimes, specially with bigger shading networks and bigger scenes, it can be quite tricky to find out which shader(s) is generating NaN/Inf/invalid samples.
An diagnostic pass for this explicit purpose would help tremendously in pinpointing the misbehaving culprit.

@oktomus
Copy link
Member

oktomus commented Mar 1, 2018

In the final exported AOVs, how do you know which shader is failling ? Do we export an AOv per shader ?

@dictoon
Copy link
Member

dictoon commented Mar 1, 2018

@oktomus We don't export an AOV per shader. There is no easy way to know which shader caused invalid samples. However having a map (an AOV) that shows in which pixels did NaN/inf/negative samples occur would be enough I think. @luisbarrancos can you confirm this?

@luisbarrancos
Copy link
Member Author

luisbarrancos commented Mar 1, 2018 via email

@luisbarrancos
Copy link
Member Author

Currently we have a object ID shader. What do you think about using this as a base or something similar, but rescaled so that it's within [0, 0.25] or [0,0.33], in order to provide some measure of background on which to overlap the invalid samples? This would give immediate feedback on which invalid samples were occurring, and from here we can go to any DCC app and inspect the shader networks (and resp. shaders) associated with it. Does something like this makes sense?

@dictoon
Copy link
Member

dictoon commented Mar 1, 2018

It's an interesting idea yes, so the original render in the background (darkened) and invalid samples marked in e.g. bright pink on top?

@oktomus
Copy link
Member

oktomus commented Mar 1, 2018

Why adding the original render in the background ? We can save both the rendered image and the diagnostic AOV.

@dictoon
Copy link
Member

dictoon commented Mar 1, 2018

I agree and I'm slightly split about this, but I guess it's out of convenience: with a single image you can see where there are invalid samples in the render, you don't have to overlay two images (original render + diagnostic AOV). I'm fine with either solution: one is more convenient, the other is more orthogonal.

@luisbarrancos
Copy link
Member Author

luisbarrancos commented Mar 1, 2018 via email

@oktomus
Copy link
Member

oktomus commented Mar 1, 2018

I have another question @luisbarrancos, how do you get the shader network from only the object id? Sorry if it sounds stupid, but I'm wondering..

@luisbarrancos
Copy link
Member Author

@oktomus np, but i meant if we had an image, visual cues to the objects (i.e, data from object IDs in one channel, dimmed), and the invalid samples in other channel, then we would immediatly have a visual idea of where the samples are in regard to the object. It would then be a matter of going into the DCC app (Max, Maya, Blender, whatever), and selecting the object where the invalid samples were placed, and seeing what shaders/shading networks were instanced with that object. From there we would already know one of the nodes was the culprit for producing the invalid samples, it would make things easier to debug.

This in the OSL case, where you have potentially complex shading networks. With appleseed materials, it would be the same principle, except instead of OSL networks or single shaders, we would have a visual cue for the potentially problematic BxDF attached to the object.

@oktomus
Copy link
Member

oktomus commented Mar 2, 2018

Ok I understand, thanks :)

@oktomus
Copy link
Member

oktomus commented Mar 4, 2018

So we finally go with a unique diagnostic AOV containing 20% of the luminance in R+G+B or bright pink if the sampling failed.

@oktomus
Copy link
Member

oktomus commented Mar 8, 2018

Done.

@oktomus oktomus closed this as completed Mar 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Live Roadmap
Awaiting triage
Development

No branches or pull requests

3 participants