Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
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
20 changes: 3 additions & 17 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,30 +62,16 @@ jobs:
echo "MODEL_DIR=$MODEL_DIR" >> "$GITHUB_ENV"
echo "model_dir=$MODEL_DIR" >> "$GITHUB_OUTPUT"

- name: Restore mesh cache
id: meshcache
uses: actions/cache@v4
with:
path: ${{ steps.model.outputs.model_dir }}
key: ${{ runner.os }}-${{ matrix.os }}-${{ matrix.python-version }}-judo_meshes

- name: Download meshes (cache miss)
if: steps.meshcache.outputs.cache-hit != 'true'
- name: Download meshes
env:
MODEL_DIR: ${{ steps.model.outputs.model_dir }}
GITHUB_TOKEN: ${{ github.token }}
run: |
python - <<'PY'
import os
from judo.utils.assets import download_and_extract_meshes
download_and_extract_meshes(extract_root=os.environ["MODEL_DIR"])
from judo.utils.assets import retrieve_model_from_remote
retrieve_model_from_remote("cylinder_push", force=True)
PY

- name: Show cache outcome
run: |
echo "::notice::mesh cache hit = ${{ steps.meshcache.outputs.cache-hit }}"
echo "::notice::MODEL_DIR = ${{ steps.model.outputs.model_dir }}"
ls -R "${{ steps.model.outputs.model_dir }}" | head

- name: Test with pytest
run: pytest -rsx
2 changes: 1 addition & 1 deletion judo/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
from pathlib import Path

PACKAGE_ROOT = Path(__file__).resolve().parent
MODEL_PATH = PACKAGE_ROOT / "models"
DESCRIPTION_CACHE_DIR = "~/.cache/judo_descriptions_cache"
4 changes: 4 additions & 0 deletions judo/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
from hydra.core.config_store import ConfigStore
from omegaconf import DictConfig

from judo.utils.assets import retrieve_description_path_from_remote

# suppress annoying warning from hydra
warnings.filterwarnings(
"ignore",
Expand All @@ -29,6 +31,8 @@
@hydra.main(config_path=str(CONFIG_PATH), config_name="judo_dora_default", version_base="1.3")
def main_app(cfg: DictConfig) -> None:
"""Main function to run judo via a hydra configuration yaml file."""
# Include a download for the default asset to cache the description repository
retrieve_description_path_from_remote(cfg["task"], force=False)
run(cfg)


Expand Down
8 changes: 0 additions & 8 deletions judo/controller/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Copyright (c) 2025 Robotics and AI Institute LLC. All rights reserved.

from judo import MODEL_PATH
from judo.controller.controller import Controller, ControllerConfig, make_controller
from judo.controller.overrides import (
set_default_caltech_leap_cube_overrides,
Expand All @@ -10,13 +9,6 @@
set_default_leap_cube_down_overrides,
set_default_leap_cube_overrides,
)
from judo.utils.assets import download_and_extract_meshes

download_and_extract_meshes(
extract_root=str(MODEL_PATH),
repo="bdaiinstitute/judo",
asset_name="meshes.zip",
)

set_default_caltech_leap_cube_overrides()
set_default_cartpole_overrides()
Expand Down
10 changes: 0 additions & 10 deletions judo/models/xml/README.md

This file was deleted.

25 changes: 0 additions & 25 deletions judo/models/xml/caltech_leap_components/assets.xml

This file was deleted.

Loading
Loading