Loping151 / ForPlane

Neural LerPlane Representations for Fast 4D Reconstruction of Deformable Tissues
Other
42 stars 2 forks source link

Code get stuck with NeRFACC #14

Closed Rashfu closed 3 weeks ago

Rashfu commented 3 weeks ago

The code in main.py is stuck for 20minutes+ at line 258 in lowrank_model.py(self.occupancy_grid.sampling).

All the environment setup commands run successfully. (I used pip install nerfacc here.)

When I switched to pip install git+https://github.com/nerfstudio-project/nerfacc.git, the code worked well. But I couldn't get into the sampling function for debugging.

Loping151 commented 3 weeks ago

We didn't get stuck there, but I assume it is likely a build error. Anyway, it makes no sense you can't debug. Did you try debug using import pdb or debug line by line?

Rashfu commented 3 weeks ago

Yes, I debugged the code line by line using VSCode. I still couldn't step into self.occupancy_grid.sampling, but I can step into sigma_fn and rgb_sigma_fn, which looks strange. How can I uninstall Nerfacc completely? Maybe I'll try to set up a new Conda environment to test it.

Rashfu commented 3 weeks ago

I found this tip: “The easiest way is to install from PyPI. In this way it will build the CUDA code on the first run (JIT).” from the nerfacc repo. So, do I need to wait for a long time for the first run of your code?

Loping151 commented 3 weeks ago

Yes. It requires some time to build the first time you run nerfacc, but there should be tips in the command line output informing nerfacc is building.

Loping151 commented 3 weeks ago

image It looks like this and takes only minutes. But anyway, I just set up an env with command in the readme and it runs successfully on a machine with 2080Ti and AMD CPU—most package latest version.

Rashfu commented 3 weeks ago

Emmm, I remember seeing it the first time I set up the environment, but I pressed Ctrl+C to cancel the code execution back then, and I have been having this issue ever since. (That's the problem)

Update: Find similar issue in nerfacc repo here. Problem Solved! Thanks for your patience!