opentau 0.1.0__tar.gz → 0.1.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. {opentau-0.1.0/src/opentau.egg-info → opentau-0.1.1}/PKG-INFO +7 -4
  2. {opentau-0.1.0 → opentau-0.1.1}/README.md +3 -3
  3. {opentau-0.1.0 → opentau-0.1.1}/pyproject.toml +7 -2
  4. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/__init__.py +1 -0
  5. opentau-0.1.1/src/opentau/scripts/launch.py +79 -0
  6. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/train.py +8 -8
  7. opentau-0.1.1/src/opentau/utils/transformers_patch.py +48 -0
  8. {opentau-0.1.0 → opentau-0.1.1/src/opentau.egg-info}/PKG-INFO +7 -4
  9. {opentau-0.1.0 → opentau-0.1.1}/src/opentau.egg-info/SOURCES.txt +2 -1
  10. opentau-0.1.1/src/opentau.egg-info/entry_points.txt +4 -0
  11. {opentau-0.1.0 → opentau-0.1.1}/src/opentau.egg-info/requires.txt +3 -0
  12. opentau-0.1.0/src/opentau/scripts/launch_train.py +0 -63
  13. opentau-0.1.0/src/opentau.egg-info/entry_points.txt +0 -2
  14. {opentau-0.1.0 → opentau-0.1.1}/LICENSE +0 -0
  15. {opentau-0.1.0 → opentau-0.1.1}/setup.cfg +0 -0
  16. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/__version__.py +0 -0
  17. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/__init__.py +0 -0
  18. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/default.py +0 -0
  19. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/libero.py +0 -0
  20. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/parser.py +0 -0
  21. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/policies.py +0 -0
  22. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/reward.py +0 -0
  23. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/train.py +0 -0
  24. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/configs/types.py +0 -0
  25. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/constants.py +0 -0
  26. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/__init__.py +0 -0
  27. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/backward_compatibility.py +0 -0
  28. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/compute_stats.py +0 -0
  29. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/dataset_mixture.py +0 -0
  30. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/factory.py +0 -0
  31. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/__init__.py +0 -0
  32. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/base.py +0 -0
  33. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/clevr.py +0 -0
  34. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/cocoqa.py +0 -0
  35. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/dummy.py +0 -0
  36. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/pixmo.py +0 -0
  37. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/grounding/vsr.py +0 -0
  38. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/image_writer.py +0 -0
  39. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/lerobot_dataset.py +0 -0
  40. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/online_buffer.py +0 -0
  41. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/push_dataset_to_hub/utils.py +0 -0
  42. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/sampler.py +0 -0
  43. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/standard_data_format_mapping.py +0 -0
  44. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/transforms.py +0 -0
  45. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/utils.py +0 -0
  46. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v2/batch_convert_dataset_v1_to_v2.py +0 -0
  47. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v2/convert_dataset_v1_to_v2.py +0 -0
  48. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v21/_remove_language_instruction.py +0 -0
  49. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v21/batch_convert_dataset_v20_to_v21.py +0 -0
  50. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v21/convert_dataset_v20_to_v21.py +0 -0
  51. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/v21/convert_stats.py +0 -0
  52. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/datasets/video_utils.py +0 -0
  53. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/envs/__init__.py +0 -0
  54. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/envs/configs.py +0 -0
  55. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/envs/factory.py +0 -0
  56. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/envs/libero.py +0 -0
  57. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/envs/utils.py +0 -0
  58. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/optim/__init__.py +0 -0
  59. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/optim/factory.py +0 -0
  60. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/optim/optimizers.py +0 -0
  61. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/optim/schedulers.py +0 -0
  62. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/planner/__init__.py +0 -0
  63. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/planner/high_level_planner.py +0 -0
  64. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/planner/utils/memory.py +0 -0
  65. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/planner/utils/utils.py +0 -0
  66. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/__init__.py +0 -0
  67. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/factory.py +0 -0
  68. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/normalize.py +0 -0
  69. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi0/__init__.py +0 -0
  70. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi0/configuration_pi0.py +0 -0
  71. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi0/modeling_pi0.py +0 -0
  72. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi0/paligemma_with_expert.py +0 -0
  73. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi05/__init__.py +0 -0
  74. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi05/configuration_pi05.py +0 -0
  75. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi05/modeling_pi05.py +0 -0
  76. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pi05/paligemma_with_expert.py +0 -0
  77. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/pretrained.py +0 -0
  78. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/utils.py +0 -0
  79. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/value/__init__.py +0 -0
  80. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/value/configuration_value.py +0 -0
  81. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/value/modeling_value.py +0 -0
  82. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/value/reward.py +0 -0
  83. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/policies/value/siglip_gemma.py +0 -0
  84. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/actions_mse_loss.py +0 -0
  85. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/bin_to_safetensors.py +0 -0
  86. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/compute_max_token_length.py +0 -0
  87. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/display_sys_info.py +0 -0
  88. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/download_libero_benchmarks.py +0 -0
  89. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/eval.py +0 -0
  90. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/export_to_onnx.py +0 -0
  91. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/fake_tensor_training.py +0 -0
  92. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/get_advantage_and_percentiles.py +0 -0
  93. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/high_level_planner_inference.py +0 -0
  94. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/inference.py +0 -0
  95. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/libero_simulation_parallel.py +0 -0
  96. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/libero_simulation_sequential.py +0 -0
  97. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/nav_high_level_planner_inference.py +0 -0
  98. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/visualize_dataset.py +0 -0
  99. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/visualize_dataset_html.py +0 -0
  100. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/scripts/zero_to_fp32.py +0 -0
  101. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/__init__.py +0 -0
  102. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/accelerate_utils.py +0 -0
  103. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/benchmark.py +0 -0
  104. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/fake_tensor.py +0 -0
  105. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/hub.py +0 -0
  106. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/import_utils.py +0 -0
  107. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/io_utils.py +0 -0
  108. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/libero.py +0 -0
  109. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/libero_dataset_recorder.py +0 -0
  110. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/logging_utils.py +0 -0
  111. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/monkey_patch.py +0 -0
  112. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/random_utils.py +0 -0
  113. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/train_utils.py +0 -0
  114. {opentau-0.1.0 → opentau-0.1.1}/src/opentau/utils/utils.py +0 -0
  115. {opentau-0.1.0 → opentau-0.1.1}/src/opentau.egg-info/dependency_links.txt +0 -0
  116. {opentau-0.1.0 → opentau-0.1.1}/src/opentau.egg-info/top_level.txt +0 -0
  117. {opentau-0.1.0 → opentau-0.1.1}/tests/test_available.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: opentau
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: OpenTau: Tensor's VLA Training Infrastructure for Real-World Robotics in Pytorch
5
5
  Author-email: Shuheng Liu <wish1104@icloud.com>, William Yue <williamyue37@gmail.com>, Akshay Shah <akshayhitendrashah@gmail.com>, Xingrui Gu <xingrui_gu@berkeley.edu>
