nv-tlabs / ATISS

Code for "ATISS: Autoregressive Transformers for Indoor Scene Synthesis", NeurIPS 2021
Other
258 stars 55 forks source link

Preprocessing error: self.ctx_write_uniform, moderngl.error: invalid uniform size #44

Closed hjjeong closed 6 months ago

hjjeong commented 6 months ago

I met error when executing preprocessing_data.py

Applying threed_front_bedroom filtering
Loading dataset  6812 /  6813
{'translations': (array([-2.7625005,  0.045    , -2.75275  ]), array([2.77844175, 3.6248396 , 2.81854277])), 'sizes': (array([0.0350001 , 0.02000002, 0.012772  ]), array([2.8682  , 1.770065, 1.698315])), 'angles': (array([-3.14159265]), array([3.14159265]))}
Loading dataset with 4004 rooms
2it [00:00,  2.05it/s]
Traceback (most recent call last):
  File "preprocess_data.py", line 271, in <module>
    main(sys.argv[1:])
  File "preprocess_data.py", line 261, in main
    render(
  File "/mnt/storage2/HJJeong/ATISS/scripts/utils.py", line 178, in render
    scene.add(r)
  File "/home/hj/anaconda3/envs/atiss/lib/python3.8/site-packages/simple_3dviz/scenes.py", line 60, in add
    renderable.init(self._ctx)
  File "/home/hj/anaconda3/envs/atiss/lib/python3.8/site-packages/simple_3dviz/renderables/textured_mesh.py", line 197, in init
    self.material = self._material
  File "/home/hj/anaconda3/envs/atiss/lib/python3.8/site-packages/simple_3dviz/renderables/textured_mesh.py", line 229, in material
    self._prog["ambient"].write(self._material.ambient.tobytes())
  File "/home/hj/anaconda3/envs/atiss/lib/python3.8/site-packages/_moderngl.py", line 95, in write
    self.ctx._write_uniform(
_moderngl.Error: invalid uniform size

I have already tried to the following solution, but they cannot solve my problem.

'''
self._Ns = float([
float(l.strip().split()[1:][0])
for l in lines if l.strip().startswith("Ns")
][0])
'''
self._Ns = 400

Please anyone help me.

lichuanx commented 3 months ago

Hi, have you solved the issue

francescosarno commented 1 month ago

Hi, any updates on this?