-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Intro
Hi!
I am a PhD student at Tsinghua University, I use MuJoCo for my research on Reinforcement Learning in Robotics Control.
My setup
M4 Macbook Pro
Environment settings as in https://github.com/google-deepmind/mujoco/blob/main/wasm/README.md
What's happening? What did you expect?
Running the demo with error
Initialization error: TypeError: mujoco.MjModel.loadFromXML is not a function at App.loadModel (app.ts:211:35) at main (app.ts:489:9)
Steps for reproduction
Preparing environment as in the https://github.com/google-deepmind/mujoco/blob/main/wasm/README.md
git clone https://github.com/emscripten-core/emsdk.git ./emsdk/emsdk install 4.0.10 ./emsdk/emsdk activate 4.0.10 source ./emsdk/emsdk_env.sh npm install --prefix ./wasm export PATH="$(pwd)/wasm/node_modules/.bin:$PATH" python3 -m venv .venv source .venv/bin/activate pip install -r python/build_requirements.txt npm run dev:demo --prefix ./wasm
And opening the port in broswer
Minimal model for reproduction
No response
Code required for reproduction
Line 211 in 69179ea
| this.mjModel = mujoco.MjModel.loadFromXML('/working/model.xml'); |
I search the whole mujoco source code folder and I don't find any API in documentation as mujoco.MjModel.loadFromXML. I think it is deprecated, the right one should be mujoco.MjModel.mj_loadXML.
Or there are something I miss when preparing environment?
Confirmations
- I searched the latest documentation thoroughly before posting.
- I searched previous Issues and Discussions, I am certain this has not been raised before.