PhotonGI cache

Discussion related to the LuxCore functionality, implementations and API.
User avatar
Sharlybg
Donor
Donor
Posts: 3101
Joined: Mon Dec 04, 2017 10:11 pm
Location: Ivory Coast

Re: PhotonGI cache

Post by Sharlybg »

Luxcore = Total Luxury :D
Support LuxCoreRender project with salts and bounties

Portfolio : https://www.behance.net/DRAVIA
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: PhotonGI cache

Post by Dade »

Dade wrote: Thu Feb 28, 2019 10:56 am What puzzle me is that I'm quite convinced now that the problem is not in PhotonGI at all but in backward Vs.forward ray tracing results (aka Path tracing Vs. Light tracing). PhotonGI incidentally just does light tracing.

This is a rendering with PATHCPU (no PGI involved):

path.jpg

And this with LIGHTCPU (no PGI involved):

light.jpg

The difference is striking. I'm starting to think the problem may be in using "true" HDR and importance sampling (i.e. LIGHTCPU ends to emit only 1 out 1000 particles from low power HDR pixels).
This problem was driving me crazy than I have finally noticed that test scene was using variance clamping of 1 .... damn, variance clamping requires different values between forward and backward ray tracing. It was the source of the above problem. Another strange setting of the scene was the 64 max. path depth ... 64 ?!?

Anyway back to square one and looking for the source of problem.
Support LuxCoreRender project with salts and bounties
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: PhotonGI cache

Post by lacilaci »

What do you mean by different values? I though that photongi doesn't even use clamping...
About path depth... if too low values like 4 and lower are a bit low, and above 8 seem to not make too big diffrence... maybe we should simply have hardcoded 8 or 16 and get rid of it. Especially if it can break stuff!

EDIT: unclamped rendering (also used photon depth of 8) shows just as big difference, if not bigger. So I don't know if clamping even matters in this issue.

unclamped no pgi:
unclamped_nopgi.jpg
unclamped + pgi:
unclamped_pgi.jpg
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: PhotonGI cache

Post by lacilaci »

I might be missinterpreting stuff here, but to me it looks like cache looks at first hit ok, then it somehow got overwriten by weaker entries but then at some places bounces with proper power, might also be source of some leaks.... no?
cache_entries.jpg
andreymd87
Posts: 22
Joined: Mon Jun 04, 2018 10:59 am

Re: PhotonGI cache

Post by andreymd87 »

lacilaci wrote: Fri Mar 01, 2019 9:05 am I might be missinterpreting stuff here, but to me it looks like cache looks at first hit ok, then it somehow got overwriten by weaker entries but then at some places bounces with proper power, might also be source of some leaks.... no?

cache_entries.jpg
not sure about this but fully biased solution always will come with these leaks if no proper settings are used. maybe a better solution will be a partial caching method wich is slightly slower but with light leaks free, like corona has :?
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: PhotonGI cache

Post by lacilaci »

andreymd87 wrote: Fri Mar 01, 2019 10:02 am
lacilaci wrote: Fri Mar 01, 2019 9:05 am I might be missinterpreting stuff here, but to me it looks like cache looks at first hit ok, then it somehow got overwriten by weaker entries but then at some places bounces with proper power, might also be source of some leaks.... no?

cache_entries.jpg
not sure about this but fully biased solution always will come with these leaks if no proper settings are used. maybe a better solution will be a partial caching method wich is slightly slower but with light leaks free, like corona has :?
Corona's solution isn't completely problem free, it's basicaly two presets, one for stills and one for animation.. And I think some general multiplier value if you need even more precise cache to avoid flickering.

I think this cache works really well and we could eventually establish preset modes instead all setings exposed as well.. But this brightness issue is something different and it definitely looks like a bug. Although for me personally this bias isn't too big and I'm ok with it. Many people will definitely have issues with such difference.
andreymd87
Posts: 22
Joined: Mon Jun 04, 2018 10:59 am

Re: PhotonGI cache

Post by andreymd87 »

lacilaci wrote: Fri Mar 01, 2019 10:17 am
andreymd87 wrote: Fri Mar 01, 2019 10:02 am
lacilaci wrote: Fri Mar 01, 2019 9:05 am I might be missinterpreting stuff here, but to me it looks like cache looks at first hit ok, then it somehow got overwriten by weaker entries but then at some places bounces with proper power, might also be source of some leaks.... no?

cache_entries.jpg
not sure about this but fully biased solution always will come with these leaks if no proper settings are used. maybe a better solution will be a partial caching method wich is slightly slower but with light leaks free, like corona has :?
Corona's solution isn't completely problem free, it's basicaly two presets, one for stills and one for animation.. And I think some general multiplier value if you need even more precise cache to avoid flickering.

I think this cache works really well and we could eventually establish preset modes instead all setings exposed as well.. But this brightness issue is something different and it definitely looks like a bug. Although for me personally this bias isn't too big and I'm ok with it. Many people will definitely have issues with such difference.
maybe you are right. let's just follow the development and see how this problem is resolved.
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: PhotonGI cache

Post by Dade »

lacilaci wrote: Fri Mar 01, 2019 6:11 am What do you mean by different values? I though that photongi doesn't even use clamping...
About path depth... if too low values like 4 and lower are a bit low, and above 8 seem to not make too big diffrence... maybe we should simply have hardcoded 8 or 16 and get rid of it. Especially if it can break stuff!

EDIT: unclamped rendering (also used photon depth of 8) shows just as big difference, if not bigger. So I don't know if clamping even matters in this issue.

unclamped no pgi:
unclamped_nopgi.jpg
unclamped + pgi:
unclamped_pgi.jpg

Your no pgi rendering is very different from before while the pgi one is about the same: viewtopic.php?f=5&t=840&start=640#p10692

You are mixing different tests.
Support LuxCoreRender project with salts and bounties
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: PhotonGI cache

Post by Dade »

lacilaci wrote: Fri Mar 01, 2019 9:05 am I might be missinterpreting stuff here, but to me it looks like cache looks at first hit ok, then it somehow got overwriten by weaker entries but then at some places bounces with proper power, might also be source of some leaks.... no?
It is because the geometry is bad: check the roof, it is a single plane, not a real wall with a depth, this is a bad idea, it can cause light leaks even with normal path tracing.
Support LuxCoreRender project with salts and bounties
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: PhotonGI cache

Post by lacilaci »

Dade wrote: Fri Mar 01, 2019 11:12 am
lacilaci wrote: Fri Mar 01, 2019 6:11 am What do you mean by different values? I though that photongi doesn't even use clamping...
About path depth... if too low values like 4 and lower are a bit low, and above 8 seem to not make too big diffrence... maybe we should simply have hardcoded 8 or 16 and get rid of it. Especially if it can break stuff!

EDIT: unclamped rendering (also used photon depth of 8) shows just as big difference, if not bigger. So I don't know if clamping even matters in this issue.

unclamped no pgi:
unclamped_nopgi.jpg
unclamped + pgi:
unclamped_pgi.jpg

Your no pgi rendering is very different from before while the pgi one is about the same: viewtopic.php?f=5&t=840&start=640#p10692

You are mixing different tests.
no I'm not. they're different but just a little bit

unclamped gi caching:
unclamped_0.jpg
clamped gi caching:
clamped_0.jpg
EDIT: also fixing roof/ceiling geometry doesn't change anything...
Post Reply