跳到主要内容

🚀 Install GBC

Now that you have prepared your environment, let's install the GBC (Generalized Biped Controller) framework. This section will guide you through cloning the repository, installing the main package, and setting up the optional training components.

📋 Before You Start

Make sure you have completed all the steps in the Prerequisites section and have activated your gbc conda environment:

conda activate gbc

1. 📥 Clone GBC Repository

Create a dedicated directory for GBC and clone the main repository with all submodules:

# Create and navigate to GBC directory
mkdir GBC && cd GBC

# Clone GBC repository with all submodules
git clone https://github.com/sjtu-mvasl-robotics/GBC.git --recursive
🔗 Why --recursive?

The --recursive flag ensures that all Git submodules (including the training library rsl_rl) are automatically downloaded. This saves you from manually initializing submodules later.

2. 🔧 Install GBC Package

Navigate to the GBC directory and install the package in development mode:

cd GBC
pip install -e .
💡 Development Mode Installation

The -e flag installs GBC in "editable" or "development" mode, which means:

  • Changes to the source code are immediately reflected without reinstalling
  • Perfect for development and experimentation
  • Links to the source directory instead of copying files

3. 🏃‍♂️ Install rsl_rl (Optional)

rsl_rl is GBC's training library, added as a Git submodule. You can install it using one of the following methods. Skip this step if you don't plan to train models.

🤔 When do you need rsl_rl?
  • ✅ Required: For training new models or fine-tuning existing ones
  • 🔄 Optional: If you only plan to use pre-trained models or data processing features

If you used the --recursive flag when cloning, the library should be available in dependencies/rsl_rl:

# Navigate to the rsl_rl submodule directory
cd dependencies/rsl_rl

# Install in development mode
pip install -e .

# Return to GBC root directory
cd ../..

Method 2: Install Latest Release

If you want the most recent version of rsl_rl (rather than the version tied to your current GBC release):

# Clone the latest rsl_rl repository
git clone https://github.com/sjtu-mvasl-robotics/rsl_rl.git

# Navigate and install
cd rsl_rl
pip install -e .

# Return to previous directory
cd ..

4. 🔍 Verify rsl_rl Installation

It's important to ensure that our custom rsl_rl correctly overrides the version that Isaac Lab automatically installed.

Check rsl_rl Version

Run the following command to check if rsl_rl has the -dev suffix:

python -c "import rsl_rl; print(f'rsl_rl version: {rsl_rl.__version__}')"

Expected output: rsl_rl version: X.X.X-dev (with -dev suffix)

Fix Installation if Needed

If you see a version without the -dev suffix, it means Isaac Lab's version is still being used. Fix this by:

# Uninstall the Isaac Lab version
pip uninstall rsl_rl -y

# Reinstall our custom version
cd dependencies/rsl_rl # or your rsl_rl directory
pip install -e .
cd ../..

# Verify again
python -c "import rsl_rl; print(f'rsl_rl version: {rsl_rl.__version__}')"

5. ✅ Verify GBC Installation

Finally, let's verify that GBC is properly installed and all components are working.

Method 1: Quick Import Test

Test the basic import functionality:

python -c "import GBC; print('✅ GBC import successful!')"

Method 2: Run Installation Test Script

GBC provides a comprehensive installation test script:

# Run the installation verification script
python test_installation.py

This script will:

  • ✅ Test all core GBC modules
  • ✅ Verify SMPL/SMPLH support libraries
  • ✅ Check Isaac Lab integration (if installed)
  • ✅ Validate rsl_rl installation (if installed)
  • 📊 Provide a detailed installation report

🎉 Success Indicators

If everything is installed correctly, you should see:

✅ GBC Core: OK
✅ SMPL Support: OK
✅ Isaac Lab: OK (if installed)
✅ rsl_rl: OK (if installed)
🎉 Installation Complete!
🎊 Congratulations!

You have successfully installed GBC! You're now ready to:

  • Process motion data
  • Train new models (if rsl_rl is installed)
  • Run experiments and evaluations
  • Explore the GBC ecosystem

Continue to the next section to learn how to configure your robot and start using GBC.

🔧 Troubleshooting

Common Issues

Issue: ModuleNotFoundError: No module named 'GBC'

  • Solution: Make sure you activated the gbc conda environment and installed with pip install -e .

Issue: rsl_rl version doesn't have -dev suffix

  • Solution: Follow the "Fix Installation if Needed" steps in section 4

Issue: Import errors related to SMPL libraries

  • Solution: Ensure you haven't deleted the smpl_libs directory from the Prerequisites setup

Issue: Isaac Lab related errors

  • Solution: Verify Isaac Lab installation and ensure proper permissions (no sudo installation)