본문으로 건너뛰기
Skillpedia
분석 및 스프레드시트12k · #11550

rerun-chunk-processing

하는 일

이 스킬은 원본 파일을 읽는 것부터 최적화된 녹화를 쓰는 것까지, Rerun의 청크 처리 방식을 AI에게 가르칩니다. 로봇이나 센서 데이터를 변환하거나 정리하는 개발자를 위한 스킬입니다.

사용하는 경우

  • ✓MCAP, Parquet 또는 비디오 파일을 Rerun 형식으로 바꾸는 코드를 작성할 때.
  • ✓기존 .rrd 녹화를 전처리하고 싶을 때.
  • ✓오래된 데이터 변환기를 Rerun의 리더 및 렌즈 파이프라인으로 옮기는 경우.

스킬 링크

https://github.com/rerun-io/rerun/blob/main/skills/rerun-chunk-processing/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/rerun-io/rerun/blob/main/skills/rerun-chunk-processing/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 MCAP 파일을 읽고, 렌즈를 적용하고, 최적화된 녹화를 저장하는 Rerun 파이프라인을 작성해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

이 스킬은 리더가 데이터 청크를 만드는 방식, 스트림과 렌즈가 청크를 바꾸는 방식, 그리고 마지막 호출이 파이프라인을 실행하고 결과를 저장하는 방식을 설명합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Rerun chunk processing

The pipeline layer between raw data and an RRD: readers produce Chunks, streams transform them, terminal calls execute. This skill is the generic mechanics only. Decide the data model first (rerun-data-model), then pick the importer skill for each source:

Source Reader Skill
MCAP file (ROS2, protobuf, Foxglove) McapReader(path).stream() rerun-mcap
URDF robot model (+ joint states → FK) UrdfTree.from_file_path(...).stream() rerun-urdf
Parquet table (trajectories, sensor logs) ParquetReader(path).stream() rerun-parquet
mp4 camera video Mp4Reader(path).stream() rerun-mp4
HDF5 file (groups → entities) Hdf5Reader(path).stream() none yet
LeRobot dataset directory built-in importer, then RrdReader rerun-lerobot
Existing RRD RrdReader(path) here, below
Sidecar files (JSON calib, metadata) Chunk.from_columns + from_iter here, below

The API is rerun.chunk; when behavior matters, check the installed surface: python -c "from rerun.chunk import LazyChunkStream; help(LazyChunkStream)".

Decision rule: where does each component come from?

Default: a reader produces the chunks; lenses shape them. Walk this before writing any conversion code — most "build it by hand" instincts are wrong here:

  1. Source a reader supports? Use the reader's .stream(); never hand-parse and re-log. MCAP→McapReader, URDF→UrdfTree, parquet→ParquetReader, mp4→Mp4Reader, HDF5→Hdf5Reader, RRD→RrdReader, LeRobot dir→log_file_from_path.
  2. A decoder already emits the archetype? Foxglove gives Transform3D, Pinhole, VideoStream (real sample bytes) ready-made — pass it through, do not re-derive. Only custom-protobuf topics arrive as <Name>:message and need a lens (see rerun-mcap).
  3. Fix an existing component in place (swapped resolution, recolor, unit convert)? MutateLens, output_mode="forward_unmatched".
  4. Derive a new component/entity (FK→/tf, scalars from a message)? DeriveLens. To scatter one row into N (a joint batch → per-joint /tf), use the two-lens pair: derive the batch with output_mode="forward_all" (keeps the originals, e.g. the joint states), then a second DeriveLens with scatter=True and output_mode="drop_unmatched" (emits only the scattered rows). See the robot_data_preprocessing example.
  5. Genuine sidecar no reader or lens can produce (JSON calibration offsets, hand-measured extrinsics, external metadata)? Chunk.from_columns + from_iter.
  6. Finish with LazyChunkStream.merge(...) → .collect(optimize=OptimizationProfile.OBJECT_STORE) → write_rrd(application_id, recording_id).

Why this order: the pipeline stays lazy, columnar, multithreaded, and OBJECT_STORE-optimizable. A hand-built row loop or an out-of-lens pa.array throws all of that away — that is the path we are deliberately avoiding.

Anti-patterns (use a reader + lens instead)

If you are writing the left, stop and use the right:

  • for-loop building rows/components → a lens with a Selector(...).pipe(...) PyArrow-compute callback.
  • rr.init + rr.log per message for conversion → that is live logging; for ingestion, read with a reader and write_rrd.
  • chunk.to_record_batch() + pc.filter then rebuilding via Chunk.from_columns (row-thinning by hand) → stream.drop(content=...), .split(...), or a MutateLens returning a filtered pa.array.
  • pa.array / pa.RecordBatch / np.frombuffer assembled OUTSIDE a lens → move the transform inside a MutateLens/DeriveLens selector callback.
  • rr.send_columns hand-assembled from a custom parser → use the matching reader; it produces chunks directly.
  • Parsing MCAP/URDF with a non-Rerun library then re-logging → McapReader / UrdfTree.
  • Chunk.from_columns for data a reader already decodes (Pinhole intrinsics, VideoStream, Transform3D from a transforms topic) → keep it in the reader stream; fix with a MutateLens if neede
자주 묻는 질문

청크를 직접 만들어야 하나요?

기존 리더와 렌즈가 있으면 그것을 쓰고, 외부 메타데이터가 있을 때만 청크를 직접 만들라고 이 스킬은 말합니다.

어떤 리더를 언급하나요?

MCAP, URDF, Parquet, mp4 비디오, LeRobot 데이터셋, 그리고 RRD 파일용 리더를 나열합니다.

데이터 모델을 먼저 설계해야 하나요?

네. 이 스킬은 rerun-data-model 스킬을 사용해 데이터 모델을 먼저 정하라고 말합니다.

상세 정보

작성자의 원본 설명

Core mechanics of the Rerun Chunk Processing API (rerun.chunk) — LazyChunkStream pipelines, Chunk, lenses (MutateLens/DeriveLens/Selector), RrdReader, writing optimized RRDs. Read BEFORE writing any ingestion/conversion/preprocessing code (convert an MCAP, build a recording from a dataset, preprocess an .rrd, port an old converter): it mandates reader+lens pipelines and steers away from hand-built chunks — no Chunk.from_columns for data a reader/lens can produce, no per-message rr.log, no manual pa.array assembly. Source-specific knowledge lives in the importer skills (rerun-mcap, rerun-urdf,

repo: rerun-io/rerun

인기도

GitHub 스타
12k
순위
#11550
라이선스
Apache-2.0
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