PJLab-ADG / neuralsim

neuralsim: 3D surface reconstruction and simulation based on 3D neural rendering.
MIT License
582 stars 31 forks source link

lidar-only model extract mesh #34

Open tangtaogo opened 10 months ago

tangtaogo commented 10 months ago

Hi, Thanks for your excellent work! I have trained model with the lidaronly_filterobj.230814.yaml, but when I want to extract mesh:

Traceback (most recent call last):                                                                                                                                                                                                           
  File "code_single/tools/extract_mesh.py", line 157, in <module>
    main_function(bc.parse())
  File "code_single/tools/extract_mesh.py", line 125, in main_function
    extract_mesh(query_surf_fn, query_color_fn, bmin=aabb[:3], bmax=aabb[3:], N=args.N,
  File "/data/code/neuralsim/nr3d_lib/geometry/mesh.py", line 243, in extract_mesh
    colors = batchify_color(query_color_fn, verts.astype(np.float32), normals.astype(np.float32))
  File "/data/code/neuralsim/nr3d_lib/geometry/mesh.py", line 228, in batchify_color
    out_i = query_fn(x, v)
  File "code_single/tools/extract_mesh.py", line 110, in <lambda>
    query_color_fn = lambda x, v: model.forward(
  File "/data/code/neuralsim/nr3d_lib/profile.py", line 550, in <lambda>
    return lambda *args, **kwargs: _ProfileWrap(fn=arg)(*args, **kwargs)
  File "/data/nas_sync/code/neuralsim/nr3d_lib/profile.py", line 496, in __call__
    ret = self.fn(*args, **kwargs)
  File "/data/code/neuralsim/nr3d_lib/models/fields/neus/lotd_neus.py", line 159, in forward
    h_extra=raw_ret['h'], 
KeyError: 'h'

Can you help me?