2025-03-05 17:56:51 +01:00
# Copyright 2024 The HuggingFace Inc. team. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
2025-02-16 14:28:03 +01:00
[ project . urls ]
homepage = "https://github.com/huggingface/lerobot"
issues = "https://github.com/huggingface/lerobot/issues"
discord = "https://discord.gg/s3KuuzsPFb"
[ project ]
2024-02-28 19:11:29 +01:00
name = "lerobot"
version = "0.1.0"
2024-04-16 12:09:56 +02:00
description = "🤗 LeRobot: State-of-the-art Machine Learning for Real-World Robotics in Pytorch"
2024-02-28 19:11:29 +01:00
authors = [
2025-03-05 17:56:51 +01:00
{ name = "Rémi Cadène" , email = "re.cadene@gmail.com" } ,
{ name = "Simon Alibert" , email = "alibert.sim@gmail.com" } ,
{ name = "Alexander Soare" , email = "alexander.soare159@gmail.com" } ,
{ name = "Quentin Gallouédec" , email = "quentin.gallouedec@ec-lyon.fr" } ,
{ name = "Adil Zouitine" , email = "adilzouitinegm@gmail.com" } ,
{ name = "Thomas Wolf" , email = "thomaswolfcontact@gmail.com" } ,
{ name = "Steven Palma" , email = "imstevenpmwork@ieee.org" } ,
2024-02-28 19:11:29 +01:00
]
readme = "README.md"
2025-03-05 17:56:51 +01:00
license = { text = "Apache-2.0" }
2025-02-16 14:28:03 +01:00
requires-python = ">=3.10"
keywords = [ "robotics" , "deep learning" , "pytorch" ]
2025-03-05 17:56:51 +01:00
classifiers = [
2024-02-28 19:11:29 +01:00
"Development Status :: 3 - Alpha" ,
"Intended Audience :: Developers" ,
2024-04-16 12:09:56 +02:00
"Intended Audience :: Education" ,
"Intended Audience :: Science/Research" ,
2024-02-28 19:11:29 +01:00
"Topic :: Software Development :: Build Tools" ,
2024-04-16 12:09:56 +02:00
"Topic :: Scientific/Engineering :: Artificial Intelligence" ,
"License :: OSI Approved :: Apache Software License" ,
2024-03-05 16:03:03 +01:00
"Programming Language :: Python :: 3.10" ,
2024-02-28 19:11:29 +01:00
]
2025-02-16 14:28:03 +01:00
dependencies = [
"cmake>=3.29.0.1" ,
"datasets>=2.19.0" ,
"deepdiff>=7.0.1" ,
"diffusers>=0.27.2" ,
2025-04-24 09:42:03 +02:00
"draccus==0.10.0" ,
2025-02-16 14:28:03 +01:00
"einops>=0.8.0" ,
"flask>=3.0.3" ,
"gdown>=5.1.0" ,
2025-06-05 17:48:43 +02:00
"gymnasium==0.29.1" , # TODO(rcadene, aliberts): Make gym 1.0.0 work
2025-02-16 14:28:03 +01:00
"h5py>=3.10.0" ,
"huggingface-hub[hf-transfer,cli]>=0.27.1 ; python_version < '4.0'" ,
"imageio[ffmpeg]>=2.34.0" ,
"jsonlines>=4.0.0" ,
"numba>=0.59.0" ,
"omegaconf>=2.3.0" ,
2025-04-09 17:33:01 +02:00
"opencv-python-headless>=4.9.0" ,
2025-02-25 15:27:29 +01:00
"packaging>=24.2" ,
2025-04-29 17:39:35 +02:00
"av>=14.2.0" ,
2025-06-02 13:18:02 +02:00
"pymunk>=6.6.0,<7.0.0" ,
2025-02-25 09:06:50 +01:00
"pynput>=1.7.7" ,
2025-06-06 14:38:33 +02:00
"pyserial>=3.5" ,
2025-02-25 09:06:50 +01:00
"pyzmq>=26.2.1" ,
2025-02-16 14:28:03 +01:00
"rerun-sdk>=0.21.0" ,
"termcolor>=2.4.0" ,
2025-05-28 16:54:20 +02:00
"torch>=2.2.1" ,
"torchcodec>=0.2.1; sys_platform != 'win32' and (sys_platform != 'linux' or (platform_machine != 'aarch64' and platform_machine != 'arm64' and platform_machine != 'armv7l')) and (sys_platform != 'darwin' or platform_machine != 'x86_64')" ,
2025-02-16 14:28:03 +01:00
"torchvision>=0.21.0" ,
"wandb>=0.16.3" ,
2025-02-25 09:06:50 +01:00
"zarr>=2.17.0" ,
2025-02-16 14:28:03 +01:00
]
2024-04-23 14:13:25 +02:00
2025-02-16 14:28:03 +01:00
[ project . optional-dependencies ]
aloha = [ "gym-aloha>=0.1.1 ; python_version < '4.0'" ]
2025-05-02 12:47:23 +02:00
docs = [ "hf-doc-builder @ git+https://github.com/huggingface/doc-builder.git@main" , "watchdog >= 6.0.0" ]
2025-07-09 16:22:40 +02:00
dev = [ "pre-commit>=3.7.0" , "debugpy>=1.8.1" , "grpcio-tools==1.71.0" ]
2025-03-05 17:56:51 +01:00
dora = [
"gym-dora @ git+https://github.com/dora-rs/dora-lerobot.git#subdirectory=gym_dora ; python_version < '4.0'" ,
]
2025-06-05 17:48:43 +02:00
dynamixel = [ "dynamixel-sdk>=3.7.31" ]
feetech = [ "feetech-servo-sdk>=1.0.0" ]
2025-06-13 17:07:11 +02:00
gamepad = [ "pygame>=2.5.1" , "hidapi>=0.14.0" ]
Add Hope Jr (#935)
* Fix imports
* Add feetech write tests
* Nit
* Add autoclosing fixture
* Assert ping stub called
* Add CalibrationMode
* Add Motor in dxl robots
* Simplify split_int_bytes
* Rename read/write -> sync_read/write, refactor, add write
* Rename tests
* Refactor dxl tests by functionality
* Add dxl write test
* Refactor _is_comm_success
* Refactor feetech tests by functionality
* Add feetech write test
* Simplify _is_comm_success & _is_error
* Move mock_serial patch to dedicated file
* Remove test skips & fix docstrings
* Nit
* Add dxl operating modes
* Add is_connected in robots and teleops
* Update Koch
* Add feetech operating modes
* Caps dxl OperatingMode
* Update ensure_safe_goal_position
* Update so100
* Privatize methods & renames
* Fix dict
* Add _configure_motors & move ping methods
* Return models (str) with pings
* Implement feetech broadcast ping
* Add raw_values option
* Rename idx -> id_
* Improve errors
* Fix feetech ping tests
* Ensure motors exist at connection time
* Update tests
* Add test_motors_bus
* Move DriveMode & TorqueMode
* Update Koch imports
* Update so100 imports
* Fix visualize_motors_bus
* Fix imports
* Add calibration
* Rename idx -> id_
* Rename idx -> id_
* (WIP) _async_read
* Add new calibration method for robot refactor (#896)
Co-authored-by: Simon Alibert <simon.alibert@huggingface.co>
* Remove deprecated scripts
* Rename CalibrationMode -> MotorNormMode
* Fix calibration functions
* Remove todo
* Add scan_port utility
* Add calibration utilities
* Move encoding functions to encoding_utils
* Add test_encoding_utils
* Rename test
* Add more calibration utilities
* Format baudrate tables
* Implement SO-100 leader calibration
* Implement SO-100 follower calibration
* Implement Koch calibration
* Add test_scan_port (TODO)
* Fix calibration
* Hack feetech firmware bug
* Update tests
* Update Koch & SO-100
* Improve format
* Rename SO-100 classes
* Rename Koch classes
* Add calibration tests
* Remove old calibration tests
* Revert feetech hack and monkeypatch instead
* Simplify motors mocks
* Add is_calibrated test
* Update viperx & widowx
* Rename viperx & widowx
* Remove old calibration
* feat(teleop): thread-safe keyboard teleop implementation (#869)
Co-authored-by: Simon Alibert <75076266+aliberts@users.noreply.github.com>
* Add support for feetech scs series + various fixes
* Update dynamixel with motors bus & tables changes
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* (WIP) Add Hope Jr
* Rename arm -> hand
* (WIP) Add homonculus arm & glove
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Add Feetech protocol version
* Implement read
* Use constants from sdks
* (nit) move write
* Fix broadcast ping type hint
* Add protocol 1 broadcast ping
* Refactor & add _serialize_data
* Add feetech sm8512bl
* Make feetech broadcast ping faster in protocol 1
* Cleanup
* Add support for feetech protocol 1 to _split_into_byte_chunks
* Fix unormalize
* Remove test_motors_bus fixtures
* Add more segmented tests (base motor bus & feetech), add feetech protocol 1 support
* Add more segmented tests (dynamixel)
* Refactor tests
* Add handshake, fix feetech _read_firmware_version
* Fix tests
* Motors config & disconnect fixes
* Add torque_disabled context
* Update branch & fix pre-commit errors
* Fix hand & glove readings
* Update feetech tables
* Move read/write_calibration implementations
* Add setup_motor
* Fix calibration msg display
* Fix setup_motor & add it to robots
* Fix _find_single_motor
* Remove deprecated configure_motor
* Remove deprecated dynamixel_calibration
* Remove names
* Remove deprecated import
* refactor/lekiwi robot (#863)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Simon Alibert <simon.alibert@huggingface.co>
Co-authored-by: Simon Alibert <75076266+aliberts@users.noreply.github.com>
* fix(teleoperators): use property is_connected (#1075)
* Remove deprecated manipulator
* Update robot features & naming
* Update teleop features & naming
* Add make_teleoperator_from_config
* Rename find_port
* Fix config parsing
* Remove app script
* Add setup_motors
* Add teleoperate
* Add record
* Add replay
* Fix test_datasets
* Add mock robot & teleop
* Add new test_control_robot
* Add test_record_and_resume
* Remove deprecated scripts & tests
* Add calibrate
* Add docstrings
* Fix tests (no-extras install)
* Add SO101
* Remove pynput from optional deps
* Rename example 7
* Remove unecessary id
* Add MotorsBus docstrings
* Rename arm -> bus
* Remove Moss arm
* Fix setup_motors & calibrate configs
* Fix test_calibrate
* Add copyrights
* Update hand & arm
* Update homonculus hand & arm
* Fix dxl _find_single_motor
* Update glove
* Add setup_motors for lekiwi
* Fix glove calibration
* Complete docstring
* Add check for same min and max during calibration
* Move MockMotorsBus
* Add so100_follower tests
* (WIP) add calibration gui
* Fix test
* Add setup_motors
* Update calibration gui
* Remove old .cache folder
* Replace deprecated abc.abstractproperty
* Fix feetech protocol 1 configure
* Cleanup gui & add copyrights
* Anatomically precise joint names
* (WIP) Add glove to hand joints translation
* Move make_robot_config
* Add drive_mode & norm_mode in glove calibration
* Fix joints translation
* Fix normalization drive_mode
* nit
* Fix glove to hand conversion
* Adapt feetech calibration
* Remove pygame prompt
* Implement arm calibration (hacks)
* Better MotorsBus error messages
* Update feetech read_calibration
* Fix feetech test_is_calibrated
* Cleanup glove
* (WIP) Update arm
* Add changes from #1117
* refactor(cameras): cameras implementations + tests improvements (#1108)
Co-authored-by: Simon Alibert <simon.alibert@huggingface.co>
Co-authored-by: Simon Alibert <75076266+aliberts@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Fix arm joints order
* Add timeout/event logic
* Fix arm & glove
* Fix predict_action from record
* fix(cameras): update docstring + handle sn when starts with 0 + update timeouts to more reasonable value (#1154)
* fix(scripts): parser instead of draccus in record + add __get_path_fields__() to RecordConfig (#1155)
* Left/Right sides + other fixes
* Arm fixes and add config
* More hacks
* Add control scripts
* Fix merge errors
* push changes to calibration, teleop and docs
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Move readme to docs
* update readme
Signed-off-by: Martino Russi <77496684+nepyope@users.noreply.github.com>
* Add files via upload
Signed-off-by: Martino Russi <77496684+nepyope@users.noreply.github.com>
* Update image sources
* Symlink doc
* Compress image
* Move image
* Update docs link
* fix docs
* simplify teleop scripts
* fix variable names
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Address code review
* add EMA to glove
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* integrate teleoperation for hand
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* update docs
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* import hopejr/homunculus in teleoperate
* update docs for teleoperate, record, replay, train and inference
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* chore(hopejr): address comments
* chore(hopejr): address coments 2
* chore(docs): update teleoperation instructions for the hand/glove
* fix(hopejr): calibration int + update docs
---------
Signed-off-by: Martino Russi <77496684+nepyope@users.noreply.github.com>
Signed-off-by: Simon Alibert <75076266+aliberts@users.noreply.github.com>
Co-authored-by: Pepijn <138571049+pkooij@users.noreply.github.com>
Co-authored-by: Steven Palma <imstevenpmwork@ieee.org>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: nepyope <nopyeps@gmail.com>
Co-authored-by: Martino Russi <77496684+nepyope@users.noreply.github.com>
Co-authored-by: Steven Palma <steven.palma@huggingface.co>
2025-07-08 15:47:11 +02:00
hopejr = [ "feetech-servo-sdk>=1.0.0" , "pygame>=2.5.1" ]
2025-07-02 15:20:04 +02:00
kinematics = [ "placo>=0.9.6" ]
2025-06-05 17:48:43 +02:00
intelrealsense = [
"pyrealsense2>=2.55.1.6486 ; sys_platform != 'darwin'" ,
"pyrealsense2-macosx>=2.54 ; sys_platform == 'darwin'" ,
]
2025-06-15 08:57:08 +02:00
pi0 = [ "transformers>=4.50.3" ]
2025-06-11 16:56:55 +02:00
smolvla = [ "transformers>=4.50.3" , "num2words>=0.5.14" , "accelerate>=1.7.0" , "safetensors>=0.4.3" ]
2025-02-16 14:28:03 +01:00
pusht = [ "gym-pusht>=0.1.5 ; python_version < '4.0'" ]
stretch = [
"hello-robot-stretch-body>=0.7.27 ; python_version < '4.0' and sys_platform == 'linux'" ,
"pyrender @ git+https://github.com/mmatl/pyrender.git ; sys_platform == 'linux'" ,
2025-06-05 17:48:43 +02:00
"pyrealsense2>=2.55.1.6486 ; sys_platform != 'darwin'"
2025-02-16 14:28:03 +01:00
]
2025-06-13 13:15:47 +02:00
test = [ "pytest>=8.1.0" , "pytest-timeout>=2.4.0" , "pytest-cov>=5.0.0" , "pyserial>=3.5" , "mock-serial>=0.0.1 ; sys_platform != 'win32'" ]
2025-07-02 15:20:04 +02:00
hilserl = [ "transformers>=4.50.3" , "gym-hil>=0.1.9" , "protobuf>=5.29.3" , "grpcio==1.71.0" , "placo>=0.9.6" ]
2025-02-16 14:28:03 +01:00
umi = [ "imagecodecs>=2024.1.1" ]
video_benchmark = [ "scikit-image>=0.23.2" , "pandas>=2.2.2" ]
xarm = [ "gym-xarm>=0.1.1 ; python_version < '4.0'" ]
2024-02-28 19:11:29 +01:00
2025-02-16 14:28:03 +01:00
[ tool . poetry ]
requires-poetry = ">=2.1"
2025-07-02 11:40:35 +01:00
packages = [
{ include = "lerobot" , from = "src" }
]
2024-02-28 19:11:29 +01:00
2024-02-29 12:26:35 +01:00
[ tool . ruff ]
line-length = 110
target-version = "py310"
2025-06-13 13:15:47 +02:00
exclude = [ "tests/artifacts/**/*.safetensors" , "*_pb2.py" , "*_pb2_grpc.py" ]
2024-02-29 12:26:35 +01:00
[ tool . ruff . lint ]
select = [ "E4" , "E7" , "E9" , "F" , "I" , "N" , "B" , "C4" , "SIM" ]
2024-03-11 12:10:46 +01:00
2025-06-05 17:48:43 +02:00
[ tool . ruff . lint . per-file-ignores ]
"__init__.py" = [ "F401" , "F403" ]
2025-03-01 19:19:26 +01:00
[ tool . bandit ]
exclude_dirs = [
"tests" ,
"benchmarks" ,
2025-07-01 16:34:46 +02:00
"src/lerobot/datasets/push_dataset_to_hub" ,
"src/lerobot/datasets/v2/convert_dataset_v1_to_v2" ,
"src/lerobot/policies/pi0/conversion_scripts" ,
"src/lerobot/scripts/push_dataset_to_hub.py" ,
2025-03-01 19:19:26 +01:00
]
skips = [ "B101" , "B311" , "B404" , "B603" ]
2024-03-11 12:10:46 +01:00
2025-02-25 23:51:15 +01:00
[ tool . typos ]
default . extend-ignore-re = [
2025-03-05 17:56:51 +01:00
"(?Rm)^.*(#|//)\\s*spellchecker:disable-line$" , # spellchecker:disable-line
"(?s)(#|//)\\s*spellchecker:off.*?\\n\\s*(#|//)\\s*spellchecker:on" , # spellchecker:<on|off>
2025-02-25 23:51:15 +01:00
]
default . extend-ignore-identifiers-re = [
# Add individual words here to ignore them
"2nd" ,
"pn" ,
"ser" ,
"ein" ,
]
2024-03-11 12:10:46 +01:00
[ build-system ]
2024-05-08 19:23:10 +02:00
requires = [ "poetry-core" ]
2024-04-16 12:09:56 +02:00
build-backend = "poetry.core.masonry.api"