Python Environment Installation
This section presents the following contents:
Install Isaac Sim using PIP in a (virtual) Python environment
Using the Isaac Sim Default Python Environment
Install Isaac Sim using PIP
Warning
The feature described in this section is in an experimental stage and errors or unexpected results may occur!
Note
Isaac Sim requires Python 3.10. Visit the Python download page to get a suitable version.
On Linux, GLIBC 2.34+ (
manylinux_2_34_x86_64
) version compatibility is required for pip to discover and install the Python packages. Check the GLIBC version using the commandldd --version
.
Isaac Sim provides several Python namespace packages that allow to compose an Isaac Sim app by parts using a Python package manager (e.g.: pip). The following tables list the available Isaac Sim - Python packages.
Python package name |
Description |
---|---|
|
A metapackage that installs the complete version (all the other main Python packages) of Isaac Sim |
|
Isaac Sim kernel |
|
Isaac Sim components for application setup |
|
Isaac Sim components for asset import, creation and management |
|
Isaac Sim components for benchmarking |
|
Isaac Sim components for scripting and code edition |
|
Isaac Sim core extensions and APIs |
|
Isaac Sim components to enable the Cortex decision framework for intelligent robot behavior |
|
Isaac Sim examples |
|
Isaac Sim components for the graphical user interface (GUI) |
|
Isaac Sim components to enable the Replicator framework for synthetic data generation pipelines and services |
|
Isaac Sim components for reinforcement learning |
|
Isaac Sim’s robot models and APIs |
|
Isaac Sim components for motion generation pipelines and algorithms |
|
Isaac Sim components for robot setup |
|
Isaac Sim components for ROS 1 system integration |
|
Isaac Sim components for ROS 2 system integration |
|
Isaac Sim components to simulate sensors |
|
Isaac Sim components for storage system |
|
Isaac Sim templates |
|
Isaac Sim components for testings |
|
Isaac Sim utilities |
Python package name |
Description |
---|---|
|
Kit extensions cache for Isaac Sim |
|
Kit-SDK extensions cache for Isaac Sim |
|
Physics extensions cache for Isaac Sim |
Installation using PIP
Note
Installation using Python package managers does not include Nucleus. If Nucleus is needed, the recommended way to get it is via the Omniverse Launcher.
Create and activate the virtual environment (optional, but highly recommended):
python3.10 -m venv env_isaacsim source env_isaacsim/bin/activate
python3.10 -m venv env_isaacsim env_isaacsim\Scripts\activate
conda create -n env_isaacsim python=3.10 conda activate env_isaacsim
Make sure pip is updated (
pip install --upgrade pip
) after activating the environment and before proceeding with installation.Install Isaac Sim - Python packages
pip install isaacsim==4.2.0.2 --extra-index-url https://pypi.nvidia.com
pip install isaacsim-PACKAGE_SUBNAME==4.2.0.2 --extra-index-url https://pypi.nvidia.com
!pip install isaacsim==4.2.0.2 --extra-index-url https://pypi.nvidia.com
!pip install isaacsim-PACKAGE_SUBNAME==4.2.0.2 --extra-index-url https://pypi.nvidia.com
The installation path can be queried with the command
pip show isaacsim
.Install Isaac Sim - Python packages cached extension dependencies (optional)
Isaac Sim depends on several Omniverse extensions that are not included in the main python packages. These dependencies will be downloaded from the Omniverse registry, at demand, if they are not found at runtime. However, it is possible to install these dependencies manually, through the following command, and thus avoid future downloads from the registers.
pip install isaacsim-extscache-physics==4.2.0.2 isaacsim-extscache-kit==4.2.0.2 isaacsim-extscache-kit-sdk==4.2.0.2 --extra-index-url https://pypi.nvidia.com
!pip install isaacsim-extscache-physics==4.2.0.2 isaacsim-extscache-kit==4.2.0.2 isaacsim-extscache-kit-sdk==4.2.0.2 --extra-index-url https://pypi.nvidia.com
Running Isaac Sim
Note
It is necessary to agree and accept the Omniverse License Agreement (EULA) in order to use Isaac Sim. The EULA can be accepted in two ways, through system environment variables or by responding to a prompt:
The first time isaacsim is imported, a prompt will ask about accepting the EULA at runtime. Once the EULA is accepted, it should not appear on subsequent Isaac Sim calls. If the EULA is not accepted, the execution will be terminated.
By installing or using Omniverse Kit, I agree to the terms of NVIDIA OMNIVERSE LICENSE AGREEMENT (EULA)
in https://docs.omniverse.nvidia.com/platform/latest/common/NVIDIA_Omniverse_License_Agreement.html
Do you accept the EULA? (Yes/No):
By setting the OMNI_KIT_ACCEPT_EULA
environment variable to YES
, Y
or 1
(case insensitive), the interpreter will not prompt for EULA acceptance at runtime.
export OMNI_KIT_ACCEPT_EULA=YES
set OMNI_KIT_ACCEPT_EULA=YES
Add the following statements at the beginning of the script or notebook cell before importing isaacsim
:
import os
os.environ["OMNI_KIT_ACCEPT_EULA"] = "YES"
Note
First time running Isaac Sim may take several minutes due to the download of dependency extensions from the Omniverse registry.
To avoid this, it is possible to install the packages with the cached extensions (isaacsim-extscache-physics
, isaacsim-extscache-kit
and isaacsim-extscache-kit-sdk
) as described in the installation section (step number 3).
Warning
Some Python packages required by some Isaac Sim extensions or examples may not be included as dependencies of Isaac Sim - Python packages. However, it is possible to install them using the command pip install DEPENDENCY_NAME
.
Running Python Scripts
Run the following command to execute a Python script in the (virtual) environment:
python path/to/script.py
Running in Interactive Interpreter / Notebooks
When running in interactive interpreter or notebooks (e.g.: Jupyter, Colab, etc.), it is necessary to first import the isaacsim
package in order to access the SimulationApp class.
For convenience, the isaacsim
package exposes that class (implemented in the omni.isaac.kit
extension).
from isaacsim import SimulationApp simulation_app = SimulationApp({"headless": True}) ## perform any Isaac Sim / Omniverse imports after instantiating the classimport isaacsim from omni.isaac.kit import SimulationApp simulation_app = SimulationApp({"headless": True}) ## perform any Isaac Sim / Omniverse imports after instantiating the classWarning
Calling the
SimulationApp.close
method on notebooks causes a kernel interruption and termination.
Launching Isaac Sim Experiences
The installation registers a Python entry point (isaacsim
) that allow to launch experience (.kit
) files.
isaacsim path/to/experience_file.kit [arguments]Hint
The experience can be defined by its:
absolute or relative file path.
file name, with or without the
.kit
file extension. Search path areisaacsim/apps
andomni/apps
The following table lists the most common Isaac Sim - Python packages commands to launch experiences:
Command |
Description |
---|---|
|
Standard Isaac Sim app, as it is executed from the Launcher. |
|
Headless livestreaming Isaac Sim natively. See Omniverse Streaming Client for more details. |
|
Headless livestreaming Isaac Sim using the WebRTC protocol. See WebRTC Browser Client for more details. |
Default Python Environment
It is possible to run Isaac Sim natively from Python rather than as a standalone executable. This provides more low-level control over how to initialize, setup, and manage an Omniverse application. Isaac Sim provides a built-in Python 3.10 environment that packages can use, similar to a system-level Python install. We recommend using this Python environment when running the Python scripts.
Run the following from the Isaac Sim root folder to start a Python script in this environment:
./python.sh path/to/script.py
Note
You can open a terminal directly at the Isaac Sim root folder from the Isaac Sim App Selector.
If you need to install additional packages via pip, run the following:
./python.sh -m pip install name_of_package_here
Note
On Windows use python.bat instead of python.sh.
See also
See the Python Environment manual for more details about python.sh
.
Jupyter Notebook Setup
Jupyter Notebooks that use Isaac Sim can be executed as follows:
./jupyter_notebook.sh path/to/notebook.ipynb
Note
The first time you run
jupyter_notebook.sh
, it installs the Jupyter Notebook package into the Isaac Sim Python environment, this may take several minutes.
Note
Jupyter Notebook is supported on Linux only.
See also
See the Jupyter Notebooks documentation for more details.
Visual Studio Code Support
The Isaac Sim package provides a .vscode
workspace with a pre-configured environment
that provides the following:
Launch configurations for running in standalone Python mode, or the interactive GUI
An environment for Python auto-complete
You can open this workspace by opening the main Isaac Sim package folder in Visual Studio Code (VSCode).
Note
Using Visual Studio Code when going through tutorials and examples is recommended.
See also
See the Visual Studio Code (VSCode) Support documentation for details about the VSCode workspace.
Advanced: Running in Docker
Start the Docker container following the instructions in Container Deployment up to step 7.
After the Isaac Sim container is running, you can run a Python script or Jupiter Notebook from the sections above.
Note
You can install additional packages via pip:
./python.sh -m pip install name_of_package_here
See Save Docker Image for committing the image and making the Python setup installation persistent.
Advanced: Running with Anaconda
Create a new environment with the following command:
conda env create -f environment.yml conda activate isaac-sim
If you have an existing conda environment, ensure that the packages in environment.yml
are
installed. Alternatively, you can delete and re-create your conda environment as follows:
conda remove --name isaac-sim --all conda env create -f environment.yml conda activate isaac-sim
Finally, you must set up environment variables so that Isaac Sim Python packages are located correctly. On Linux, you can do this as follows:
source setup_conda_env.sh
You can then run samples as follows in the isaac-sim
conda env:
python path/to/script.py
Note
If you are using the isaac-sim
Anaconda environment, use python
instead of python.sh
to run the samples.