Audio-based bow-change detection for string instruments
Project description
bowdet
Audio-based bow-change detection for string instruments.
bowdet detects bow changes (down-bow ↔ up-bow transitions) in bowed string instrument recordings using a two-stage mel-spectrogram boundary approach.
Install
pip install bowdet
Usage
from bowdet import detect
times = detect("recording.wav")
print(times) # array of bow-change times in seconds
Options
times = detect(
"recording.wav",
threshold=0.40, # classification threshold (default: 0.40)
min_dist_sec=0.12, # minimum distance between events in seconds
)
Method
The system uses a two-stage pipeline:
-
Stage 1 — Boundary Proposal: Computes log-mel spectrogram boundary strength (L2 norm of frame differences), and proposes candidate bow-change positions at spectral peaks.
-
Stage 2 — Candidate Classification: A compact CNN fused with 15 acoustic boundary features classifies each candidate as a bow change or not.
Key insight: Bow changes produce a broadband energy transition visible in the log-mel spectrogram, spanning approximately 100–300 ms across all frequency bands.
Performance
Evaluated under leave-one-performer-out (LOPO) on 6 viola performers (9 recordings, ~17.7 min, 1,020 annotated bow changes):
| Metric | Score |
|---|---|
| IoU@0.1 F1 | 0.645 ± 0.012 |
| Point F1 @100ms | 0.635 |
Citation
If you use bowdet in your research, please cite:
Yuan, H. and Su, Y. (2026). Audio-Based Bow-Change Detection in Viola Performance:
A Two-Stage Mel-Spectrogram Boundary Approach.
Late-Breaking/Demo Session, ISMIR 2026.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bowdet-0.2.0.tar.gz.
File metadata
- Download URL: bowdet-0.2.0.tar.gz
- Upload date:
- Size: 115.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6012cdf72091f69efb3ef13506aa4bfe92553f6615f8f11ebacb37beef12b8f3
|
|
| MD5 |
370372922c7c165f3db3d998190859cb
|
|
| BLAKE2b-256 |
fee1dc12245d126e48247cf68361a956790d0ad0873ec593f247f020d0c8c0b0
|
File details
Details for the file bowdet-0.2.0-py3-none-any.whl.
File metadata
- Download URL: bowdet-0.2.0-py3-none-any.whl
- Upload date:
- Size: 114.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
76d4164989fd303d3cd40223eedad11e16190007cf819993a6245ee1f766ba35
|
|
| MD5 |
b3e4b05c50de85179d4e53f5aca91b62
|
|
| BLAKE2b-256 |
fdd96adb24fa856c2f6c1746c23b90fc619109bb0cfd72773a050ab11e6c9ac5
|