Tags: dora-rs/DoRobot
Tags
V34: Add episode display, P key reset flow, and increase queue to 50 - Add episode_index display in camera status bar with key hints - Add 'p' key handling for reset/proceed flow between episodes - Increase async_save_queue_size from 10 to 50 for larger collections - Update run_so101.sh to enable cloud_offload and NPU by default
v0.2.29: Cloud offload mode - skip video encoding on edge devices - Add skip_encoding parameter to save_episode() for cloud offload mode - Skip video encoding when skip_encoding=True, keep raw PNG images - Add cloud offload documentation in docs/offload_cloud.md - Add train.py training script 🤖 Generated with [Claude Code](https://claude.com/claude-code)
V27: NPU encoder with semaphore, retry, and CPU fallback Implements hybrid encoding strategy for Ascend NPU: 1. Semaphore (prevents channel exhaustion): - Limits concurrent NPU encoding to 2 channels (configurable) - Prevents "Failed to create venc channel" errors - Use set_npu_encoder_channels(n) to adjust for your hardware 2. Retry with exponential backoff (maximizes NPU usage): - If NPU channel busy, wait and retry (1s, 1.5s, 2.25s...) - Default timeout: 30 seconds - NPU is ~10-50x faster than CPU, so waiting is worth it 3. CPU fallback (last resort): - Only after retry timeout expires - Uses libx264 with preset=ultrafast - Shows progress during encoding New parameters: - npu_retry_timeout: Max wait time for NPU (default: 30s) - npu_retry_interval: Initial retry interval (default: 1s) - npu_retry_max_interval: Max retry interval (default: 5s) Typical flow for 10 episodes (20 videos): - Videos 1-2: NPU encodes immediately (2 channels) - Videos 3-20: Wait for semaphore, then NPU encode - Total time: ~30-60 seconds (vs 5-10 min with CPU fallback) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
V26: Improve libx264 CPU fallback encoding with progress and speed Changes: - Add -preset ultrafast for fast CPU encoding (was missing) - Add -g (keyframe interval) default to fps*2 (every 2 seconds) - Add -crf 23 default for good quality/size balance - Show ffmpeg progress output during fallback encoding - Log frame count and ffmpeg command for visibility - Remove g=1 default which made every frame a keyframe (slow) Fallback now shows: [VideoEncoder] NPU encoder failed, falling back to libx264 (CPU)... [VideoEncoder] Encoding 300 frames with libx264 (preset=ultrafast)... [VideoEncoder] Running: ffmpeg -f image2 -r 30 ... frame= 100 fps=45 ... (ffmpeg progress) 🤖 Generated with [Claude Code](https://claude.com/claude-code)
V25: Fix USB port and ZeroMQ socket resource leaks Problem: Video port numbers increment after each data collection session (e.g., /dev/video0 -> /dev/video2), indicating USB camera ports not released. Root cause: 1. ZeroMQ sockets created at module import, never closed 2. No signal handlers for Ctrl+C cleanup 3. disconnect() did not release ZMQ context/sockets Solution: 1. Lazy ZeroMQ initialization in manipulator.py 2. Signal handlers in main.py for graceful shutdown 3. Improved disconnect with socket cleanup Generated with Claude Code Co-Authored-By: Claude <[email protected]>
V24: Add NPU video encoder fallback to libx264 Problem: When encoding 10+ episodes on Ascend NPU, video encoding fails with "Failed to create venc channel" due to hardware channel exhaustion. Solution: Automatically fallback to libx264 software encoder when NPU fails: - Detect NPU channel exhaustion errors in ffmpeg stderr - Retry with libx264 when h264_ascend fails - Log warning about fallback for debugging Changes: - Refactored encode_video_frames() with _build_ffmpeg_cmd() helper - Added try/except with automatic encoder fallback - Capture ffmpeg stderr for better error diagnostics - Updated RELEASE.md with V24 documentation 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
PreviousNext