POV-Ray : Newsgroups : povray.bugreports : Partial Output does not match Single-Pass Output on some files Server Time
15 Oct 2024 05:03:24 EDT (-0400)
  Partial Output does not match Single-Pass Output on some files (Message 1 to 5 of 5)  
From: Lloyd
Subject: Partial Output does not match Single-Pass Output on some files
Date: 10 Jul 2018 03:45:01
Message: <web.5b4462c4d886bf7bf3845660@news.povray.org>
Hello,

I am interested in using POV-Ray in a distributed computing environment, in
which I may have many compute nodes available for rendering.  One requirement
for this project is that an image rendered in a single pass should match exactly
an image that is rendered in pieces with Partial Output and then properly
reassembled.

I have been trying to verify this behavior on a fairly large file with many
thousands of elements (frames of this video: https://youtu.be/Pa149iuBPGw , a
spinning glassy earth globe with thousands of spherical markers), by rendering
one frame in a Single-Pass, and again in 4 Quadrants and then merging
(Merged-Quadrant).  I was surprised to see small differences distributed
throughout the image.  I thought it might be my particular file, which has many
glassy elements with reflection and refraction.  But then I tried the same test
on some standard images from the POV-Ray distribution.  There were no problems
with biscuit.pov.  But I found a lot of problems with benchmark.pov.

Here is my setup.  I am running POV-Ray on Windows.  This example does not use
AntiAliasing, just to keep the render times shorter.  I'm using a small 16:9
image size (480x270) for these small tests. Here are the 4 commands to render
the 4 quadrants:

pvengine.exe /RENDER benchmark.pov Width=480 Height=270 DISPLAY=off -A
Start_Column=1 Start_Row=1 End_Column=240 End_Row=135 /EXIT

pvengine.exe /RENDER benchmark.pov Width=480 Height=270 DISPLAY=off -A
Start_Column=241 Start_Row=1 End_Column=480 End_Row=135 /EXIT

pvengine.exe /RENDER benchmark.pov Width=480 Height=270 DISPLAY=off -A
Start_Column=1 Start_Row=136 End_Column=240 End_Row=270 /EXIT

pvengine.exe /RENDER benchmark.pov Width=480 Height=270 DISPLAY=off -A
Start_Column=241 Start_Row=136 End_Column=480 End_Row=270 /EXIT

which I then reassembled into a single image in Photoshop.  Here is the command
to render the Single-Pass reference:

pvengine.exe /RENDER benchmark.pov Width=480 Height=270 DISPLAY=off -A /EXIT

Here is the Single-Pass reference image:
https://www.dropbox.com/s/mep5qzw7rj73sld/SinglePass.png?dl=0

Here is the Merged-Quadrant image:
https://www.dropbox.com/s/baz4z8r2my15ayy/MergedQuadrants.png?dl=0

And here is the difference map, amplified:
https://www.dropbox.com/s/jxbk6xzgzgz0q05/Difference.png?dl=0

In isolation, the Merged-Quadrant image looks just fine.  But it does not match
the Single-Pass image well at all.  This would be very important in frames of an
animation where some frames might be rendered by a powerful machine in
Single-Pass mode, and others might be rendered by weaker machines in
Merged-Quadrant mode -- frame-to-frame differences would jump out as
crawling/sparkly artifacts in the animation.

I have run the same experiment with AntiAliasing on, and the results are similar
(but even trickier, because new problems occur at the quadrant edges, requiring
a "guard ring" of extra pixels to be rendered to make sure that all the pixels
that are actually used in the final merged image have all 8 neighbors.)

I note that benchmark.pov uses a lot of fancy features like radiosity, photons,
etc.  But my original globe-with-markers image doesn't use any of those fancy
features.  Just lots of glassy spheres and CSG. I can provide the .pov file for
that if it would help -- it's a big, computer-generated file, so I thought it
would be best to report the problem using benchmark.pov which is familiar and
much shorter.

Would this be considered a bug?  Or an out-of-scope usage of the Partial Output
feature -- perhaps this kind of matching was never a requirement for Partial
Output?  Or something else?

