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

Fix eval finetuned #40

Merged
merged 2 commits into from
Jan 23, 2024
Merged
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
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ repos:
rev: 6.1.0
hooks:
- id: flake8
exclude: ^experiments/
exclude: ^experiments/|^examples/03_eval_finetuned.py
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
Expand Down
13 changes: 12 additions & 1 deletion examples/03_eval_finetuned.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,27 @@
Then run:
pip3 install opencv-python modern_robotics pyrealsense2 h5py_cache pyquaternion pyyaml rospkg pexpect mujoco==2.3.3 dm_control==1.0.9 einops packaging h5py

Finally modify the sys.path.append statement below to add the ACT repo to your path and start a virtual display:
Finally, modify the `sys.path.append` statement below to add the ACT repo to your path.
If you are running this on a head-less server, start a virtual display:
Xvfb :1 -screen 0 1024x768x16 &
export DISPLAY=:1

To run this script, run:
cd examples
python3 03_eval_finetuned.py --filetuned_path=<path_to_finetuned_aloha_checkpoint>
"""
import sys

from absl import app, flags, logging
import gym
import jax
import numpy as np
import wandb

sys.path.append("path/to/your/act")

from envs.aloha_sim_env import AlohaGymEnv # keep this to register ALOHA sim env

from octo.model.octo_model import OctoModel
from octo.utils.gym_wrappers import HistoryWrapper, RHCWrapper, UnnormalizeActionProprio

Expand Down