Files
orisys-sdk/examples
ykcheungab b956d071ea 滤波说明落到文档与 examples:三级位置/性质、四个预设、可追溯性清单 - What: 新增 docs/filters.md(json.load 不支持注释,故建议以"代码预设 + 文档 + 可复制配置"承载:三级滤波的作用位置与性质对照——flow_ema_alpha 在 compute_flow/HHD 之前、改变测量故两次录制不可比,中值与低通是读数滤波;取值规则:每级按值开关、非法值一律关、filters.enabled 仅作废弃别名、显式键优先于预设;FILTER_PRESETS 四个档位的延迟与用途表;configure()/filters_state() 用法;force_triplets() 两个 buffer 的语义与尖峰实测 10/999;可追溯性五条清单)与 examples/filters/README.md(off/low_latency/balanced/low_noise 四段可直接整块替换的 filters 配置、preset 等价写法、"从预设出发只改一个键"的写法、复制后用 filters_state() 核对生效值的片段)。 - Why: 用户提出"在 json 里加 comment 说明建议的滤波,或在 examples 里写",查证 configs.py 使用 json.load 且环境无 json5/commentjson,加注释会导致加载失败;因此把建议做成可执行预设并在文档与 examples 中给出可复制版本。 - Verification: 文档中的四个预设与 FILTER_PRESETS 逐值一致;示例片段与 sensors/*/sensor.json 的 filters 段结构一致;filters_state()/force_triplets() 的行为已用 external-frame 模式实测(预设解析结果与尖峰 10/999 对照)。 - Not in this change: 未生成四个独立的 sensor_<preset>.json 整机配置文件(README 里给的是整块 filters 段);calibration.py 指纹尚未改读 filters_state();venv 内 SDK 未升级;app 侧 wrapper/齿轮与 CSV 17 列未动。
2026-09-14 10:36:00 +08:00
..
滤波说明落到文档与 examples:三级位置/性质、四个预设、可追溯性清单 - What: 新增 docs/filters.md(json.load 不支持注释,故建议以"代码预设 + 文档 + 可复制配置"承载:三级滤波的作用位置与性质对照——flow_ema_alpha 在 compute_flow/HHD 之前、改变测量故两次录制不可比,中值与低通是读数滤波;取值规则:每级按值开关、非法值一律关、filters.enabled 仅作废弃别名、显式键优先于预设;FILTER_PRESETS 四个档位的延迟与用途表;configure()/filters_state() 用法;force_triplets() 两个 buffer 的语义与尖峰实测 10/999;可追溯性五条清单)与 examples/filters/README.md(off/low_latency/balanced/low_noise 四段可直接整块替换的 filters 配置、preset 等价写法、"从预设出发只改一个键"的写法、复制后用 filters_state() 核对生效值的片段)。 - Why: 用户提出"在 json 里加 comment 说明建议的滤波,或在 examples 里写",查证 configs.py 使用 json.load 且环境无 json5/commentjson,加注释会导致加载失败;因此把建议做成可执行预设并在文档与 examples 中给出可复制版本。 - Verification: 文档中的四个预设与 FILTER_PRESETS 逐值一致;示例片段与 sensors/*/sensor.json 的 filters 段结构一致;filters_state()/force_triplets() 的行为已用 external-frame 模式实测(预设解析结果与尖峰 10/999 对照)。 - Not in this change: 未生成四个独立的 sensor_<preset>.json 整机配置文件(README 里给的是整块 filters 段);calibration.py 指纹尚未改读 filters_state();venv 内 SDK 未升级;app 侧 wrapper/齿轮与 CSV 17 列未动。
2026-09-14 10:36:00 +08:00
2026-08-26 20:19:55 +08:00
2026-08-26 19:38:47 +08:00
2026-08-18 11:00:57 +08:00

Examples

Runnable demos live at the examples/ root. Shared helpers stay in pipeline/, viz/, and gui/. Run commands from the repository root.

Product Entry Points

Product Entry Default config
ORY-BOX basic_pipeline.py box
ORY-MINI mini_pipeline.py mini
ORY-FINGER (2D) finger_pipeline.py finger
ORY-FINGER (3D Qt) finger_pipeline_3dview.py finger

finger is the public ORY-FINGER config stem. dd02 remains a compatibility alias for dd02-ov.

Typical Usage

ORY-BOX:

python examples/basic_pipeline.py -v 0 -c box

ORY-MINI:

python examples/mini_pipeline.py -v 0 -c mini

ORY-FINGER 2D:

python examples/finger_pipeline.py --camera_id 0 --config finger

ORY-FINGER video file:

python examples/finger_pipeline.py --video ./data/sample.mp4 --config finger

ORY-FINGER 3D Qt dashboard:

pip install -e ".[gui]"
python examples/finger_pipeline_3dview.py --video 0 --config finger

Other Root Examples

  • plot_data.py — single-sensor OpenCV views plus PyQtGraph force charts
  • two_sensor_pipeline.py — two-sensor multiprocessing demo

Requirements

  • SDK installed from the repository root, for example pip install -e .
  • camera index or test video path
  • matching config names under ./config/ (or packaged orisys/configs/)

Qt / PyQtGraph examples additionally require:

pip install -e ".[gui]"

Notes

  • finger_pipeline_3dview.py is the main interactive finger demo. It uses gui/app_paths.py so the same entry works in editable and packaged runs.
  • Dashboard controls: click 启动 to start acquisition; use Record CSV / Stop CSV and the CSV save-directory browser to log contact/force data; Q quits, R resets, S starts video recording, E stops video recording, and Esc toggles fullscreen.
  • finger_pipeline.py is the leanest finger example if you want to validate UV unroll + force/contact processing without the full dashboard.