Skip to content

Releases: liesliy/tlabel

v0.13.0 - Motor Primitive Annotation System

Choose a tag to compare

@liesliy liesliy released this 06 Jul 03:00

🦖 v0.13.0 — Motor Primitive Annotation System

基于 T-Rex 论文定义的 22 个标准 Motor Primitive,为触觉数据提供 primitive 级别标注。

✨ New Features

  • PrimitiveAnnotation 类 — 22 个标准 Motor Primitive(wrap, lift, grasp, fold, cut, insert, press, wipe, peel, assemble, extract, twist, shake, dispense, disassemble, squeeze, pour, open, close, screw, unscrew, reach)
  • Primitive 时间轴轨道 — Panel UI 中新增彩色 primitive 轨道,在 phase 轨道下方显示
  • AI 预标注 — 基于力/接触信号的规则推断 primitive(PredictEngine.predict_primitives()
  • 导出支持 — JSON 新增 primitive_annotations 字段,CSV 新增 primitive_label
  • Demo 数据tlabel.demo('primitives_demo') 展示 reach→grasp→lift→wrap→press 序列
  • 向后兼容 — 旧版本 JSON 正常加载,无 primitive_annotations 字段时不影响

📦 API 变更

# 新增 API
import tlabel

# 添加 primitive 标注
data.add_primitive('grasp', start_frame=10, end_frame=30, confidence=0.95)

# 获取 primitive 时间线
timeline = data.get_primitive_timeline()

# AI 预标注 primitive
engine = tlabel.PredictEngine()
engine.apply_primitives(data, min_confidence=0.4)

# Demo
data = tlabel.demo('primitives_demo')
data.review()  # 显示 primitive 轨道

📁 Changed Files

  • tlabel/core/primitive.py (NEW) — PrimitiveAnnotation 类 + 22 primitive 预设
  • tlabel/core/types.py — 新增 primitive_label, primitive_confidence, primitive_annotations
  • tlabel/viewer/templates.py — Primitive 时间轴轨道 + 颜色映射
  • tlabel/predict/engine.py — predict_primitives(), apply_primitives()
  • tlabel/export/writer.py — CSV primitive_label 列
  • tlabel/adapters/tlabel_format.py — 向后兼容加载 primitive_annotations
  • tlabel/demo.py — primitives_demo
  • tlabel/_version.py, pyproject.toml — v0.13.0

v0.12.4 - 修复gelsight_images demo数据格式

Choose a tag to compare

@liesliy liesliy released this 04 Jul 05:41

v0.12.4 修复

🐛 Bug修复

  • demo('gelsight_images') 返回0帧demo_gelsight_images.json 的帧数据嵌套在 episodes[0].frames 中,但demo函数期望顶层 frames 字段
  • 修复JSON格式:帧数据移至顶层,使用正确的 tlabel_v2 结构
  • 合成图像正常生成(10帧 × 320×240灰度图)

✅ 验证

  • tlabel.demo('gelsight_images') → 10帧 + 10张合成触觉图像
  • 面板正确显示图像序列
  • 版本号显示 v0.12.4

📦 安装

pip install tlabel==0.12.4 --upgrade

v0.12.3 - 面板版本号动态化

Choose a tag to compare

@liesliy liesliy released this 04 Jul 03:32

v0.12.3 修复

🐛 Bug修复

  • 面板版本号硬编码问题templates.py 中面板标题的版本号写死为 v0.8.0,导致无论安装什么版本,面板始终显示 v0.8.0
  • 修复为动态读取 tlabel._version.__version__,面板版本号随包版本自动更新

📦 发布

v0.12.2 - 图像可视化 & Demo修复

Choose a tag to compare

@liesliy liesliy released this 03 Jul 14:05

v0.12.2

  • 修复 tlabel.demo() 未解析 image/image_path 字段的问题
  • 新增 tlabel.demo("gelsight_images") 自动生成合成触觉图像
  • 面板右侧显示触觉图像序列(播放/暂停/进度条)
  • 修复 tlabel/_version.py 版本同步问题

v0.12.0

  • 新增图像可视化:面板右侧显示触觉图像序列
  • TLabelFrame 支持 image / image_path 字段
  • 新增 examples/demo_with_images/ 数据集

v0.11.2

  • 修复 JS 语法转义 + Jupyter 初始化时序问题

v0.8.0 - FTP-1/MTTS Zarr Export

Choose a tag to compare

@liesliy liesliy released this 28 Jun 03:24

🚀 TLabel v0.8.0 — FTP-1 / MTTS Integration

New Features

  • FTP-1 Converter (tlabel/converters/ftp1.py): Export labeled data to FTP-1 MTTS Zarr format
    • tlabel_to_ftp1() / batch_to_ftp1() core functions
    • 21 MTTS functional areas (15 hand zones + 6 wrist torque channels)
    • 7 registered sensors: GelSight, GelSightMini, FreeTacMan, ViTaMIn, 3DViTac, Contactile, BinaryContact
    • 4 preset mappings: parallel_gripper, three_finger, five_finger, dexterous_hand
    • image/matrix/binary modality support
    • Auto image resize 224×224 + normalization to float32 [-1, 1]
  • data.export_ftp1(): One-line export from TLabelData
  • 🚀 Export Tab in Panel: Sensor selection, functional area picker with presets, export preview + Python command generation
  • Zarr backend: Append mode for multi-episode datasets

Installation

pip install tlabel[ftp1]   # installs zarr>=2.16

Quick Start

from tlabel import demo
data = demo("gelsight")
data.export_ftp1("output.zarr",
    sensor_name="GelSightMini",
    functional_areas=[0, 1])  # thumb tip + index fingertip

Compatibility

Exported Zarr files are directly compatible with FTP-1 for fine-tuning the world first general-purpose tactile foundation model.

v0.7.0 — Sensor Profile & Feature Metadata

Choose a tag to compare

@liesliy liesliy released this 25 Jun 14:06

What's New in v0.7.0

🆕 Sensor Profile (sensor_profile)

TLabelData now carries optional sensor metadata — elastomer properties, optical specs, and calibration status. This is the foundation for physics-aware calibration and the path toward TLabel as a sensor-agnostic metadata standard (like EXIF for images).

data.sensor_profile = {
    "sensor_type": "GelSight Mini",
    "elastomer": {"material": "PDMS", "modulus_pa": 1.8e6, "thickness_mm": 2.0},
    "optical": {"resolution": [320, 240], "fps": 30},
    "calibration": {"force_model": None, "status": "uncalibrated"}
}

🆕 Feature Metadata Registry (features_meta.py)

All 22+1 features now have static metadata: category, computation formula, physical semantics, SI units, force correlation level, and calibration dependencies. Transparent, self-documenting, no black boxes.

Categories:

  • deformation (5): contact, deformation_magnitude, force_peak, force_direction, deformation_magnitude_peak
  • gradient (4): slip_entropy, slip_event, texture_energy, edge_density
  • force_semantic (9): contact_area, centroid_x, normal_field_magnitude, shear_field_, delta_force_, friction_cone_ratio
  • temporal (4): optical_flow_*, temporal_deformation_rate, contact_transition

🆕 deformation_magnitude_peak

Honest replacement for the deprecated force_magnitude. Same computation, transparent naming — no more implying a force measurement in Newtons when the value is uncalibrated pixel intensity.

⚠️ Deprecation: force_magnitude

force_magnitude now emits a DeprecationWarning. It remains functional (alias of deformation_magnitude) but will be removed in v1.0. Migrate to deformation_magnitude_peak.

📦 Schema & Export

  • to_dict() now outputs feature_metadata and sensor_profile sections
  • schema_version bumped from 0.4.00.7.0
  • Full backward compatibility: old JSON files load without errors

✅ Tests

  • 121 tests, 119 passed
  • 2 stale version assertions in legacy test files (test_v040, test_v050) — not functional regressions

Full Changelog: v0.6.2...v0.7.0

v0.6.2 - ToucHD Demo + Regression Test

Choose a tag to compare

@liesliy liesliy released this 24 Jun 10:20

What's New

ToucHD Demo Data

tlabel.demo('touchd') now works! 100-frame simulated press sequence.

import tlabel
data = tlabel.demo('touchd')
data.review()

Release Regression Test

tests/release_regression.py — 11 tests covering all adapters and demos.

python tests/release_regression.py

Bug Fixes

  • Fix missing _version.py in wheel
  • Fix missing submodules in wheel

Full Changelog: v0.5.3...v0.6.2

v0.6.1 - ToucHD-Force Adapter

Choose a tag to compare

@liesliy liesliy released this 24 Jun 09:58

What's New

ToucHD-Force Adapter (AnyTouch 2, ICLR 2026)

Full support for ToucHD-Force dataset from AnyTouch 2 (ICLR 2026) by GeWu-Lab + BAAI.

Features:

  • 4 sensors: DIGIT, BioTip, GelSight, DuraGel
  • 3D contact force ground truth (Fx, Fy, Fz) with sensor-specific normalization
  • Action labels (press, slide, etc.) + left/right hand image selection
  • 22-dim TLabel v2 feature extraction + force-driven slip detection
  • Optical flow computation (Farneback, when cv2 available)
  • Manipulation phase inference

Usage:

import tlabel

# Auto-detect
data = tlabel.load("ToucHD-Force/", sensor="gelsight")

# With params
data = tlabel.load("ToucHD-Force/", format="touchd", sensor="digit", obj_id=6, hand="r")

# All sensors
data = tlabel.load("ToucHD-Force/", format="touchd", sensor="all")

Install:

pip install --upgrade tlabel
pip install tlabel[touchd]  # with cv2 + scipy

Full Changelog: v0.5.3...v0.6.1

v0.5.3 Hot Fix #2

Choose a tag to compare

@liesliy liesliy released this 23 Jun 08:41

v0.5.3 — Hot Fix #2

Bug Fix

  • 修复 generate_panel_html 的 NameErrorrenderDescribe() 中 JS 对象字面量 { i18n: ..., data: ... } 未在 Python f-string 中转义,导致 NameError: name 'i18n' is not defined

包含v0.5.2的修复

  • 修复PyPI打包遗漏模块(adapters/batch/converters/core/demo_data等)

包含v0.5.1的修复

  • i18n补全:雷达图22维+统计表格中英文切换
  • 深色模式:统计页数字颜色修复
  • Episode保存反馈:4秒+详细提示+防重复点击
  • QUICKSTART.md全面更新

v0.5.1 Bug Fix Release

Choose a tag to compare

@liesliy liesliy released this 23 Jun 07:33

Bug Fixes

i18n补全

  • 雷达图维度标签(22维特征)使用i18n国际化
  • 统计摘要表格的行名和列名支持中英文切换

深色模式数字不可读

  • 统计页和质量页在暗色模式下数字颜色修复
  • 切换暗色模式后自动重新渲染统计数据

Episode语义标注保存反馈优化

  • 反馈持续时间从2秒延长至4秒
  • 反馈信息更详细
  • 保存按钮点击后短暂禁用,防止重复点击

Documentation

  • QUICKSTART.md 全面更新,使用 v0.5.0+ API