ubuntu 20.04 安装mujoco 210

 环境参数:

 

 考虑配置环境的玄学,就不写过程了,下面就是参考的链接。

参考链接:

  • mujoco环境变量报错:Missing path to your environment variable._BBJG_001的博客-CSDN博客_mujoco 环境变量
  • Ubuntu 安装mujoco_李峻枫的博客-CSDN博客_ubuntu安装mujoco
  • 如何在 Ubuntu 18.04 LTS 系统中安装多版本 GCC 编译器 - 系统极客
    • 修改默认的gcc版本 sudo update-alternatives --config gcc
  • 安装中遇到的问题 安装mujoco_py遇到的一些问题与解决方法,如command ‘gcc‘ failed with exit status 1_陈三章的博客-CSDN博客_安装mujoco_py
    • 使用mujoco需要安装GLEW和patchelf
      • GLEW 在Ubuntu下面安装GLEW_专心规控的小段的博客-CSDN博客_glew安装
      • patchelf No such file or directory: 'patchelf' on mujoco-py installation · Issue #652 · openai/mujoco-py · GitHub
    • 解决ImportError:lib***.so--cannot open shared object file: No such file or directory - 简书
  • 安装脚本
    wget https://github.com/deepmind/mujoco/releases/download/2.1.1/mujoco-2.1.1-linux-x86_64.tar.gz
    tar -zxvf mujoco-2.1.1-linux-x86_64.tar.gz 
    mkdir ~/.mujoco
    mv mujoco-2.1.1  ~/.mujoco/mujoco210
    ln -s ~/.mujoco/mujoco210/lib/libglewegl.so ~/.mujoco/mujoco210/bin/libglewegl.so
    ln -s ~/.mujoco/mujoco210/lib/libmujoco.so ~/.mujoco/mujoco210/bin/libmujoco210.so
    echo "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/.mujoco/mujoco210/bin" >> ~/.bashrc
    echo "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/nvidia" >> ~/.bashrc
    echo "export LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libGLEW.so" >> ~/.bashrc
    sudo apt-get install libglew-dev
    sudo apt-get install libegl-dev libgl-dev libgl1-mesa-dev libgles-dev libgles1 libglew2.1 libglu1-mesa-dev libglvnd-dev libglx-dev libopengl-dev
    sudo apt-get install -y patchelf
    pip install mujoco_py

你可能感兴趣的:(机器学习,ubuntu,linux,运维)