6
6
  License: Apache-2.0
@@ -94,6 +94,9 @@ Requires-Dist: numpy<2; extra == "libero"
94
94
  Requires-Dist: gym<0.27,>=0.25; extra == "libero"
95
95
  Requires-Dist: pyopengl-accelerate==3.1.7; sys_platform == "linux" and extra == "libero"
96
96
  Requires-Dist: gymnasium[other]>=0.29; extra == "libero"
97
+ Requires-Dist: mujoco>=3.1.6; sys_platform == "linux" and extra == "libero"
98
+ Requires-Dist: pyopengl==3.1.7; sys_platform == "linux" and extra == "libero"
99
+ Requires-Dist: numpy==1.26.4; sys_platform == "linux" and extra == "libero"
97
100
  Dynamic: license-file
98
101
 
99
102
  <p align="center">
@@ -134,10 +137,10 @@ OpenTau ($\tau$) is a tool developed by *[Tensor][1]* to bridge this gap, and we
134
137
  ## Quick Start
135
138
  If you are familiar with LeRobot, getting started with OpenTau is very easy.
136
139
  Because OpenTau is a fork of the popular LeRobot repository, any LeRobot-compliant policy and dataset can be used directly with OpenTau.
137
- Check out our documentation to get started quickly.
138
- We provide a quick start guide to help you get started with OpenTau.
140
+ Check out our [documentation](https://opentau.readthedocs.io/) to get started quickly.
141
+ We provide a [quick start guide](https://opentau.readthedocs.io/en/latest/getting_started.html) to help you get started with OpenTau.
139
142
 
140
- For using local notebooks to train and evaluate models, find the notebooks at `notebooks/pi05_training.ipynb` and `notebooks/pi05_evaluation_only.ipynb`.
143
+ For using local notebooks to train and evaluate models, find the notebooks at [notebooks/pi05_training.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_training.ipynb) and [notebooks/pi05_evaluation_only.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_evaluation_only.ipynb).
141
144
 
142
145
  For using the Google Colab notebooks to train and evaluate models, find the colab notebooks here: [pi05_training](https://colab.research.google.com/drive/1DeU0lNnEzs1KHo0Nkgh4YKBr-xu9moBM?usp=sharing) and [pi05_evaluation_only](https://colab.research.google.com/drive/1U_AyuH9WYMT4anEWvsOtIT7g01jA0WGm?usp=sharing) respectively.
143
146
 
@@ -36,10 +36,10 @@ OpenTau ($\tau$) is a tool developed by *[Tensor][1]* to bridge this gap, and we
36
36
  ## Quick Start
37
37
  If you are familiar with LeRobot, getting started with OpenTau is very easy.
38
38
  Because OpenTau is a fork of the popular LeRobot repository, any LeRobot-compliant policy and dataset can be used directly with OpenTau.
39
- Check out our documentation to get started quickly.
40
- We provide a quick start guide to help you get started with OpenTau.
39
+ Check out our [documentation](https://opentau.readthedocs.io/) to get started quickly.
40
+ We provide a [quick start guide](https://opentau.readthedocs.io/en/latest/getting_started.html) to help you get started with OpenTau.
41
41
 
42
- For using local notebooks to train and evaluate models, find the notebooks at `notebooks/pi05_training.ipynb` and `notebooks/pi05_evaluation_only.ipynb`.
42
+ For using local notebooks to train and evaluate models, find the notebooks at [notebooks/pi05_training.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_training.ipynb) and [notebooks/pi05_evaluation_only.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_evaluation_only.ipynb).
43
43
 
44
44
  For using the Google Colab notebooks to train and evaluate models, find the colab notebooks here: [pi05_training](https://colab.research.google.com/drive/1DeU0lNnEzs1KHo0Nkgh4YKBr-xu9moBM?usp=sharing) and [pi05_evaluation_only](https://colab.research.google.com/drive/1U_AyuH9WYMT4anEWvsOtIT7g01jA0WGm?usp=sharing) respectively.
45
45
 
@@ -20,7 +20,7 @@ huggingface = "https://huggingface.co/TensorAuto"
20
20
 
21
21
  [project]
22
22
  name = "opentau"
23
- version = "0.1.0"
23
+ version = "0.1.1"
24
24
  description = "OpenTau: Tensor's VLA Training Infrastructure for Real-World Robotics in Pytorch"
25
25
  authors = [
26
26
  { name = "Shuheng Liu", email = "wish1104@icloud.com" },
@@ -89,7 +89,9 @@ dependencies = [
89
89
  ]
90
90
 
91
91
  [project.scripts]
92
- opentau-train = "opentau.scripts.launch_train:main"
92
+ opentau-train = "opentau.scripts.launch:train"
93
+ opentau-eval = "opentau.scripts.launch:eval"
94
+ opentau-export = "opentau.scripts.launch:export"
93
95
 
94
96
  [project.optional-dependencies]
95
97
  dev = ["pre-commit>=3.7.0",
@@ -122,6 +124,9 @@ libero = [
122
124
  "gym>=0.25,<0.27",
123
125
  "pyopengl-accelerate==3.1.7 ; sys_platform == 'linux'",
124
126
  "gymnasium[other]>=0.29",
127
+ "mujoco>=3.1.6 ; sys_platform == 'linux'",
128
+ "pyopengl==3.1.7 ; sys_platform == 'linux'",
129
+ "numpy==1.26.4 ; sys_platform == 'linux'",
125
130
  ]
126
131
 
127
132
  [tool.uv.sources]
@@ -56,6 +56,7 @@ When implementing a new policy class (e.g., `DiffusionPolicy`), follow these ste
56
56
  import itertools
57
57
 
58
58
  from opentau.__version__ import __version__ # noqa: F401
59
+ from opentau.utils import transformers_patch # noqa: F401
59
60
 
60
61
  # TODO(rcadene): Improve policies and envs. As of now, an item in `available_policies`
61
62
  # refers to a yaml file AND a modeling name. Same for `available_envs` which refers to
@@ -0,0 +1,79 @@
1
+ # Copyright 2026 Tensor Auto Inc. All rights reserved.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ import argparse
16
+ import subprocess
17
+ import sys
18
+ from pathlib import Path
19
+ from types import ModuleType
20
+
21
+ import opentau.scripts.eval as eval_script
22
+ import opentau.scripts.export_to_onnx as export_script
23
+ import opentau.scripts.train as train_script
24
+
25
+
26
+ def launch(script_module: ModuleType, description: str, use_accelerate: bool = True):
27
+ """Generic launcher for OpenTau scripts using Accelerate or Python."""
28
+ parser = argparse.ArgumentParser(
29
+ description=description,
30
+ usage=f"{Path(sys.argv[0]).name} {'[--accelerate-config CONFIG] ' if use_accelerate else ''}[ARGS]",
31
+ )
32
+ if use_accelerate:
33
+ parser.add_argument(
34
+ "--accelerate-config", type=str, help="Path to accelerate config file (yaml)", default=None
35
+ )
36
+
37
+ # We use parse_known_args so that all other arguments are collected
38
+ # These will be passed to the target script
39
+ args, unknown_args = parser.parse_known_args()
40
+
41
+ # Base command
42
+ if use_accelerate:
43
+ cmd = ["accelerate", "launch"]
44
+ # Add accelerate config if provided
45
+ if args.accelerate_config:
46
+ cmd.extend(["--config_file", args.accelerate_config])
47
+ else:
48
+ cmd = [sys.executable]
49
+
50
+ # Add the path to the target script
51
+ # We resolve the path to ensure it's absolute
52
+ script_path = Path(script_module.__file__).resolve()
53
+ cmd.append(str(script_path))
54
+
55
+ # Add all other arguments (passed to the target script)
56
+ cmd.extend(unknown_args)
57
+
58
+ # Print the command for transparency
59
+ print(f"Executing: {' '.join(cmd)}")
60
+
61
+ # Replace the current process with the accelerate launch command
62
+ try:
63
+ subprocess.run(cmd, check=True)
64
+ except subprocess.CalledProcessError as e:
65
+ sys.exit(e.returncode)
66
+ except KeyboardInterrupt:
67
+ sys.exit(130)
68
+
69
+
70
+ def train():
71
+ launch(train_script, "Launch OpenTau training with Accelerate")
72
+
73
+
74
+ def eval():
75
+ launch(eval_script, "Launch OpenTau evaluation with Accelerate")
76
+
77
+
78
+ def export():
79
+ launch(export_script, "Launch OpenTau ONNX export", use_accelerate=False)
@@ -73,16 +73,16 @@ def update_policy(
73
73
  train_config.loss_weighting["MSE"] * losses["MSE"] + train_config.loss_weighting["CE"] * losses["CE"]
74
74
  )
75
75
 
76
- # accelerator.backward(loss)
77
- # accelerator.unscale_gradients(optimizer=optimizer)
76
+ accelerator.backward(loss)
77
+ accelerator.unscale_gradients(optimizer=optimizer)
78
78
 
79
- # if accelerator.sync_gradients:
80
- # grad_norm = accelerator.clip_grad_norm_(policy.parameters(), grad_clip_norm)
81
- # if accelerator.is_main_process:
82
- # train_metrics.grad_norm = grad_norm
79
+ if accelerator.sync_gradients:
80
+ grad_norm = accelerator.clip_grad_norm_(policy.parameters(), grad_clip_norm)
81
+ if accelerator.is_main_process:
82
+ train_metrics.grad_norm = grad_norm
83
83
 
84
- # optimizer.step()
85
- # optimizer.zero_grad()
84
+ optimizer.step()
85
+ optimizer.zero_grad()
86
86
 
87
87
  # Step through pytorch scheduler at every batch instead of epoch
88
88
  if lr_scheduler is not None:
@@ -0,0 +1,48 @@
1
+ # Copyright 2026 Tensor Auto Inc. All rights reserved.
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ """Module for patching transformers metadata lookup.
16
+
17
+ This module monkey patches `importlib.metadata.distribution` to redirect
18
+ 'transformers' lookups to 'opentau-transformers'. This ensures that the custom
19
+ transformers fork is correctly recognized by libraries checking for transformers
20
+ installation.
21
+ """
22
+
23
+ import importlib.metadata
24
+
25
+ # Keep a reference to the original distribution function
26
+ _orig_distribution = importlib.metadata.distribution
27
+
28
+
29
+ def distribution(distribution_name):
30
+ """Monkey patch to redirect 'transformers' metadata lookups to 'opentau-transformers'.
31
+
32
+ This function intercepts calls to `importlib.metadata.distribution`. If the
33
+ requested distribution is "transformers", it redirects the lookup to
34
+ "opentau-transformers". Otherwise, it delegates to the original implementation.
35
+
36
+ Args:
37
+ distribution_name: The name of the distribution to retrieve metadata for.
38
+
39
+ Returns:
40
+ The distribution metadata object.
41
+ """
42
+ if distribution_name == "transformers":
43
+ distribution_name = "opentau-transformers"
44
+ return _orig_distribution(distribution_name)
45
+
46
+
47
+ # Apply the patch
48
+ importlib.metadata.distribution = distribution
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: opentau
3
- Version: 0.1.0
3
+ Version: 0.1.1
4
4
  Summary: OpenTau: Tensor's VLA Training Infrastructure for Real-World Robotics in Pytorch
5
5
  Author-email: Shuheng Liu <wish1104@icloud.com>, William Yue <williamyue37@gmail.com>, Akshay Shah <akshayhitendrashah@gmail.com>, Xingrui Gu <xingrui_gu@berkeley.edu>
6
6
  License: Apache-2.0
@@ -94,6 +94,9 @@ Requires-Dist: numpy<2; extra == "libero"
94
94
  Requires-Dist: gym<0.27,>=0.25; extra == "libero"
95
95
  Requires-Dist: pyopengl-accelerate==3.1.7; sys_platform == "linux" and extra == "libero"
96
96
  Requires-Dist: gymnasium[other]>=0.29; extra == "libero"
97
+ Requires-Dist: mujoco>=3.1.6; sys_platform == "linux" and extra == "libero"
98
+ Requires-Dist: pyopengl==3.1.7; sys_platform == "linux" and extra == "libero"
99
+ Requires-Dist: numpy==1.26.4; sys_platform == "linux" and extra == "libero"
97
100
  Dynamic: license-file
98
101
 
99
102
  <p align="center">
@@ -134,10 +137,10 @@ OpenTau ($\tau$) is a tool developed by *[Tensor][1]* to bridge this gap, and we
134
137
  ## Quick Start
135
138
  If you are familiar with LeRobot, getting started with OpenTau is very easy.
136
139
  Because OpenTau is a fork of the popular LeRobot repository, any LeRobot-compliant policy and dataset can be used directly with OpenTau.
137
- Check out our documentation to get started quickly.
138
- We provide a quick start guide to help you get started with OpenTau.
140
+ Check out our [documentation](https://opentau.readthedocs.io/) to get started quickly.
141
+ We provide a [quick start guide](https://opentau.readthedocs.io/en/latest/getting_started.html) to help you get started with OpenTau.
139
142
 
140
- For using local notebooks to train and evaluate models, find the notebooks at `notebooks/pi05_training.ipynb` and `notebooks/pi05_evaluation_only.ipynb`.
143
+ For using local notebooks to train and evaluate models, find the notebooks at [notebooks/pi05_training.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_training.ipynb) and [notebooks/pi05_evaluation_only.ipynb](https://github.com/TensorAuto/OpenTau/blob/main/notebooks/pi05_evaluation_only.ipynb).
141
144
 
142
145
  For using the Google Colab notebooks to train and evaluate models, find the colab notebooks here: [pi05_training](https://colab.research.google.com/drive/1DeU0lNnEzs1KHo0Nkgh4YKBr-xu9moBM?usp=sharing) and [pi05_evaluation_only](https://colab.research.google.com/drive/1U_AyuH9WYMT4anEWvsOtIT7g01jA0WGm?usp=sharing) respectively.
143
146
 
@@ -87,7 +87,7 @@ src/opentau/scripts/fake_tensor_training.py
87
87
  src/opentau/scripts/get_advantage_and_percentiles.py
88
88
  src/opentau/scripts/high_level_planner_inference.py
89
89
  src/opentau/scripts/inference.py
90
- src/opentau/scripts/launch_train.py
90
+ src/opentau/scripts/launch.py
91
91
  src/opentau/scripts/libero_simulation_parallel.py
92
92
  src/opentau/scripts/libero_simulation_sequential.py
93
93
  src/opentau/scripts/nav_high_level_planner_inference.py
@@ -108,5 +108,6 @@ src/opentau/utils/logging_utils.py
108
108
  src/opentau/utils/monkey_patch.py
109
109
  src/opentau/utils/random_utils.py
110
110
  src/opentau/utils/train_utils.py
111
+ src/opentau/utils/transformers_patch.py
111
112
  src/opentau/utils/utils.py
112
113
  tests/test_available.py
@@ -0,0 +1,4 @@
1
+ [console_scripts]
2
+ opentau-eval = opentau.scripts.launch:eval
3
+ opentau-export = opentau.scripts.launch:export
4
+ opentau-train = opentau.scripts.launch:train
@@ -82,6 +82,9 @@ gymnasium[other]>=0.29
82
82
 
83
83
  [libero:sys_platform == "linux"]
84
84
  pyopengl-accelerate==3.1.7
85
+ mujoco>=3.1.6
86
+ pyopengl==3.1.7
87
+ numpy==1.26.4
85
88
 
86
89
  [openai]
87
90
  openai>=1.0.0
@@ -1,63 +0,0 @@
1
- # Copyright 2026 Tensor Auto Inc. All rights reserved.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
- import argparse
16
- import subprocess
17
- import sys
18
- from pathlib import Path
19
-
20
- import opentau.scripts.train as train_script
21
-
22
-
23
- def main():
24
- parser = argparse.ArgumentParser(
25
- description="Launch OpenTau training with Accelerate",
26
- usage="opentau-train [--accelerate-config CONFIG] [TRAINING_ARGS]",
27
- )
28
- parser.add_argument(
29
- "--accelerate-config", type=str, help="Path to accelerate config file (yaml)", default=None
30
- )
31
- # We use parse_known_args so that all other arguments are collected
32
- # These will be passed to the training script
33
- args, unknown_args = parser.parse_known_args()
34
-
35
- # Base command
36
- cmd = ["accelerate", "launch"]
37
-
38
- # Add accelerate config if provided
39
- if args.accelerate_config:
40
- cmd.extend(["--config_file", args.accelerate_config])
41
-
42
- # Add the path to the training script
43
- # We resolve the path to ensure it's absolute
44
- train_script_path = Path(train_script.__file__).resolve()
45
- cmd.append(str(train_script_path))
46
-
47
- # Add all other arguments (passed to the training script)
48
- cmd.extend(unknown_args)
49
-
50
- # Print the command for transparency
51
- print(f"Executing: {' '.join(cmd)}")
52
-
53
- # Replace the current process with the accelerate launch command
54
- try:
55
- subprocess.run(cmd, check=True)
56
- except subprocess.CalledProcessError as e:
57
- sys.exit(e.returncode)
58
- except KeyboardInterrupt:
59
- sys.exit(130)
60
-
61
-
62
- if __name__ == "__main__":
63
- main()
@@ -1,2 +0,0 @@
1
- [console_scripts]
2
- opentau-train = opentau.scripts.launch_train:main
File without changes
File without changes
File without changes