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

glb converter normal computation error #159

Open
balazsdukai opened this issue Jan 20, 2023 · 0 comments
Open

glb converter normal computation error #159

balazsdukai opened this issue Jan 20, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@balazsdukai
Copy link
Member

Describe the bug

The normal calculation in the glb converter occasionally returns invalid vectors.

cjio version
develop branch d503d03

To Reproduce
run --release -- --metadata /home/balazs/Development/cjio_dbexport/tests/data/output/metadata.city.json --features /home/balazs/Development/cjio_dbexport/tests/data/output --output /data/work/bdukai/3dbasisvoorziening/3dtiles_buildings --format 3dtiles --python-bin /home/balazs/Development/cjio/venv/bin/python --export-grid --cellsize 100 --quadtree-criteria vertices --quadtree-limit 10000 --object-type building-part --object-type building --gltfpack-bin /opt/gltfpack

Expected behavior
Handle the invalid geoms/normals more robustly.

Screenshots

[2023-01-20T12:52:26Z ERROR tyler] 3/20/8 conversion subprocess stdout: 
    Traceback (most recent call last):
      File "/home/balazs/Development/tyler/resources/python/convert_cityjsonfeatures.py", line 82, in <module>
        glb = cm.export2glb(do_triangulate=False)
      File "/home/balazs/Development/cjio/cjio/cityjson.py", line 1576, in export2glb
        glb = convert.to_glb(self, do_triangulate=do_triangulate)
      File "/home/balazs/Development/cjio/cjio/convert.py", line 303, in to_glb
        normals_np = np.concatenate(normals_per_geom)
      File "<__array_function__ internals>", line 200, in concatenate
    ValueError: all the input arrays must have same number of dimensions, but the array at index 0 has 2 dimension(s) and the array at index 1 has 1 dimension(s)

Additional context
See the tyler tests on the 3d basisvoorziening.

@balazsdukai balazsdukai added the bug Something isn't working label Jan 20, 2023
@balazsdukai balazsdukai changed the title glb exporter glb converter normal computation error Jan 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant