Dataset Viewer

The dataset viewer is not available because its heuristics could not detect any supported data files. You can try uploading some data files, or configuring the data files location manually.

Rat Hindlimb Motion Capture Data

Processed motion capture data from rat hindlimb gait analysis experiments.

The installable rat_hindlimb_mocap package owns session naming and dataset measurements. Source recordings are ordinary expanded C3D session directories. The editable prepare_dataset.py notebook makes recording assignments visible. MoveDB owns C3D/ENF conversion, flat trial storage, conversion progress, catalog querying and the optional explorer. OpenSim file conversion and native tools belong to Osimpy; study analysis belongs to rat-vml.

Installation

Use GIT_LFS_SKIP_SMUDGE=1 when cloning to avoid downloading every source recording. Materialize selected session files only when you need them.

The locked environment installs the compatible MoveDB revision pinned in pyproject.toml; no adjacent MoveDB checkout is required:

uv sync --locked
uv sync --locked --extra explorer

Core imports require neither the explorer nor native OpenSim. The explorer extra installs MoveDB's Marimo viewer and Hub downloads; download enables only dataset downloads. Gradio and Pandas are not dependencies of this package.

Dataset Structure

processed/
└── {subject_id}/{session_id}/{trial_name}/
    β”œβ”€β”€ points.parquet                    # Marker positions, residuals and camera masks
    β”œβ”€β”€ forceplates.parquet               # Forces, moments and center of pressure
    β”œβ”€β”€ forceplate_geometry.parquet       # Force plate origins and corners
    β”œβ”€β”€ analogs.parquet                   # Analog channel samples
    β”œβ”€β”€ events.parquet                    # Gait events (foot strike/off)
    β”œβ”€β”€ parameters.json                   # Grouped raw C3D metadata and raw sidecars
    β”œβ”€β”€ conversion.json                   # Source fingerprint, schema and file inventory
    └── history.jsonl                     # Append-only conversion history

MoveDB("processed") reads these flat trial files through its catalog. Each output root supports a single writer: do not overlap conversion/sync commands or query the dataset while writes are running. Conversion stages all trial outputs before replacing files individually, with the conversion manifest last. This does not provide cross-table atomic publication or a crash-safe reader snapshot. Distinct sessions may be converted by workers within one command.

Files

  • points.parquet: Long-format marker positions (marker_name, frame, time, x, y, z), tracking residuals and camera visibility masks.
  • forceplates.parquet: Long-format forces, moments and center of pressure in recorded axes and units. Canonical samples contain no interpreted side column and are never enriched after publication. Rat-vml interprets the raw ENF labels in memory when preparing external loads.
  • forceplate_geometry.parquet: Force plate origins and corners.
  • analogs.parquet: Analog channel samples.
  • events.parquet: Gait events (Left/Right Foot Strike, Foot Off).
  • parameters.json: One JSON object per readable capture, including captures with no parameter groups: {"subject_id": "...", "session_id": "...", "trial_name": "...", "parameters": {...}}. The payload preserves every raw C3D group and entry, including __METADATA__, source type, description and lock metadata. Arrays retain nested-list values plus array_shape and array_dtype; nonfinite numbers are tagged as {"$float": "NaN"}, {"$float": "Infinity"} or {"$float": "-Infinity"}. No physical units are invented from source type metadata. Recognized ENF sidecars are preserved separately in the envelope's sidecars mapping, e.g. sidecars.enf.sections.TRIAL_INFO.FP1 = "Right", without interpreting or discarding raw labels. The catalog exposes sidecars as a JSON column too.

All five Parquet tables include subject_id, session_id and trial_name and are written only when they have data. Metadata JSON is always written for a readable capture, not aggregated at session level. MoveDB exposes identity columns and a JSON parameters payload (a String in Polars), not flattened measurement columns. Different datasets may use the same parameter name with different types or shapes; no common raw parameter schema is inferred.

Usage

from movedb import MoveDB
from rat_hindlimb_mocap import normalize_session_name, get_anthropometrics

dataset = MoveDB("processed")
session = normalize_session_name("Baseline")
points = dataset.get_points("BAA01", session=session, trial="Walk09")
trials = dataset.trials("BAA01", session=session)
measurements = get_anthropometrics(
    dataset, "BAA01", session, trial="Static01",
)
inventory = dataset.inventory()  # Tables, recorded rates and conversion provenance

Normalize aliases at the input boundary, then query canonical lowercase identities. Recording qualifiers are retained: 4w good data becomes week04_good_data, 12w (2nd) becomes week12_2nd, and 8w_lgs14 becomes week08_lgs14. Baseline BAD MARKERS becomes baseline_bad_markers. These are distinct recordings, not automatically pooled with the unqualified timepoint. Mappings that give two captures the same subject/session/trial identity fail before conversion. Original source directories and filenames are never renamed.

get_anthropometrics is the rat-analysis boundary: it extracts value from the seven required PROCESSING entries and returns measured Mass in kg and bilateral Femur/Tibia/FootLength in mm, without conversion. Each must contain exactly one finite, positive number; missing entries, multiple values, strings, booleans and tagged nonfinite values raise a field-specific prerequisite error. Unknown groups and entries do not affect scaling. Hand metadata or other captures lacking these rat measurements remain valid for ingestion/catalog access, but cannot supply rat scaling inputs. Without trial, extraction preserves the historical first returned parameter record; explicit selection uses only that trial, never averaging or borrowing missing values from another. The explorer displays the grouped raw metadata, not a numeric measurement table. The marker protocol is MARKER_UNITS="mm" and OPENSIM_MARKER_AXES=("x", "z", "-y"). Raw force Parquets retain C3D axes and units. FORCEPLATE_SI_SCALES supplies the recorded N→N, Nmm→Nm and mm→m factors for OpenSim exports, which use the same signed axes. The recorded moment is about the plate centre, not the COP; Osimpy owns the wrench transformation and reference shift using recorded plate geometry.

Conversion and reproducibility

Use expanded sourcedata/{subject_id}/{original_session}/{trial}.c3d recordings. Keep matching {trial}.Trial.enf and other original acquisition files beside their captures. Source session directories retain their original names and qualifiers; normalization happens only when assigning output identities.

Open the researcher-owned notebook:

uv run --extra explorer marimo edit prepare_dataset.py

Run its setup cells with the editor's Run button if outputs are not visible. Set source/output paths and press Enter to apply each field:

  1. Edit map_recordings. It calls MoveDB's discover directly, then visibly applies normalize_session_name(source.session_id). Review the original source paths and session names alongside the canonical identities.
  2. Review conversion. MoveDB validates the complete identity inventory, including normalization collisions, and shows pending/skipped counts without decoding or writing captures.
  3. Convert pending captures. One worker reports progress and real failure paths. Current captures are skipped, including when the same action is repeated.
  4. Inspect and extend. Review inventory, point/event rows, raw measurements and sidecars. Add scientific processing in custom_analysis or later cells, without rewriting canonical files.

Use Refresh source inventory after adding/removing files. After repairing a capture, click Convert again. Opening the notebook, changing paths/mappings, or refreshing inventory does not convert. There is no extraction step or cache. Inspection connections close after fetching frames, before another write.

Git LFS pointers are not C3D data. Materialize only the sessions you need before conversion, for example:

git lfs pull --include="sourcedata/K05/Baseline/**"

The published source format is expanded files, not per-session archives. Historical revisions retain the earlier archive distribution. Keep original companion files even when MoveDB does not use them.

Keep processed output on the data volume, separate from source recordings. Preserve older results when validating a fresh conversion. Changing canonical identities or removing captures does not remove old partitions; choose a fresh output root for the changed inventory.

The notebook composes MoveDB's discover, TrialSource, plan_conversion and convert_trials directly. There is no rat conversion CLI, ingestion wrapper or archive-preparation helper. Keep the notebook and dependency versions with the dataset release; conversion manifests do not record custom notebook code.

MoveDB owns decoding, staged publication and per-trial failure handling. A failed capture is reported while later captures continue. Parse and staging failures preserve the previous trial; publication is atomic per file, not across a trial. Do not overlap writers or browse while conversion is publishing. Raw ENF labels are stored as metadata, never applied as a post-conversion rewrite.

The notebook uses one worker: conversion holds one decoded capture and one emitted table. Keep staging space on the output volume. Conversion preserves missing samples and recorded units/axes; it does not introduce filtering, zero-fill, or biological interpretation.

Data explorer

Install the explorer extra, then open an existing local dataset without a download:

uv run rat-mocap-explore --data-dir /mnt/data/processed

To download and browse the published dataset:

uv run rat-mocap-explore --destination /mnt/data/rat-download --revision COMMIT

Replace COMMIT with a dataset commit or tag; omitting --revision uses the Hub's default revision. Use a fresh destination when switching releases: Hub local directories retain files removed from newer revisions. The downloader includes Parquets, parameter/manifest JSON and history.jsonl, and returns destination/processed. It runs on each download-mode launch so partial downloads and Git LFS pointers are not mistaken for a complete dataset.

The rat launcher opens MoveDB's fixed-root, read-only explorer. Inventory, provenance, metadata, table previews and selected-signal plots come from MoveDB; there is no separate rat plotting or catalog implementation. The former Gradio multi-marker overlays are not retained; the current viewer plots one selected signal. Imports neither download data nor start a server. python app.py is a local shortcut for downloading and opening the dataset, not a Gradio Space app. Hosted deployment is outside this migration.

For conversion through the generic local UI, use uv run movedb-explore.

API changes

Use from movedb import MoveDB instead of the removed open_dataset wrapper. The rat package retains session normalization, anthropometric validation and scientific constants. The former process_subject, ingest_dataset and rat-mocap-convert entry points and archive-preparation helpers are removed. Use the notebook or compose MoveDB's discovery, planning and conversion APIs.

Existing published files are not upgraded by changing application code. Missing conversion manifests/history require a fresh conversion from real C3D sources and a new dataset release; inventory may report older trials incomplete.

Current ingestion stores C3D event times in seconds (60 * minutes + seconds). Previously converted tables may contain the historical incorrect event units; re-ingest those trials rather than assuming downloading old Parquets repairs them.

Downloads last month
1,463

Space using hudsonburke/rat-hindlimb-mocap 1