Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sync main branch #4

Merged
merged 20 commits into from
Oct 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
225a896
Updates pre-merge and post-merge CI (#1118)
nv-apoddubny Oct 7, 2024
c186add
Adds buildspec for mirroring job (#1177)
nv-apoddubny Oct 8, 2024
c81550a
Fix Cartpole Manager-based Vision-Based Environment Task Name in Docs…
glvov-bdai Oct 8, 2024
d18f0c2
Fixes Isaac Sim executable on pip installation (#1172)
Toni-SM Oct 8, 2024
4a773d9
Fixes the event for randomizing rigid body material (#1140)
pascal-roth Oct 9, 2024
f6741f3
Adds configuration classes for spawning different assets at prim path…
Mayankm96 Oct 9, 2024
c8e6a32
Moves codebuild pipeline files to `.aws` directory (#1196)
nv-apoddubny Oct 10, 2024
5f81301
Fixes the ray_caster_camera tutorial script when saving the data (#1198)
mpgussert Oct 10, 2024
73c47e4
Fixes running the docker container when the DISPLAY env variable is n…
GiulioRomualdi Oct 10, 2024
cb9fee6
Fixes default joint pos when setting joint limits (#1040)
kellyguo11 Oct 10, 2024
92dcb8c
Adds benchmark script to measure robot loading (#1195)
Mayankm96 Oct 11, 2024
a972182
Fixes formatting issues in the robot loading benchmark script
Mayankm96 Oct 11, 2024
fb72d92
Fixes device propogation for noise and adds noise tests (#1175)
jtigue-bdai Oct 12, 2024
cc7112c
Removes extension startup messages from the Simulation App (#1217)
Mayankm96 Oct 12, 2024
1b8943c
Removes additional sbatch and fixes default profile in cluster deploy…
pascal-roth Oct 13, 2024
f879aa6
Fixes the checkpoint loading error in RSL-RL training script (#1210)
bearpaw Oct 13, 2024
8ee6c97
Makes pre and post merge pipelines more flexible on the Isaac SIM bas…
nv-apoddubny Oct 14, 2024
94f4610
Disables backward pass compilation of warp kernels (#1222)
Mayankm96 Oct 14, 2024
69df26b
Switches from `carb` to `omni.log` for logging (#1215)
Mayankm96 Oct 14, 2024
517c4c1
Excludes cache files from vscode explorer (#1131)
Divelix Oct 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .aws/mirror-buildspec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
version: 0.2

phases:
install:
runtime-versions:
nodejs: 14
pre_build:
commands:
- git config --global user.name "Isaac LAB CI Bot"
- git config --global user.email "[email protected]"
build:
commands:
- git remote set-url origin https://github.com/${TARGET_REPO}.git
- git checkout $SOURCE_BRANCH
- git push --force https://[email protected]/${TARGET_REPO}.git $SOURCE_BRANCH:$TARGET_BRANCH
44 changes: 44 additions & 0 deletions .aws/postmerge-ci-buildspec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
version: 0.2

phases:
build:
commands:
- echo "Building and pushing Docker image"
- |
# Determine branch name or use fallback
if [ -n "$CODEBUILD_WEBHOOK_HEAD_REF" ]; then
BRANCH_NAME=$(echo $CODEBUILD_WEBHOOK_HEAD_REF | sed 's/refs\/heads\///')
elif [ -n "$CODEBUILD_SOURCE_VERSION" ]; then
BRANCH_NAME=$CODEBUILD_SOURCE_VERSION
else
BRANCH_NAME="unknown"
fi

# Replace '/' with '-' and remove any invalid characters for Docker tag
SAFE_BRANCH_NAME=$(echo $BRANCH_NAME | sed 's/[^a-zA-Z0-9._-]/-/g')

# Use "latest" if branch name is empty or only contains invalid characters
if [ -z "$SAFE_BRANCH_NAME" ]; then
SAFE_BRANCH_NAME="latest"
fi

# Get the git repository short name
REPO_SHORT_NAME=$(basename -s .git `git config --get remote.origin.url`)
if [ -z "$REPO_SHORT_NAME" ]; then
REPO_SHORT_NAME="verification"
fi

# Combine repo short name and branch name for the tag
COMBINED_TAG="${REPO_SHORT_NAME}-${SAFE_BRANCH_NAME}"

docker login -u \$oauthtoken -p $NGC_TOKEN nvcr.io
docker build -t $IMAGE_NAME:$COMBINED_TAG \
--build-arg ISAACSIM_BASE_IMAGE_ARG=$ISAACSIM_BASE_IMAGE \
--build-arg ISAACSIM_VERSION_ARG=$ISAACSIM_BASE_VERSION \
--build-arg ISAACSIM_ROOT_PATH_ARG=/isaac-sim \
--build-arg ISAACLAB_PATH_ARG=/workspace/isaaclab \
--build-arg DOCKER_USER_HOME_ARG=/root \
-f docker/Dockerfile.base .
docker push $IMAGE_NAME:$COMBINED_TAG
docker tag $IMAGE_NAME:$COMBINED_TAG $IMAGE_NAME:$COMBINED_TAG-b$CODEBUILD_BUILD_NUMBER
docker push $IMAGE_NAME:$COMBINED_TAG-b$CODEBUILD_BUILD_NUMBER
84 changes: 84 additions & 0 deletions .aws/premerge-ci-buildspec.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
version: 0.2

phases:
pre_build:
commands:
- echo "Launching EC2 instance to run tests"
- |
INSTANCE_ID=$(aws ec2 run-instances \
--image-id ami-0b3a9d48380433e49 \
--count 1 \
--instance-type g5.2xlarge \
--key-name production/ssh/isaaclab \
--security-group-ids sg-02617e4b8916794c4 \
--subnet-id subnet-0907ceaeb40fd9eac \
--block-device-mappings '[{"DeviceName":"/dev/sda1","Ebs":{"VolumeSize":500}}]' \
--output text \
--query 'Instances[0].InstanceId')
- aws ec2 wait instance-running --instance-ids $INSTANCE_ID
- |
EC2_INSTANCE_IP=$(aws ec2 describe-instances \
--filters "Name=instance-state-name,Values=running" "Name=instance-id,Values=$INSTANCE_ID" \
--query 'Reservations[*].Instances[*].[PrivateIpAddress]' \
--output text)
- mkdir -p ~/.ssh
- |
aws ec2 describe-key-pairs --include-public-key --key-name production/ssh/isaaclab \
--query 'KeyPairs[0].PublicKey' --output text > ~/.ssh/id_rsa.pub
- |
aws secretsmanager get-secret-value --secret-id production/ssh/isaaclab \
--query SecretString --output text > ~/.ssh/id_rsa
- chmod 400 ~/.ssh/id_*
- echo "Host $EC2_INSTANCE_IP\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- |
aws ec2-instance-connect send-ssh-public-key \
--instance-id $INSTANCE_ID \
--availability-zone us-west-2a \
--ssh-public-key file://~/.ssh/id_rsa.pub \
--instance-os-user ubuntu

build:
commands:
- echo "Running tests on EC2 instance"
- SRC_DIR=$(basename $CODEBUILD_SRC_DIR)
- cd ..
- |
bash -c '
function retry_scp() {
local retries=5
local wait_time=30
local count=0
while [ $count -lt $retries ]; do
sleep $wait_time
scp -r $SRC_DIR ubuntu@$EC2_INSTANCE_IP:~
if [ $? -eq 0 ]; then
echo "SCP command succeeded"
return 0
fi
count=$((count + 1))
echo "SCP command failed. Retrying in $wait_time seconds..."
done
echo "SCP command failed after $retries attempts."
return 1
}
retry_scp
'
- ssh ubuntu@$EC2_INSTANCE_IP "docker login -u \\\$oauthtoken -p $NGC_TOKEN nvcr.io"
- |
ssh ubuntu@$EC2_INSTANCE_IP "
cd $SRC_DIR
DOCKER_BUILDKIT=1 docker build -t isaac-lab-dev \
--build-arg ISAACSIM_BASE_IMAGE_ARG=$ISAACSIM_BASE_IMAGE \
--build-arg ISAACSIM_VERSION_ARG=$ISAACSIM_BASE_VERSION \
--build-arg ISAACSIM_ROOT_PATH_ARG=/isaac-sim \
--build-arg ISAACLAB_PATH_ARG=/workspace/isaaclab \
--build-arg DOCKER_USER_HOME_ARG=/root \
-f docker/Dockerfile.base .
docker run --rm --entrypoint bash --gpus all --network=host \
--name isaac-lab-test isaac-lab-dev ./isaaclab.sh -t && exit \$?
"

post_build:
commands:
- echo "Terminating EC2 instance"
- aws ec2 terminate-instances --instance-ids $INSTANCE_ID
12 changes: 0 additions & 12 deletions .github/workflows/postmerge-ci-buildspec.yml

This file was deleted.

50 changes: 0 additions & 50 deletions .github/workflows/premerge-ci-buildspec.yml

This file was deleted.

5 changes: 5 additions & 0 deletions .vscode/tools/settings.template.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{
"files.exclude": {
"**/.mypy_cache": true,
"**/__pycache__": true,
"**/*.egg-info": true
},
"files.associations": {
"*.tpp": "cpp",
"*.kit": "toml",
Expand Down
2 changes: 2 additions & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ Guidelines for modifications:
* Chenyu Yang
* David Yang
* Gary Lvov
* Giulio Romualdi
* HoJin Jeon
* Jean Tampon
* Jia Lin Yuan
Expand All @@ -62,6 +63,7 @@ Guidelines for modifications:
* Rosario Scalise
* Shafeef Omar
* Vladimir Fokow
* Wei Yang
* Xavier Nal
* Yang Jin
* Zhengyu Zhang
Expand Down
2 changes: 2 additions & 0 deletions docker/.env.base
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

# Accept the NVIDIA Omniverse EULA by default
ACCEPT_EULA=Y
# NVIDIA Isaac Sim base image
ISAACSIM_BASE_IMAGE=nvcr.io/nvidia/isaac-sim
# NVIDIA Isaac Sim version to use (e.g. 4.2.0)
ISAACSIM_VERSION=4.2.0
# Derived from the default path in the NVIDIA provided Isaac Sim container
Expand Down
3 changes: 2 additions & 1 deletion docker/Dockerfile.base
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
# Please check above link for license information.

# Base image
ARG ISAACSIM_BASE_IMAGE_ARG
ARG ISAACSIM_VERSION_ARG
FROM nvcr.io/nvidia/isaac-sim:${ISAACSIM_VERSION_ARG} AS base
FROM ${ISAACSIM_BASE_IMAGE_ARG}:${ISAACSIM_VERSION_ARG} AS base
ENV ISAACSIM_VERSION=${ISAACSIM_VERSION_ARG}

# Set default RUN shell to bash
Expand Down
18 changes: 11 additions & 7 deletions docker/cluster/cluster_interface.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,9 @@ submit_job() {

case $CLUSTER_JOB_SCHEDULER in
"SLURM")
CMD=sbatch
job_script_file=submit_job_slurm.sh
;;
"PBS")
CMD=bash
job_script_file=submit_job_pbs.sh
;;
*)
Expand All @@ -75,7 +73,7 @@ submit_job() {
;;
esac

ssh $CLUSTER_LOGIN "cd $CLUSTER_ISAACLAB_DIR && $CMD $CLUSTER_ISAACLAB_DIR/docker/cluster/$job_script_file \"$CLUSTER_ISAACLAB_DIR\" \"isaac-lab-$profile\" ${@}"
ssh $CLUSTER_LOGIN "cd $CLUSTER_ISAACLAB_DIR && bash $CLUSTER_ISAACLAB_DIR/docker/cluster/$job_script_file \"$CLUSTER_ISAACLAB_DIR\" \"isaac-lab-$profile\" ${@}"
}

#==
Expand Down Expand Up @@ -162,11 +160,17 @@ case $command in
scp $SCRIPT_DIR/exports/isaac-lab-$profile.tar $CLUSTER_LOGIN:$CLUSTER_SIF_PATH/isaac-lab-$profile.tar
;;
job)
[ $# -ge 1 ] && profile=$1 && shift
if [ $# -ge 1 ]; then
passed_profile=$1
if [ -f ".env.$passed_profile" ]; then
profile=$passed_profile
shift
fi
fi
job_args="$@"
echo "Executing job command"
[ -n "$profile" ] && echo "Using profile: $profile"
[ -n "$job_args" ] && echo "Job arguments: $job_args"
echo "[INFO] Executing job command"
[ -n "$profile" ] && echo -e "\tUsing profile: $profile"
[ -n "$job_args" ] && echo -e "\tJob arguments: $job_args"
source $SCRIPT_DIR/.env.cluster
# Get current date and time
current_datetime=$(date +"%Y%m%d_%H%M%S")
Expand Down
1 change: 1 addition & 0 deletions docker/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ services:
context: ../
dockerfile: docker/Dockerfile.base
args:
- ISAACSIM_BASE_IMAGE_ARG=${ISAACSIM_BASE_IMAGE}
- ISAACSIM_VERSION_ARG=${ISAACSIM_VERSION}
- ISAACSIM_ROOT_PATH_ARG=${DOCKER_ISAACSIM_ROOT_PATH}
- ISAACLAB_PATH_ARG=${DOCKER_ISAACLAB_PATH}
Expand Down
3 changes: 1 addition & 2 deletions docker/utils/container_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,7 @@ def enter(self):
"exec",
"--interactive",
"--tty",
"-e",
f"DISPLAY={os.environ['DISPLAY']}",
*(["-e", f"DISPLAY={os.environ['DISPLAY']}"] if "DISPLAY" in os.environ else []),
f"{self.container_name}",
"bash",
])
Expand Down
Binary file added docs/source/_static/demos/multi_asset.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
25 changes: 25 additions & 0 deletions docs/source/api/lab/omni.isaac.lab.sim.spawners.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
sensors
from_files
materials
wrappers

.. rubric:: Classes

Expand Down Expand Up @@ -302,3 +303,27 @@ Physical Materials
.. autoclass:: DeformableBodyMaterialCfg
:members:
:exclude-members: __init__, func

Wrappers
--------

.. automodule:: omni.isaac.lab.sim.spawners.wrappers

.. rubric:: Classes

.. autosummary::

MultiAssetSpawnerCfg
MultiUsdFileCfg

.. autofunction:: spawn_multi_asset

.. autoclass:: MultiAssetSpawnerCfg
:members:
:exclude-members: __init__, func

.. autofunction:: spawn_multi_usd_file

.. autoclass:: MultiUsdFileCfg
:members:
:exclude-members: __init__, func
11 changes: 11 additions & 0 deletions docs/source/how-to/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,17 @@ a fixed base robot. This guide goes over the various considerations and steps to

make_fixed_prim

Spawning Multiple Assets
------------------------

This guide explains how to import and configure different assets in each environment. This is
useful when you want to create diverse environments with different objects.

.. toctree::
:maxdepth: 1

multi_asset_spawning

Saving Camera Output
--------------------

Expand Down
Loading