NSpectrumSamples=1 causes unit test fails

44 views
Skip to first unread message

sldstt

unread,
Jan 12, 2023, 3:07:45 AM1/12/23
to pbrt
I have a use case where I want NSpectrumSamples=1, but this causes some unit tests to fail. Specifically the "RadianceMatch" tests fail due to inaccuracy of the results. I guess this happens because the spectrum is not sampled as well as before. I tried to increase the number of samples-per-pixel but that had not effect, not sure why. Increasing the resolution did seem to fix this. Am I doing something terribly wrong here or is it acceptable to change NSpectrumSamples?

Matt Pharr

unread,
Jan 27, 2023, 8:13:51 PM1/27/23
to pb...@googlegroups.com
It’s definitely ok to change NSpectrumSamples!

I see three failures, all of which are results just slightly out of tolerance, so it should just be a matter of bumping up the epsilons in the tests. I filed https://github.com/mmp/pbrt-v4/issues/321 pending actually doing that.

Thanks for noticing this!

Matt

On Jan 12, 2023, at 12:07 AM, sldstt <soli...@gmail.com> wrote:

I have a use case where I want NSpectrumSamples=1, but this causes some unit tests to fail. Specifically the "RadianceMatch" tests fail due to inaccuracy of the results. I guess this happens because the spectrum is not sampled as well as before. I tried to increase the number of samples-per-pixel but that had not effect, not sure why. Increasing the resolution did seem to fix this. Am I doing something terribly wrong here or is it acceptable to change NSpectrumSamples?

--
You received this message because you are subscribed to the Google Groups "pbrt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pbrt+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pbrt/bec5282c-4681-49a3-8cb9-9b6810601d53n%40googlegroups.com.

sldstt

unread,
Jan 28, 2023, 3:25:24 AM1/28/23
to pbrt
Thanks Matt!

Can you shed some light on why increasing spp didn't fix this?

Matt Pharr

unread,
Jan 28, 2023, 10:01:27 AM1/28/23
to pb...@googlegroups.com
Increasing spp fixed it for me, so I can’t say! In any case, I’ve pushed a fix—the tests should all pass as expected now.

Thanks,
Matt

Reply all
Reply to author
Forward
0 new messages