Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I can´t find the rendered file #1292

Open
alecail opened this issue Aug 31, 2024 · 6 comments
Open

I can´t find the rendered file #1292

alecail opened this issue Aug 31, 2024 · 6 comments

Comments

@alecail
Copy link

alecail commented Aug 31, 2024

Summary

I can´t find the rendered file

System configuration

I am using python3.

System information:

    ~/mitsuba/cornell-box  python3 -m mitsuba.sys_info      

                                                                                               127 ✘ 
jit_llvm_init(): your CPU does not support the `fma` instruction set, shutting down the LLVM backend...
System information:

  OS: Linux Mint 21.2
  CPU: Intel(R) Xeon(R) CPU E5-2670 0 @ 2.60GHz
  GPU: NVIDIA GeForce RTX 4060 Ti
NVIDIA RTX A2000
  Python: 3.10.12 (main, Jul 29 2024, 16:56:48) [GCC 11.4.0]
  NVidia driver: 550.90.07
  LLVM: 15.0.7

  Dr.Jit: 0.4.6
  Mitsuba: 3.5.2
     Is custom build? False
     Compiled with: GNU 10.2.1
     Variants:
        scalar_rgb
        scalar_spectral
        cuda_ad_rgb
        llvm_ad_rgb

Description

I downloaded the Cornell box from here: https://mitsuba.readthedocs.io/en/stable/src/gallery.html
After this command line finished executing:

$ mitsuba scene.xml -o out.exr

I don't have a file named out.exr at the end of the process.

The error code is 252 according to my terminal

Steps to reproduce


jit_llvm_init(): your CPU does not support the `fma` instruction set, shutting down the LLVM backend...
2024-08-31 20:49:25 INFO  main  [mitsuba.cpp:334] Mitsuba version 3.5.2 (master[29d6537], Linux, 64bit, 32 threads, 8-wide SIMD)
2024-08-31 20:49:25 INFO  main  [mitsuba.cpp:335] Copyright 2022, Realistic Graphics Lab, EPFL
2024-08-31 20:49:25 INFO  main  [mitsuba.cpp:336] Enabled processor features: cuda llvm avx f16c sse4.2 x86_64
2024-08-31 20:49:25 INFO  main  [xml.cpp:1380] Loading XML file "scene.xml" with variant "scalar_rgb"..
2024-08-31 20:49:25 INFO  main  [Scene] Embree ready. (took 5ms)
2024-08-31 20:49:25 INFO  main  [xml.cpp:1397] Done loading XML file "scene.xml" (took 17ms).
2024-08-31 20:49:25 INFO  main  [SamplingIntegrator] Starting render job (1024x1024, 64 samples, 32 threads)
Rendering [====================================================================================================================================] (8.01s, ETA: 0ms)     
2024-08-31 20:49:33 INFO  main  [SamplingIntegrator] Rendering finished. (took 8.006s)
2024-08-31 20:49:33 INFO  main  [HDRFilm] ✔  Developing "out.exr" ..
  1. ... No file named out.exr
@alecail alecail changed the title I can´t find the output file rendered file I can´t find the rendered file Aug 31, 2024
@njroussel
Copy link
Member

Hi @alecail

I'm not sure what is happening. Is that the full eror log you've provided? I would have expected to see an error message, or at least the error code in it too.

Is there a filesystem permission issue maybe? Can you create new files in the folder where you're running mitsuba.

The other option that comes to mind is some illegal instruction being executed on your CPU. We've seen weird behavior in the past with Xeon CPUs, and the part of the code that develops the final image can potentially use some very specific instructions.

@alecail
Copy link
Author

alecail commented Sep 2, 2024

There is no filesystem issue. It's just your standard folder, in which I copied scene.xml. Local install, nothing fancy.
FWIW, there are no problems writing the output when callling it from python like this, but the error messages are still there:
$ cat test.py

import mitsuba as mi
# Set the variant of the renderer
mi.set_variant('scalar_rgb')
# Load a scene
print (mi.variants())
mi.set_variant('cuda_ad_rgb')
scene = mi.load_dict(mi.cornell_box())
# Render the scene
img = mi.render(scene, spp=500)
# Write the rendered image to an EXR file
mi.Bitmap(img).write('cbox.exr')

python3 test.py

jit_llvm_init(): your CPU does not support the `fma` instruction set, shutting down the LLVM backend...
['scalar_rgb', 'scalar_spectral', 'cuda_ad_rgb', 'llvm_ad_rgb']
jit_shutdown(): detected variable leaks:
 - variable r930 is still being referenced! (ref=1, ref_se=0, type=void, size=1, stmt="", dep=[0, 0, 0, 0])
jit_shutdown(): 1 variables are still referenced!

Then a rendering of a Cornell box is written in the file cbox.exr

I can ´t find anything about: jit_llvm_init(): your CPU does not support the fma instruction set,
But it's also telling me that it's not going to use it. Not sure what to conclude

@njroussel
Copy link
Member

In the python script, could you try replacing
mi.Bitmap(img).write('cbox.exr')
with
scene.sensors()[0].film().write('out.exr')
Does it still work ?

These are slighlty different code paths, and the latter one is used by mitsuba executable.

@alecail
Copy link
Author

alecail commented Sep 2, 2024

@njroussel This doesn't break test.py on my end
It still outputs a correct out.exr, and it still has the same warnings.

@njroussel
Copy link
Member

I'm stumped, my only suggestion would be to build the project yourself (be careful to checkout v3.5.2 and update the git submodules) in Debug mode and run it through the debugger.
Maybe if I know which source code line is crashing, I can figure out the rest.

@dvicini
Copy link
Member

dvicini commented Sep 12, 2024

Maybe an issue with the struct converter for that particular CPU generation? What if you build from source, but explicitly set MI_STRUCTCONVERTER_USE_JIT = 0 in struct.h?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants