NVlabs / nvdiffrec

Official code for the CVPR 2022 (oral) paper "Extracting Triangular 3D Models, Materials, and Lighting From Images".
Other
2.13k stars 223 forks source link

loading .hdr environment map in the beginning #108

Closed sadexcavator closed 1 year ago

sadexcavator commented 1 year ago

Hi, again, thanks for your great work, I've noticed that in your code that the environment map can be loaded by 'lgt = light.load_env' rather than create a trainable one. And by your design idea, it needs the flag 'learn_light' to be false to do this, consequently, the optimize process won't try to optimize the light because the FLAGS.learn_light is false. I just wonder that what if I still want to optimize the light I loaded in the beginning(to do this only needs to change the code a little bit), I just want to know if is this a wrong idea to optimize a already loaded environment light.(for example I can pre-capture the envionment around the object and get a hdr environment map). Could you share some insights about this? THANKS!

jmunkberg commented 1 year ago

Yes, loading an environment map and continue optimizing it should work. It is not supported out of the box in the code, but it should be straightforward to test.