Skip to main content

Musculoskeletal environments simulated in MuJoCo

Project description

Support Ukraine PyPI Documentation Status PyPI - License PRs Welcome Downloads Open In Colab Slack Twitter Follow

MyoSuite is a collection of musculoskeletal environments and tasks simulated with the MuJoCo physics engine and wrapped in the OpenAI gym API to enable the application of Machine Learning to bio-mechanic control problems.

Full task details | Baselines | Documentation | Tutorials

Below is an overview of the tasks in the MyoSuite.

TasksALL

Getting Started

You will need Python 3.8 or later versions.

It is recommended to use Miniconda and to create a separate environment with:

conda create --name myosuite python=3.8
conda activate myosuite

It is possible to install MyoSuite with:

pip install -U myosuite

for advanced installation, see here.

Test your installation using the following command (this will return also a list of all the current environments):

python -m myosuite.tests.test_myo

You can also visualize the environments with random controls using the command below:

python -m myosuite.utils.examine_env --env_name myoElbowPose1D6MRandom-v0

NOTE: On MacOS, we moved to mujoco native launch_passive which requires that the Python script be run under mjpython:

mjpython -m myosuite.utils.examine_env --env_name myoElbowPose1D6MRandom-v0

Examples

It is possible to create and interface with MyoSuite environments just like any other OpenAI gym environments. For example, to use the myoElbowPose1D6MRandom-v0 environment, it is possible simply to run: Open In Colab

from myosuite.utils import gym
env = gym.make('myoElbowPose1D6MRandom-v0')
env.reset()
for _ in range(1000):
  env.mj_render()
  env.step(env.action_space.sample()) # take a random action
env.close()

You can find tutorials and the ICRA2023 Colab Tutorial Open In Colab on how to load MyoSuite models/tasks, train them, and visualize their outcome. Also, you can find baselines to test some pre-trained policies.

License

MyoSuite is licensed under the Apache License.

Citation

If you find this repository useful in your research, please consider giving a star ⭐ and cite our arXiv paper by using the following BibTeX entrys.

@Misc{MyoSuite2022,
  author =       {Vittorio, Caggiano AND Huawei, Wang AND Guillaume, Durandau AND Massimo, Sartori AND Vikash, Kumar},
  title =        {MyoSuite -- A contact-rich simulation suite for musculoskeletal motor control},
  publisher = {arXiv},
  year = {2022},
  howpublished = {\url{https://github.com/myohub/myosuite}},
  year =         {2022}
  doi = {10.48550/ARXIV.2205.13600},
  url = {https://arxiv.org/abs/2205.13600},
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

MyoSuite-2.3.0.tar.gz (52.4 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

MyoSuite-2.3.0-py3-none-any.whl (52.6 MB view details)

Uploaded Python 3

File details

Details for the file MyoSuite-2.3.0.tar.gz.

File metadata

  • Download URL: MyoSuite-2.3.0.tar.gz
  • Upload date:
  • Size: 52.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.9.19

File hashes

Hashes for MyoSuite-2.3.0.tar.gz
Algorithm Hash digest
SHA256 42ed7d512d61508ebafae55a37e5b7ec198050760dfa0fcac2424eca25466604
MD5 bb158ade5622a08d38766ff0ee0cf6a4
BLAKE2b-256 c5f77c54a6a95b2b88b801eec765c4d5584736eabcb38deaa40a3af54f41e92c

See more details on using hashes here.

File details

Details for the file MyoSuite-2.3.0-py3-none-any.whl.

File metadata

  • Download URL: MyoSuite-2.3.0-py3-none-any.whl
  • Upload date:
  • Size: 52.6 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.9.19

File hashes

Hashes for MyoSuite-2.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c2f274fdf563e8bd59f3637d21755c449945512039bb329b0855efd770674b52
MD5 b91c9cb1add87cacdfb124ffc124d632
BLAKE2b-256 af2d4e53d304a46b43e369bac99a64b0225ddba17ed3fe432a7f354d60dec3dc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page