Open
Description
Intro
Hi!
One of the early MuJoCo developer
My setup
Mac, python, mujoco==3.2.4
What's happening? What did you expect?
When using a virtual file system with mjSpec, there are inconsistencies in the behavior (especially when names with Caps are involved)
Case: when the asset/mesh/file is only the filename
name on disc | name in XML | loads w/ mjSpec? | loads natively? |
---|---|---|---|
cube.stl | Cube.stl | True | True |
cube.stl | cube.stl | True | True |
Cube.stl | Cube.stl | True | True |
Cube.stl | cube.stl | False | True |
Case: when the asset/mesh/file is more complex
name on disc | name in XML | loads w/ mjSpec? | loads natively? |
---|---|---|---|
cube.stl | path/Cube.stl | True | True |
cube.stl | path/cube.stl | True | True |
Cube.stl | path/Cube.stl | False | True |
Cube.stl | path/cube.stl | False | True |
In summary,
- capitalization is not respected natively. Everything works
- capitalization is partially respected in mjSpec
- capitalization behavior depends on how the name is specified
Steps for reproduction
- Unzip the folder
- Run
python test.py
- Change filenames on disc and on XML as specified above.
NOTE:
- When trying out cases with VFS, ensure that the fallback of loading assets from the disc doesn't work otherwise the bug won't highlight.
- This is extremely important as this bug is about discrepancies between VFS and load from the disc.
Recommendation:
The docs around how caps, relative paths, partial paths, etc are handled in VFS are non-existent. Consider updating the docs.
Minimal model for reproduction
See attached
Code required for reproduction
python test.py
Confirmations
- I searched the latest documentation thoroughly before posting.
- I searched previous Issues and Discussions, I am certain this has not been raised before.