From 0c3e24e3d6238c3f289e3968dd21adf585b155f4 Mon Sep 17 00:00:00 2001 From: CarolinePascal Date: Thu, 7 May 2026 11:24:16 +0200 Subject: [PATCH] chore(fromat): formatting code --- src/lerobot/datasets/video_utils.py | 3 ++- tests/datasets/test_video_encoding.py | 8 ++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/lerobot/datasets/video_utils.py b/src/lerobot/datasets/video_utils.py index 33b9ffe00..610609613 100644 --- a/src/lerobot/datasets/video_utils.py +++ b/src/lerobot/datasets/video_utils.py @@ -36,11 +36,12 @@ import torch from datasets.features.features import register_feature from PIL import Image +from lerobot.utils.import_utils import get_safe_default_video_backend + from .pyav_utils import ( check_video_encoder_config_pyav, detect_available_encoders_pyav, ) -from lerobot.utils.import_utils import get_safe_default_video_backend logger = logging.getLogger(__name__) diff --git a/tests/datasets/test_video_encoding.py b/tests/datasets/test_video_encoding.py index 968b3c5a3..7332ab357 100644 --- a/tests/datasets/test_video_encoding.py +++ b/tests/datasets/test_video_encoding.py @@ -478,7 +478,9 @@ class TestConcatenateVideoFiles: def test_two_clips_frame_count(self, tmp_path): """Output frame count equals the sum of the two input frame counts.""" out = tmp_path / "out.mp4" - concatenate_video_files([TEST_ARTIFACTS_DIR / "clip_6frames.mp4", TEST_ARTIFACTS_DIR / "clip_4frames.mp4"], out) + concatenate_video_files( + [TEST_ARTIFACTS_DIR / "clip_6frames.mp4", TEST_ARTIFACTS_DIR / "clip_4frames.mp4"], out + ) with av.open(str(out)) as container: total = sum(1 for _ in container.decode(video=0)) @@ -497,7 +499,9 @@ class TestConcatenateVideoFiles: def test_geometry_preserved(self, tmp_path): """Output resolution, fps, codec and pixel format must match the inputs.""" out = tmp_path / "out.mp4" - concatenate_video_files([TEST_ARTIFACTS_DIR / "clip_4frames.mp4", TEST_ARTIFACTS_DIR / "clip_4frames.mp4"], out) + concatenate_video_files( + [TEST_ARTIFACTS_DIR / "clip_4frames.mp4", TEST_ARTIFACTS_DIR / "clip_4frames.mp4"], out + ) info = get_video_info(out) assert info["video.height"] == 64