LuxCore: new fast pixel filtering for PATH engine

Discussion related to the implementation of new features & algorithms to the Core Engine.

Moderators: Dade, jromang, tomb, zcott, coordinators

LuxCore: new fast pixel filtering for PATH engine

Postby Dade » Sun Sep 27, 2015 4:46 am

Introduction

LuxRender uses pixel filtering to reconstruct the rendered image out of samples (like PBRT). Each sample affects multiple pixels according the pixel filter radius. Larger is the radius and more pixels are affected. Indeed, more pixels are affected and slower the rendering is. With the default filter radius value, about 5x5 pixels are affected by each sample. This is clearly very expansive.

BIASPATH pixel filtering

BIASPATH has introduced a new way to reconstruct the image from samples: it uses the samples distribution to implicitly weight the samples. On the long run, it produces exactly the same result. However one sample affects one and only one pixel and this is clearly a lot faster than affecting 5x5 pixels.

Blurred Vs sharp at the begin of the rendering

Both methods produce exactly the same result on the long run however there is a difference: classic method will produce a blurred image at the beginning of the rendering while new method produces sharper images. But it doesn't matter on the long run.

New pixel filtering now available for PATH(CPU/OCL) too

I have implemented the same BIASPATH pixel filtering technique in PATH too. It is also the new default method used. you can switch between one method and the other by using this property:

Code: Select all
path.fastpixelfilter.enable = 1


Constant (small) performance cost

The new method is clearly faster than the old one, This is a CPU rendering with the old method:

cpu-std.jpg


and this with the new method:

cpu-fast.jpg


12% faster. Larger is the filter radius and larger is the benefit. Also higher is the samples/sec and more pixel filtering become a bottleneck and more the new method is useful. Indeed, GPUs like this stuff. This is a rendering with the old method on a GPU:

ocl-std.jpg


and this with the new method:

ocl-fast.jpg


17% faster. you can obtain some crazy speedup by using larger filter radius (i.e. constant cost Vs NxN cost) however very large pixel filter radii are not particularly useful.

BIDIR

BIDIR is a low throughput (i.e. samples/sec) rendering method. I'm still wondering if it is worth to implement the new technique for BIDIR too.
User avatar
Dade
Developer
 
Posts: 8356
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: LuxCore: new fast pixel filtering for PATH engine

Postby Alpistinho » Sun Sep 27, 2015 5:06 am

Cool!

Is it like the "Filter Importance Sampling" used in Cycles?
(lgdv.cs.fau.de/get/785)

Thank you for all your work

:)
User avatar
Alpistinho
Developer
 
Posts: 264
Joined: Sat Sep 27, 2014 10:57 am
Location: Rio de Janeiro, Brazil

Re: LuxCore: new fast pixel filtering for PATH engine

Postby B.Y.O.B. » Sun Sep 27, 2015 5:54 am

You keep shattering the old "LuxRender is slow" prejudice until it is no longer recognizable... 3.85 MS/s on a CPU rendering, holy cow!
User avatar
B.Y.O.B.
Developer
 
Posts: 5135
Joined: Wed Nov 10, 2010 4:10 pm
Location: Germany

Re: LuxCore: new fast pixel filtering for PATH engine

Postby SATtva » Sun Sep 27, 2015 7:26 am

B.Y.O.B. wrote:You keep shattering the old "LuxRender is slow" prejudice until it is no longer recognizable... 3.85 MS/s on a CPU rendering, holy cow!

+1, and people still believe it is -- stereotypes are so stupid.
Linux builds packager
聞くのは一時の恥、聞かぬのは一生の恥
User avatar
SATtva
Developer
 
Posts: 7162
Joined: Tue Apr 07, 2009 12:19 pm
Location: from Siberia with love

Re: LuxCore: new fast pixel filtering for PATH engine

Postby B.Y.O.B. » Sun Sep 27, 2015 8:32 am

Maybe LuxCore should have been named "FastLux" 8-)
User avatar
B.Y.O.B.
Developer
 
Posts: 5135
Joined: Wed Nov 10, 2010 4:10 pm
Location: Germany

Re: LuxCore: new fast pixel filtering for PATH engine

Postby Dade » Sun Sep 27, 2015 8:58 am

Alpistinho wrote:Is it like the "Filter Importance Sampling" used in Cycles?
(lgdv.cs.fau.de/get/785)


Yes, exactly, it was invented for tile rendering mainly but works well with full-image samplers too (like the one used in PATH engine).
User avatar
Dade
Developer
 
Posts: 8356
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: LuxCore: new fast pixel filtering for PATH engine

Postby pciccone » Sun Sep 27, 2015 9:24 am

This is fantastic news. Not only for the speed but for the quality of the image. I found that BIASPATH images end up being sharper then when user PATHCPU. So, can we assume that this will bring the same final sharpness to the PATHCPU renderer?

Thank you.
User avatar
pciccone
Developer
 
Posts: 1579
Joined: Wed Jan 13, 2010 11:02 am
Location: South Carolina

Re: LuxCore: new fast pixel filtering for PATH engine

Postby Dade » Sun Sep 27, 2015 9:48 am

pciccone wrote:This is fantastic news. Not only for the speed but for the quality of the image. I found that BIASPATH images end up being sharper then when user PATHCPU. So, can we assume that this will bring the same final sharpness to the PATHCPU renderer?


Yes. Keep in mind that filter radius has also a huge impact on image sharpness so just reduce the radius if you like more sharp images.
User avatar
Dade
Developer
 
Posts: 8356
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Re: LuxCore: new fast pixel filtering for PATH engine

Postby pciccone » Sun Sep 27, 2015 10:46 am

I did set the filter radius to 1.5, maybe I should set it to 1.0?
User avatar
pciccone
Developer
 
Posts: 1579
Joined: Wed Jan 13, 2010 11:02 am
Location: South Carolina

Re: LuxCore: new fast pixel filtering for PATH engine

Postby Dade » Sun Sep 27, 2015 12:18 pm

pciccone wrote:I did set the filter radius to 1.5, maybe I should set it to 1.0?


1.0 sounds a bit too small to me, 2.0 is the default for the default pixel filter so 1.5 should already quite sharp.
User avatar
Dade
Developer
 
Posts: 8356
Joined: Sat Apr 19, 2008 6:04 pm
Location: Italy

Next

Return to Architecture & Design

Who is online

Users browsing this forum: No registered users and 1 guest

cron