Thank you,
Lloyd


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: Partial Output does not match Single-Pass Output on some files
Date: 10 Jul 2018 04:20:00
Message: <web.5b446b1db6160a1165a6e32f0@news.povray.org>
"Lloyd" <nomail@nomail> wrote:
> Hello,
>
> I am interested in using POV-Ray in a distributed computing environment, in
> which I may have many compute nodes available for rendering.  One requirement
> for this project is that an image rendered in a single pass should match exactly
> an image that is rendered in pieces with Partial Output and then properly
> reassembled.
>
> I have been trying to verify this behavior on a fairly large file with many
> thousands of elements (frames of this video: https://youtu.be/Pa149iuBPGw , a
> spinning glassy earth globe with thousands of spherical markers), by rendering
> one frame in a Single-Pass, and again in 4 Quadrants and then merging
> (Merged-Quadrant).  I was surprised to see small differences distributed
> throughout the image.  I thought it might be my particular file, which has many
> glassy elements with reflection and refraction.  But then I tried the same test
> on some standard images from the POV-Ray distribution.  There were no problems
> with biscuit.pov.  But I found a lot of problems with benchmark.pov.

Your problems are a user error: Using features with randomized or
order-dependent features cannot work the way you expect. Disable such features
and the problem goes away.

Thorsten


Post a reply to this message

From: clipka
Subject: Re: Partial Output does not match Single-Pass Output on some files
Date: 10 Jul 2018 08:18:00
Message: <5b44a3f8$1@news.povray.org>
Am 10.07.2018 um 09:39 schrieb Lloyd:

> I am interested in using POV-Ray in a distributed computing environment, in
> which I may have many compute nodes available for rendering.  One requirement
> for this project is that an image rendered in a single pass should match exactly
> an image that is rendered in pieces with Partial Output and then properly
> reassembled.

There are certain features that - at least currently - can't be used in
this manner.

Probably the most influential such feature (in terms of its effect on
the result image) is radiosity: During pretrace, POV-Ray decides where
to gather samples, which are then used during the main render; since the
pretrace is limited to the same section of the screen as the main
render, a partial render will lead to different decisions on where to
gather samples, and thus a different sample set, which in turn affects
the render result.

As a matter of fact, radiosity will typically display differences even
between any two given full-frame renders, due to randomness in the
operating system's scheduling and the resulting order in which render
blocks are processed.

(You can force radiosity to give reproducible results by either running
the render single-threaded, or setting `+HR` on the command line to
enforce reproducibility at the cost of a bit of pretrace performance.)


Note however that reproducibility of /individual/ frames is not the only
(and not even the most important) property you want: What you want is
"similarity" (whatever that means) of /subsequent/ frames.

In that, non-reproducibility of individual frames is actually your ally,
not your enemy: If you see differences between two renders of one and
the same frame, that's an indication that you're also likely to see the
same level of differences between subsequent frames - and those can
/not/ be turned off simply with a command-line switch.

Rather, you should make sure that the quality settings of the
problematic features are set high enough so that the residual
differences between renders of the same frame become acceptable.


Post a reply to this message

From: William F Pokorny
Subject: Re: Partial Output does not match Single-Pass Output on some files
Date: 10 Jul 2018 09:05:22
Message: <5b44af12$1@news.povray.org>
On 07/10/2018 08:17 AM, clipka wrote:
> Am 10.07.2018 um 09:39 schrieb Lloyd:
> 
>> I am interested in using POV-Ray in a distributed computing environment, in
>> which I may have many compute nodes available for rendering.  One requirement
>> for this project is that an image rendered in a single pass should match exactly
>> an image that is rendered in pieces with Partial Output and then properly
>> reassembled.
> 
> There are certain features that - at least currently - can't be used in
> this manner.
> 
> Probably the most influential such feature (in terms of its effect on
> the result image) is radiosity: During pretrace, POV-Ray decides where
...
> 

 From memory, I'll add that benchmark.pov & benchmark.ini have both 
basic jitter and an area light jitter on which you'd want off - even 
when trying to reproduce full frames render to render.

"...rendered with POV-Ray on 3 Amazon EC2 c4.8xlarge machines." - cool!

Bill P.


Post a reply to this message

From: Lloyd
Subject: Re: Partial Output does not match Single-Pass Output on some files
Date: 10 Jul 2018 14:30:06
Message: <web.5b44faffb6160a11f3845660@news.povray.org>
Thank you very much for the instructive explanations.  Very good, I now see that
I was trying to do something that could not be expected to work as I intended.
Thank you,
Lloyd


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.