Unverified Commit 09c243dc authored by Michael Gussert's avatar Michael Gussert Committed by GitHub

Adds images for the tutorial docs (#827)

# Description

I added images for the tutorials and modified the docs to include them

## Checklist

- [X] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [X] I have made corresponding changes to the documentation
- [X] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] I have updated the changelog and the corresponding version in the
extension's `config/extension.toml` file
- [X] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there

---------
Signed-off-by: 's avatarMichael Gussert <michael@gussert.com>
Signed-off-by: 's avatarKelly Guo <kellyg@nvidia.com>
Co-authored-by: 's avatarKelly Guo <kellyg@nvidia.com>
parent d6dd9035
......@@ -28,6 +28,7 @@ Guidelines for modifications:
* Mayank Mittal
* Nikita Rudin
* Pascal Roth
* Michael Gussert
## Contributors
......
......@@ -145,6 +145,11 @@ Now that we have gone through the code, let's run the script and see the result:
The simulation should be playing, and the stage should be rendering. To stop the simulation,
you can either close the window, or press ``Ctrl+C`` in the terminal.
.. figure:: ../../_static/tutorials/tutorial_create_empty.jpg
:align: center
:figwidth: 100%
:alt: result of create_empty.py
Passing ``--help`` to the above script will show the different command-line arguments added
earlier by the :class:`app.AppLauncher` class. To run the script headless, you can execute the
following:
......
......@@ -144,6 +144,10 @@ envar. If a visualization is desired, we could get one via Isaac's `Native Lives
is currently the only supported method of visualization from within the container. The
process can be killed by pressing ``Ctrl+C`` in the launching terminal.
.. figure:: ../../_static/tutorials/tutorial_launch_app.jpg
:align: center
:figwidth: 100%
:alt: result of launch_app.py
Now, let's look at how :class:`~app.AppLauncher` handles conflicting commands:
......
......@@ -178,6 +178,11 @@ The green cone, which has rigid body physics enabled, should fall and collide wi
plane. The other cones are visual elements and should not move. To stop the simulation, you can close the window,
or press ``Ctrl+C`` in the terminal.
.. figure:: ../../_static/tutorials/tutorial_spawn_prims.jpg
:align: center
:figwidth: 100%
:alt: result of spawn_prims.py
This tutorial provided a foundation for spawning various prims into the scene in Isaac Lab. Although simple, it
demonstrates the basic concepts of scene designing in Isaac Lab and how to use the spawners. In the coming tutorials,
we will now look at how to interact with the scene and the simulation.
......
......@@ -114,6 +114,7 @@ articulation. To update the state inside the buffer, we call the :meth:`assets.A
The Code Execution
~~~~~~~~~~~~~~~~~~
To run the code and see the results, let's run the script from the terminal:
.. code-block:: bash
......@@ -124,6 +125,11 @@ To run the code and see the results, let's run the script from the terminal:
This command should open a stage with a ground plane, lights, and two cart-poles that are moving around randomly.
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal.
.. figure:: ../../_static/tutorials/tutorial_run_articulation.jpg
:align: center
:figwidth: 100%
:alt: result of run_articulation.py
In this tutorial, we learned how to create and interact with a simple articulation. We saw how to set the state
of an articulation (its root and joint state) and how to apply commands to it. We also saw how to update its
buffers to read the latest state from the simulation.
......
......@@ -142,6 +142,12 @@ This should open a stage with a ground plane, lights, and several green cones. T
a random height and settling on to the ground. To stop the simulation, you can either close the window, or press
the ``STOP`` button in the UI, or press ``Ctrl+C`` in the terminal
.. figure:: ../../_static/tutorials/tutorial_run_rigid_object.jpg
:align: center
:figwidth: 100%
:alt: result of run_rigid_object.py
This tutorial showed how to spawn rigid objects and wrap them in a :class:`RigidObject` class to initialize their
physics handles which allows setting and obtaining their state. In the next tutorial, we will see how to interact
with an articulated object which is a collection of rigid objects connected by joints.
......@@ -142,6 +142,8 @@ methods of the entities in the scene.
The Code Execution
~~~~~~~~~~~~~~~~~~
Let's run the script to simulate 32 cartpoles in the scene. We can do this by passing
the ``--num_envs`` argument to the script.
......@@ -152,6 +154,12 @@ the ``--num_envs`` argument to the script.
This should open a stage with 32 cartpoles swinging around randomly. You can use the
mouse to rotate the camera and the arrow keys to move around the scene.
.. figure:: ../../_static/tutorials/tutorial_creating_a_scene.jpg
:align: center
:figwidth: 100%
:alt: result of create_scene.py
In this tutorial, we saw how to use :class:`scene.InteractiveScene` to create a
scene with multiple assets. We also saw how to use the ``num_envs`` argument
to clone the scene for multiple environments.
......
......@@ -207,6 +207,11 @@ To run training for the direct workflow Cartpole environment, we can use the fol
./isaaclab.sh -p source/standalone/workflows/rl_games/train.py --task=Isaac-Cartpole-Direct-v0
.. figure:: ../../_static/tutorials/tutorial_create_direct_workflow.jpg
:align: center
:figwidth: 100%
:alt: result of train.py
All direct workflow tasks have the suffix ``-Direct`` added to the task name to differentiate the implementation style.
......
......@@ -36,7 +36,6 @@ directory.
:emphasize-lines: 47-51, 54-71, 74-108, 111-130, 135-139, 144, 148, 153-154, 160-161
:linenos:
The Code Explained
~~~~~~~~~~~~~~~~~~
......@@ -182,7 +181,6 @@ operations under-the-hood and we want to ensure that the simulation is not slowe
the overhead of PyTorch's autograd engine and gradients are not computed for the simulation
operations.
The Code Execution
~~~~~~~~~~~~~~~~~~
......@@ -192,12 +190,17 @@ To run the base environment made in this tutorial, you can use the following com
./isaaclab.sh -p source/standalone/tutorials/03_envs/create_cartpole_base_env.py --num_envs 32
This should open a stage with a ground plane, light source, and cartpoles. The simulation should be
playing with random actions on the cartpole. Additionally, it opens a UI window on the bottom
right corner of the screen named ``"Isaac Lab"``. This window contains different UI elements that
can be used for debugging and visualization.
.. figure:: ../../_static/tutorials/tutorial_create_manager_base.jpg
:align: center
:figwidth: 100%
:alt: result of create_cartpole_base_env.py
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal where you
started the simulation.
......@@ -213,6 +216,5 @@ directory. For completeness, they can be run using the following commands:
# Quadrupedal locomotion environment with a policy that interacts with the environment
./isaaclab.sh -p source/standalone/tutorials/03_envs/create_quadruped_base_env.py --num_envs 32
In the following tutorial, we will look at the :class:`envs.ManagerBasedRLEnv` class and how to use it
to create a Markovian Decision Process (MDP).
......@@ -168,6 +168,7 @@ such as the reward contribution from individual terms, the termination status of
The Code Execution
~~~~~~~~~~~~~~~~~~
Similar to the previous tutorial, we can run the environment by executing the ``run_cartpole_rl_env.py`` script.
.. code-block:: bash
......@@ -180,6 +181,11 @@ returns more signals that specify the reward and termination status. Additionall
environments reset themselves when they terminate based on the termination criteria specified in the
configuration.
.. figure:: ../../_static/tutorials/tutorial_create_manager_rl_env.jpg
:align: center
:figwidth: 100%
:alt: result of run_cartpole_rl_env.py
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal
where you started the simulation.
......
......@@ -152,6 +152,13 @@ Now that we have gone through the code, let's run the script and see the result:
This should open a stage with everything similar to the :ref:`tutorial-create-manager-rl-env` tutorial.
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal.
.. figure:: ../../_static/tutorials/tutorial_register_environment.jpg
:align: center
:figwidth: 100%
:alt: result of random_agent.py
In addition, you can also change the simulation device from GPU to CPU by setting the value of the ``--device`` flag explicitly:
.. code-block:: bash
......
......@@ -169,6 +169,7 @@ to access the data for the different sensors created in this tutorial:
The Code Execution
~~~~~~~~~~~~~~~~~~
Now that we have gone through the code, let's run the script and see the result:
.. code-block:: bash
......@@ -182,6 +183,11 @@ Additionally, you can switch the viewport to the camera view to see the RGB imag
camera sensor. Please check `here <https://youtu.be/htPbcKkNMPs?feature=shared>`_ for more information
on how to switch the viewport to the camera view.
.. figure:: ../../_static/tutorials/tutorial_add_sensors. jpg
:align: center
:figwidth: 100%
:alt: result of add_sensors_on_robot.py
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal.
While in this tutorial, we went over creating and using different sensors, there are many more sensors
......
......@@ -140,6 +140,7 @@ previous tutorials.
The Code Execution
~~~~~~~~~~~~~~~~~~
Now that we have gone through the code, let's run the script and see the result:
.. code-block:: bash
......@@ -150,4 +151,9 @@ The script will start a simulation with 128 robots. The robots will be controlle
The current and desired end-effector poses should be displayed using frame markers. When the robot reaches
the desired pose, the command should cycle through to the next pose specified in the script.
.. figure:: ../../_static/tutorials/tutorial_task_space_controller.jpg
:align: center
:figwidth: 100%
:alt: result of run_diff_ik.py
To stop the simulation, you can either close the window, or press ``Ctrl+C`` in the terminal.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment