Skip to content

Commit

Permalink
Merge branch 'main' into fix/docs-typos
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhoeller19 authored Sep 23, 2024
2 parents 359cadb + 77e7413 commit c8aaf59
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 5 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/postmerge-ci-buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ phases:
commands:
- echo "Building a docker image"
- docker login -u \$oauthtoken -p $NGC_TOKEN nvcr.io
- docker build -t $IMAGE_NAME:latest-1.1 --build-arg ISAACSIM_VERSION_ARG=4.2.0 --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 build -t $IMAGE_NAME:latest-1.2 --build-arg ISAACSIM_VERSION_ARG=4.2.0 --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 .
- echo "Pushing the docker image"
- docker push $IMAGE_NAME:latest-1.1
- docker tag $IMAGE_NAME:latest-1.1 $IMAGE_NAME:latest-1.1-b$CODEBUILD_BUILD_NUMBER
- docker push $IMAGE_NAME:latest-1.1-b$CODEBUILD_BUILD_NUMBER
- docker push $IMAGE_NAME:latest-1.2
- docker tag $IMAGE_NAME:latest-1.2 $IMAGE_NAME:latest-1.2-b$CODEBUILD_BUILD_NUMBER
- docker push $IMAGE_NAME:latest-1.2-b$CODEBUILD_BUILD_NUMBER
2 changes: 1 addition & 1 deletion .github/workflows/premerge-ci-buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ phases:
pre_build:
commands:
- echo "Launching EC2 instance to run tests"
- INSTANCE_ID=$(aws ec2 run-instances --image-id ami-064d9f428f75cebb1 --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')
- INSTANCE_ID=$(aws ec2 run-instances --image-id ami-0f7f7fb14ee15d5ae --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
Expand Down
45 changes: 45 additions & 0 deletions tools/run_all_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,9 +307,54 @@ def test_all(
return num_failing + num_timing_out == 0


def warm_start_app():
"""Warm start the app to compile shaders before running the tests."""
print("[INFO] Warm starting the simulation app before running tests.")
before = time.time()
# headless experience
warm_start_output = subprocess.run(
[
sys.executable,
"-c",
(
"from omni.isaac.lab.app import AppLauncher; app_launcher = AppLauncher(headless=True);"
" app_launcher.app.close()"
),
],
capture_output=True,
)
if len(warm_start_output.stderr) > 0:
logging.error(f"Error warm starting the app: {str(warm_start_output.stderr)}")
exit(1)

# headless experience with rendering
warm_start_rendering_output = subprocess.run(
[
sys.executable,
"-c",
(
"from omni.isaac.lab.app import AppLauncher; app_launcher = AppLauncher(headless=True,"
" enable_cameras=True); app_launcher.app.close()"
),
],
capture_output=True,
)
if len(warm_start_rendering_output.stderr) > 0:
logging.error(f"Error warm starting the app with rendering: {str(warm_start_rendering_output.stderr)}")
exit(1)

after = time.time()
time_elapsed = after - before
print(f"[INFO] Warm start completed successfully in {time_elapsed:.2f} s")


if __name__ == "__main__":
# parse command line arguments
args = parse_args()

# warm start the app
warm_start_app()

# add tests to skip to the list of tests to skip
tests_to_skip = TESTS_TO_SKIP
tests_to_skip += args.skip_tests
Expand Down

0 comments on commit c8aaf59

Please sign in to comment.