Path tracing accumulation artifacts

Practical and theoretical implementation discussion.
Brigadir
Posts: 8
Joined: Mon May 14, 2012 11:42 am

Path tracing accumulation artifacts

Post by Brigadir » Sun Oct 19, 2014 7:27 pm

Hello guys,

Thanks for organizing this valuable forum!
Please, see the image - it is a path traced accumulated image with 15000 samples per pixel.
Each pixel color has the structure {double r, double g, double b}. At each PT pass these are accumulated: pixel.r += pass.r, pixel.g += pass.g, etc.

When I get some medium SPP of 3000-5000 the lighting on the walls is changing smoothly, but noisy. The noise is nice.
But when the path tracing accumulation process goes further and has more passes (> 10000) the lighting on the walls becomes clustered (pls zoom in the attachement img). I don't remember how this artifact is called. But please help me to eliminate the problem and get less problems with more PT passes.
Attachments
path_tracing_artifacts.jpg
path_tracing_artifacts.jpg (31.52 KiB) Viewed 7245 times

MohamedSakr
Posts: 83
Joined: Thu Apr 24, 2014 2:27 am

Re: Path tracing accumulation artifacts

Post by MohamedSakr » Sun Oct 19, 2014 7:50 pm

what is the rendered image resolution X , Y

Brigadir
Posts: 8
Joined: Mon May 14, 2012 11:42 am

Re: Path tracing accumulation artifacts

Post by Brigadir » Sun Oct 19, 2014 7:54 pm

the resolution doesn't matter, it is 512x512 rendered and displayed. Other renderers for the same scene produce correct results

MohamedSakr
Posts: 83
Joined: Thu Apr 24, 2014 2:27 am

Re: Path tracing accumulation artifacts

Post by MohamedSakr » Sun Oct 19, 2014 8:09 pm

well, I doubt something, so check it first, assuming a counter of integer type which is limited to 2^31, and it loops over the whole image (512 * 512) which is (2^9 * 2^9) , then you will have 2^13 samples per pixel before the counter goes mad (which is 8192 spp) , check this, if it is not the problem then I don't know what may cause this problem

Brigadir
Posts: 8
Joined: Mon May 14, 2012 11:42 am

Re: Path tracing accumulation artifacts

Post by Brigadir » Sun Oct 19, 2014 8:13 pm

this is irrelevant calc, double type is used.

MohamedSakr
Posts: 83
Joined: Thu Apr 24, 2014 2:27 am

Re: Path tracing accumulation artifacts

Post by MohamedSakr » Sun Oct 19, 2014 8:17 pm

well, test this, an output of 2k * 2k, with 1000 spp, if it generates artifacts then the problem is a false counter somewhere, the data is double or float for sure, but the sample "index" may be false

Brigadir
Posts: 8
Joined: Mon May 14, 2012 11:42 am

Re: Path tracing accumulation artifacts

Post by Brigadir » Sun Oct 19, 2014 8:43 pm

it is the same with different resolution and then upscaling and downscaling the final result.

The sample index doesn't matter at all, since there are just 512*512 samples, and each time they are updated (actually 15000 times each).
The artifacts follow the light intensity distribution across the walls and corners, as you may notice.

Brigadir
Posts: 8
Joined: Mon May 14, 2012 11:42 am

Re: Path tracing accumulation artifacts

Post by Brigadir » Sun Oct 19, 2014 8:56 pm

Just add that applied gamma is 2.2

MohamedSakr
Posts: 83
Joined: Thu Apr 24, 2014 2:27 am

Re: Path tracing accumulation artifacts

Post by MohamedSakr » Sun Oct 19, 2014 8:57 pm

hmm, for sure I can see where the errors in the image are, but I'm still concerned about the counter for some reason
if the samples are independent, then adding every sample with a different random number seed will give you correct image "so averaging 30k different 1 spp images should be equal to a 30k spp image"

from this point, try to store first 8k spp in one image, and the 2nd 8k spp in another image

friedlinguini
Posts: 89
Joined: Thu Apr 11, 2013 5:15 pm

Re: Path tracing accumulation artifacts

Post by friedlinguini » Sun Oct 19, 2014 10:02 pm

The image is quite dark, at least on the devices I have handy, so I can't comment on the artifacts themselves. How good is your random number generator?

Post Reply