Skip to content

Instantly share code, notes, and snippets.

@espresso3389
Last active January 24, 2025 13:10
Show Gist options
  • Save espresso3389/151c6ff86714614d8e917ccc3c87f752 to your computer and use it in GitHub Desktop.
Save espresso3389/151c6ff86714614d8e917ccc3c87f752 to your computer and use it in GitHub Desktop.
Run Hello, Genesis on WSL2 (Ubuntu 24.04)

Run Hello, Genesis on WSL2 (Ubuntu 24.04)

image

Install Python and venv

sudo apt install python python3-venv

Prepare venv and install prerequisites

python -m venv genesis_venv
source genesis_venv/bin/activate
pip install torch torchvision torchaudio

Get Genesis and try to run Hello, Genesis

git clone https://github.com/Genesis-Embodied-AI/Genesis
cd Genesis
python examples/tutorials/hello_genesis.py

Error: MESA: error: ZINK: failed to choose pdev

According to this, mesa on Ubuntu 24.04 is too old; the following lines will install the latest.

sudo add-apt-repository ppa:kisak/kisak-mesa
sudo apt upgrade

Error: OpenGL.error.Error: Attempt to retrieve context when no valid context

And, if you see the error (or the window is completely black), run hello_genesis.py with PYOPENGL_PLATFORM=glx:

PYOPENGL_PLATFORM=glx python examples/tutorials/hello_genesis.py

Warning: [cuda_driver.cpp:load_lib@36] libcuda.so lib not found.

export LD_LIBRARY_PATH=/usr/lib/wsl/lib:$LD_LIBRARY_PATH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment