@miadi/ava8-measure 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +174 -0
- package/dist/audio.d.ts +343 -0
- package/dist/audio.d.ts.map +1 -0
- package/dist/audio.js +821 -0
- package/dist/audio.js.map +1 -0
- package/dist/fft.d.ts +51 -0
- package/dist/fft.d.ts.map +1 -0
- package/dist/fft.js +246 -0
- package/dist/fft.js.map +1 -0
- package/dist/index.d.ts +112 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +183 -0
- package/dist/index.js.map +1 -0
- package/dist/midi.d.ts +333 -0
- package/dist/midi.d.ts.map +1 -0
- package/dist/midi.js +651 -0
- package/dist/midi.js.map +1 -0
- package/dist/movement.d.ts +431 -0
- package/dist/movement.d.ts.map +1 -0
- package/dist/movement.js +701 -0
- package/dist/movement.js.map +1 -0
- package/package.json +70 -0
package/dist/midi.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"midi.js","sourceRoot":"","sources":["../src/midi.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAE/C;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAA;AAE7B,6EAA6E;AAC7E,MAAM,CAAC,MAAM,aAAa,GAAqC;IAC7D,EAAE,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,YAAY,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,MAAM;IACnE,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,EAAE,EAAE,EAAE,WAAW;IAC/D,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,UAAU,EAAE,EAAE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C,CAAA;YACjD,cAAc,CAAC,GAAG,CAChB,KAAK,EACL,KAAK,CAAC,MAAM,KAAK,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAC3F,CAAA;QACH,CAAC;IACH,CAAC;IAED,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,cAAc,EAAE,CAAA;AACrE,CAAC;AAED,mFAAmF;AACnF,MAAM,UAAU,SAAS,CAAC,CAAS;IACjC,OAAO,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,EAAE,CAAA;AACrE,CAAC"}
|
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* movement.ts — read an OSC movement capture and say what the body did.
|
|
3
|
+
*
|
|
4
|
+
* A port of `atelier_movement.py` (standard library only, numpy never
|
|
5
|
+
* imported). This one has zero dependencies for the same reason: a movement
|
|
6
|
+
* take is a few thousand packets, and a module that runs everywhere is worth
|
|
7
|
+
* more here than one that runs fast. `median`, `mean` and the population
|
|
8
|
+
* standard deviation are three small functions at the bottom of this file.
|
|
9
|
+
* Nothing degrades, because there is nothing to degrade to.
|
|
10
|
+
*
|
|
11
|
+
* ## THE STREAM
|
|
12
|
+
*
|
|
13
|
+
* One JSON object per line — `{"t": <seconds>, "values": [f x 9]}`, OSC on the
|
|
14
|
+
* address `/wek/inputs`, nine float channels:
|
|
15
|
+
*
|
|
16
|
+
* | channels | content |
|
|
17
|
+
* |---|---|
|
|
18
|
+
* | 0–2 | linear acceleration |
|
|
19
|
+
* | 3–5 | gyroscope |
|
|
20
|
+
* | 6–8 | attitude — channel 8 is a HEADING in radians, and it wraps |
|
|
21
|
+
*
|
|
22
|
+
* ## UNITS ARE NOT DECLARED
|
|
23
|
+
*
|
|
24
|
+
* The studio's own field ledger says the channel semantic map is **absent**,
|
|
25
|
+
* and states only what the map *would* read. So every number this module
|
|
26
|
+
* returns is bare, with no unit, and no function here accepts or emits one.
|
|
27
|
+
* The music never depended on units — everything the atelier derives from
|
|
28
|
+
* these channels is a **ratio**: a value over that take's own peak, or one
|
|
29
|
+
* duration against another. Writing "2.96 m/s²" once, as if the unit were
|
|
30
|
+
* known, is a mistake already paid for.
|
|
31
|
+
*
|
|
32
|
+
* The single exception is {@link Heading.turnDegrees}: a difference of an
|
|
33
|
+
* *unwrapped* heading is a ratio of angles, not a conversion out of an unknown
|
|
34
|
+
* unit, so it may honestly be read in degrees.
|
|
35
|
+
*
|
|
36
|
+
* ## DEDUPE COMES FIRST, ALWAYS
|
|
37
|
+
*
|
|
38
|
+
* A packet whose `values` array equals its predecessor's is a **held value,
|
|
39
|
+
* not a measurement**. Holding each channel's last value between beats is the
|
|
40
|
+
* OSC literature's standard mitigation for UDP's non-assured delivery, and the
|
|
41
|
+
* conductor does it on purpose — but it is the transport speaking, not a body.
|
|
42
|
+
*
|
|
43
|
+
* Measured, on the capture of 2026-08-16 17:14:
|
|
44
|
+
*
|
|
45
|
+
* ```
|
|
46
|
+
* 1627 packets over 16.6 s 98 Hz of packets — the requested rate is real
|
|
47
|
+
* 1232 repeat the previous 76 %
|
|
48
|
+
* 395 new values 23.8 Hz actual, median gap 41 ms
|
|
49
|
+
* ```
|
|
50
|
+
*
|
|
51
|
+
* Multiplying the requested rate by ten multiplied the information by 2.4. At
|
|
52
|
+
* 10 Hz the same device produced **zero** repeats.
|
|
53
|
+
*
|
|
54
|
+
* Onsets found on the raw stream: **28 attacks spaced 120–133 ms** — regular,
|
|
55
|
+
* credible, and entirely false. That is the staircase of the held values, the
|
|
56
|
+
* conductor's repeat interval, and not his body. On the deduped stream:
|
|
57
|
+
* **15 attacks, spaced 153–1481 ms** — two bursts around a silence, which is a
|
|
58
|
+
* musical form, and which is his.
|
|
59
|
+
*
|
|
60
|
+
* So: {@link dedupe} runs first, every other function operates on the deduped
|
|
61
|
+
* stream, {@link rates} reports the held ratio prominently, and
|
|
62
|
+
* {@link onsets} takes `dedupeFirst` defaulting to `true` and says in its
|
|
63
|
+
* result whether it deduped. Turning it off is a deliberate act.
|
|
64
|
+
*
|
|
65
|
+
* @packageDocumentation
|
|
66
|
+
*/
|
|
67
|
+
/** Linear acceleration. Drives density and dynamics. */
|
|
68
|
+
export declare const ACCEL: readonly [0, 1, 2];
|
|
69
|
+
/** Gyroscope. Drives density, and — where it stops — the sections. */
|
|
70
|
+
export declare const ROTATION: readonly [3, 4, 5];
|
|
71
|
+
/** Attitude. Channel 8 is an absolute heading and wraps at 2π. */
|
|
72
|
+
export declare const ATTITUDE: readonly [6, 7, 8];
|
|
73
|
+
/** The channel that is a compass bearing in radians, not an intensity. */
|
|
74
|
+
export declare const HEADING_CHANNEL = 8;
|
|
75
|
+
/** One full turn, in radians. */
|
|
76
|
+
export declare const TWO_PI: number;
|
|
77
|
+
/**
|
|
78
|
+
* One line of the stream.
|
|
79
|
+
*
|
|
80
|
+
* `t` and `values` are declared with the types the capture writes, but
|
|
81
|
+
* {@link parse} only checks that both keys are **present** — exactly as the
|
|
82
|
+
* Python does, so packet counts agree line for line. The measuring functions
|
|
83
|
+
* re-check each value they touch and skip what they cannot read, rather than
|
|
84
|
+
* trusting this declaration.
|
|
85
|
+
*/
|
|
86
|
+
export interface Packet {
|
|
87
|
+
/** Seconds from the start of the take. */
|
|
88
|
+
t: number;
|
|
89
|
+
/** Nine channels by convention. The length is not enforced here. */
|
|
90
|
+
values: number[];
|
|
91
|
+
[key: string]: unknown;
|
|
92
|
+
}
|
|
93
|
+
/** What {@link parse} found, including what it could not use. */
|
|
94
|
+
export interface ParseResult {
|
|
95
|
+
/** The RAW packets, in file order. Nothing downstream may use them directly. */
|
|
96
|
+
packets: Packet[];
|
|
97
|
+
/** Non-empty lines read. */
|
|
98
|
+
lines: number;
|
|
99
|
+
/** Lines that were not usable packets: bad JSON, or missing `t` / `values`. */
|
|
100
|
+
malformed: number;
|
|
101
|
+
/** 1-based line numbers of those. Counted and reported, never guessed at. */
|
|
102
|
+
malformedLines: number[];
|
|
103
|
+
/**
|
|
104
|
+
* 1-based line numbers whose `values` is not an array of
|
|
105
|
+
* {@link EXPECTED_CHANNELS}. These packets are **kept** — the Python keeps
|
|
106
|
+
* them and the counts must agree — but a channel a short array does not
|
|
107
|
+
* carry is skipped by every measure, so the count is surfaced here rather
|
|
108
|
+
* than discovered as a silent hole in a mean.
|
|
109
|
+
*/
|
|
110
|
+
wrongLength: number[];
|
|
111
|
+
}
|
|
112
|
+
/** The declared packet rate against the real rate of NEW values. */
|
|
113
|
+
export interface Rates {
|
|
114
|
+
packets: number;
|
|
115
|
+
newValues: number;
|
|
116
|
+
held: number;
|
|
117
|
+
/** Report this first, always. 0 means the sensor kept up; 0.76 means it did not. */
|
|
118
|
+
heldRatio: number;
|
|
119
|
+
duration: number;
|
|
120
|
+
packetHz: number;
|
|
121
|
+
/** The honest resolution is this number, not `packetHz`. */
|
|
122
|
+
newValueHz: number;
|
|
123
|
+
medianGapNew: number | null;
|
|
124
|
+
resolutionMs: number | null;
|
|
125
|
+
}
|
|
126
|
+
/** `(t, |v|)` for one packet and one channel group. */
|
|
127
|
+
export interface Magnitude {
|
|
128
|
+
t: number;
|
|
129
|
+
m: number;
|
|
130
|
+
}
|
|
131
|
+
/** One group's per-second curve. One second of his body = one bar. */
|
|
132
|
+
export interface PerSecondSeries {
|
|
133
|
+
/** Whole seconds present in the take, ascending. */
|
|
134
|
+
seconds: number[];
|
|
135
|
+
/** Mean magnitude within each of those seconds. */
|
|
136
|
+
means: number[];
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Per-second curves, keyed by group name.
|
|
140
|
+
*
|
|
141
|
+
* The Python returns one flat dict with `name` and `name_seconds` keys; the
|
|
142
|
+
* same two lists live together here. Same numbers, one less thing to mis-pair.
|
|
143
|
+
*/
|
|
144
|
+
export type PerSecond = Record<string, PerSecondSeries>;
|
|
145
|
+
/** Where a note is struck when his movement plays the piece. */
|
|
146
|
+
export interface Onsets {
|
|
147
|
+
/** Seconds, rounded to 4 decimals as the Python rounds them. */
|
|
148
|
+
times: number[];
|
|
149
|
+
/** Magnitude at each attack, rounded to 4 decimals. */
|
|
150
|
+
forces: number[];
|
|
151
|
+
threshold: number | null;
|
|
152
|
+
median: number | null;
|
|
153
|
+
sigma: number | null;
|
|
154
|
+
k: number;
|
|
155
|
+
minSepS: number;
|
|
156
|
+
n: number;
|
|
157
|
+
medianGap: number | null;
|
|
158
|
+
gapRange: [number, number] | null;
|
|
159
|
+
/** Whether the stream was deduped first. If `false`, doubt every number above. */
|
|
160
|
+
deduped: boolean;
|
|
161
|
+
}
|
|
162
|
+
/** Cumulative heading, and how many 2π wraps were removed to get it. */
|
|
163
|
+
export interface Heading {
|
|
164
|
+
times: number[];
|
|
165
|
+
/** The unwrapped series. This is what may drive pitch or harmonic colour. */
|
|
166
|
+
heading: number[];
|
|
167
|
+
/** The raw channel, kept so the unwrap can be checked against it. */
|
|
168
|
+
raw: number[];
|
|
169
|
+
/** Wraps removed. **If this is 0 the channel may not be a heading at all.** */
|
|
170
|
+
wraps: number;
|
|
171
|
+
turn: number;
|
|
172
|
+
/** A ratio of angles, not a converted unit — see the module header. */
|
|
173
|
+
turnDegrees: number;
|
|
174
|
+
range: [number, number] | null;
|
|
175
|
+
}
|
|
176
|
+
/** Where the chord moves. Not on a bar line, which is the point. */
|
|
177
|
+
export interface SextantChange {
|
|
178
|
+
index: number;
|
|
179
|
+
t: number | null;
|
|
180
|
+
from: number;
|
|
181
|
+
to: number;
|
|
182
|
+
}
|
|
183
|
+
/** Which nth of the compass at each moment, and where it changes. */
|
|
184
|
+
export interface Sextants {
|
|
185
|
+
n: number;
|
|
186
|
+
sextant: number[];
|
|
187
|
+
changes: SextantChange[];
|
|
188
|
+
nChanges: number;
|
|
189
|
+
/** Share of the take spent in each visited sixth, keys ascending. */
|
|
190
|
+
occupancy: Record<number, number>;
|
|
191
|
+
visited: number[];
|
|
192
|
+
}
|
|
193
|
+
/** One still span, on the per-second grid. */
|
|
194
|
+
export interface StillnessSpan {
|
|
195
|
+
startSecond: number;
|
|
196
|
+
endSecond: number;
|
|
197
|
+
duration: number;
|
|
198
|
+
}
|
|
199
|
+
/** The still spans that cut a piece into sections. */
|
|
200
|
+
export interface Stillness {
|
|
201
|
+
/** No unit, because the stream declares none. */
|
|
202
|
+
threshold: number;
|
|
203
|
+
channels: number[];
|
|
204
|
+
seconds: number[];
|
|
205
|
+
series: number[];
|
|
206
|
+
still: boolean[];
|
|
207
|
+
spans: StillnessSpan[];
|
|
208
|
+
/** The second at which each section opens. */
|
|
209
|
+
cuts: number[];
|
|
210
|
+
nSections: number;
|
|
211
|
+
stillShare: number;
|
|
212
|
+
}
|
|
213
|
+
/** Options for {@link onsets}. */
|
|
214
|
+
export interface OnsetOptions {
|
|
215
|
+
/** Channel group. Default {@link ACCEL}. */
|
|
216
|
+
channels?: readonly number[];
|
|
217
|
+
/** Sigmas above the median. Default 1.2. */
|
|
218
|
+
k?: number;
|
|
219
|
+
/** Minimum separation between attacks, seconds. Default 0.15. */
|
|
220
|
+
minSepS?: number;
|
|
221
|
+
/** **Default `true`, and it must stay true unless you mean it.** */
|
|
222
|
+
dedupeFirst?: boolean;
|
|
223
|
+
}
|
|
224
|
+
/** Options for {@link stillness}. */
|
|
225
|
+
export interface StillnessOptions {
|
|
226
|
+
/** Rotation magnitude below which a second counts as still. No unit. Default 0.5. */
|
|
227
|
+
threshold?: number;
|
|
228
|
+
/** Channel group. Default {@link ROTATION}. */
|
|
229
|
+
channels?: readonly number[];
|
|
230
|
+
/** Shortest span that counts as a section boundary, seconds. Default 1. */
|
|
231
|
+
minSpanS?: number;
|
|
232
|
+
}
|
|
233
|
+
/** Nine, by convention — and only by convention. See {@link ParseResult.wrongLength}. */
|
|
234
|
+
export declare const EXPECTED_CHANNELS = 9;
|
|
235
|
+
/**
|
|
236
|
+
* Read one capture from JSONL **text**. One JSON object per line.
|
|
237
|
+
*
|
|
238
|
+
* Text in, never a path: this library never touches the filesystem, so it runs
|
|
239
|
+
* in a browser, in a worker, or on the capture device itself, and the caller
|
|
240
|
+
* keeps the decision of where a take comes from.
|
|
241
|
+
*
|
|
242
|
+
* Malformed lines are **counted and reported**, never guessed at and never
|
|
243
|
+
* repaired. A line that is not JSON, or a packet missing `values` or `t`, is
|
|
244
|
+
* not a packet — its line number comes back in
|
|
245
|
+
* {@link ParseResult.malformedLines}. Nothing is padded, nothing is
|
|
246
|
+
* interpolated, and no channel order is assumed that the file does not show.
|
|
247
|
+
*
|
|
248
|
+
* Returns the RAW packets. **Nothing downstream should use them directly —
|
|
249
|
+
* {@link dedupe} first.** They are returned raw so that the held-value ratio
|
|
250
|
+
* can be stated at all, which is the number that tells a human whether the
|
|
251
|
+
* requested rate was real.
|
|
252
|
+
*/
|
|
253
|
+
export declare function parse(text: string): ParseResult;
|
|
254
|
+
/**
|
|
255
|
+
* Drop every packet whose `values` equal the previous packet's.
|
|
256
|
+
*
|
|
257
|
+
* **MANDATORY BEFORE ANY OTHER MOVEMENT MEASURE.** A held value is the
|
|
258
|
+
* conductor's UDP mitigation, not a sample of his body; counting it as one
|
|
259
|
+
* turns the hold interval into a rhythm and hands back a staircase. See the
|
|
260
|
+
* module header for the 28 ghost onsets this prevents.
|
|
261
|
+
*
|
|
262
|
+
* Equality is element-wise over the array, as Python's `!=` on two lists is:
|
|
263
|
+
* a different length is a different value.
|
|
264
|
+
*/
|
|
265
|
+
export declare function dedupe(packets: readonly Packet[]): Packet[];
|
|
266
|
+
/**
|
|
267
|
+
* Share of RAW packets that repeated the previous value. Report this first, always.
|
|
268
|
+
*
|
|
269
|
+
* 0 means the sensor kept up with the requested rate. 0.76 means it did not,
|
|
270
|
+
* and that the real resolution is four times coarser than the number on the
|
|
271
|
+
* box. Both are honest; only one is what was asked for.
|
|
272
|
+
*/
|
|
273
|
+
export declare function heldRatio(packets: readonly Packet[]): number;
|
|
274
|
+
/**
|
|
275
|
+
* Declared packet rate against the real rate of NEW values.
|
|
276
|
+
*
|
|
277
|
+
* Decides what resolution everything below is entitled to claim. A tempo read
|
|
278
|
+
* at 23 Hz carries roughly ±7 BPM of instrument error around 140 BPM; calling
|
|
279
|
+
* 150 and 136 different tempi without saying that would be dishonest.
|
|
280
|
+
*
|
|
281
|
+
* Takes the RAW packets — it is the one function that must, because the held
|
|
282
|
+
* count is its subject.
|
|
283
|
+
*/
|
|
284
|
+
export declare function rates(packets: readonly Packet[]): Rates;
|
|
285
|
+
/**
|
|
286
|
+
* `(t, |v|)` per packet for a channel group. Euclidean, because direction is a
|
|
287
|
+
* separate question answered by {@link unwrapHeading}.
|
|
288
|
+
*
|
|
289
|
+
* **Deduped input assumed.** The magnitude of a group is what drives density,
|
|
290
|
+
* dynamics and onsets; the sign of an individual axis depends on how the phone
|
|
291
|
+
* sat in his pocket and decides nothing.
|
|
292
|
+
*
|
|
293
|
+
* A packet whose array is too short for a requested channel, or whose entries
|
|
294
|
+
* are not numbers, is skipped — never padded with a zero, which would be a
|
|
295
|
+
* measurement of a hole. A packet whose `t` cannot be read is skipped for the
|
|
296
|
+
* same reason; this is the one place the port is gentler than the Python,
|
|
297
|
+
* which raises there.
|
|
298
|
+
*/
|
|
299
|
+
export declare function magnitudes(packets: readonly Packet[], channels?: readonly number[]): Magnitude[];
|
|
300
|
+
/**
|
|
301
|
+
* Mean magnitude per whole second, for acceleration (0–2) and rotation (3–5).
|
|
302
|
+
*
|
|
303
|
+
* **ONE SECOND OF HIS BODY = ONE BAR.** That is the whole reason this function
|
|
304
|
+
* exists: it is the bridge from a stream to a score, and it is the shape of
|
|
305
|
+
* every piece the atelier built from movement. Reading it back is how the form
|
|
306
|
+
* is checked against him — plateau, peak, dissolution — rather than against a
|
|
307
|
+
* story about him. It is a choice, and it is undone with a word.
|
|
308
|
+
*
|
|
309
|
+
* Pass a bare channel list to measure one group; it comes back under the key
|
|
310
|
+
* `channels`. Seconds are floored toward zero, as Python's `int()` is, and
|
|
311
|
+
* each group carries its own second list because a group can lose a packet the
|
|
312
|
+
* other keeps.
|
|
313
|
+
*/
|
|
314
|
+
export declare function perSecond(packets: readonly Packet[], groups?: Record<string, readonly number[]> | readonly number[]): PerSecond;
|
|
315
|
+
/**
|
|
316
|
+
* Local maxima above median + kσ, with a minimum separation. Rhythm from the body.
|
|
317
|
+
*
|
|
318
|
+
* Decides where a note is struck when his movement plays the piece. Run on the
|
|
319
|
+
* raw stream this returns the hold interval — 28 evenly spaced ghosts, spaced
|
|
320
|
+
* 120–133 ms — so `dedupeFirst` defaults to `true`, the result carries
|
|
321
|
+
* {@link Onsets.deduped} so a reader can tell which stream a number came from,
|
|
322
|
+
* and turning it off is a deliberate act.
|
|
323
|
+
*
|
|
324
|
+
* `minSepS` exists because a single gesture crosses the threshold on several
|
|
325
|
+
* consecutive new values; without it one attack is reported as three. The
|
|
326
|
+
* 0.15 s default is calibrated, not guessed: on the take of 2026-08-16 at
|
|
327
|
+
* 17:14 it returns 15 attacks in two bursts, which is what the atelier used.
|
|
328
|
+
*
|
|
329
|
+
* **Verified against that take, and the disagreement is named rather than
|
|
330
|
+
* hidden:** the count and the two-burst shape reproduce; **11 of the 15
|
|
331
|
+
* timestamps land within 30 ms of the session's own published list, and the
|
|
332
|
+
* remaining four differ, because the session's peak-picking was never written
|
|
333
|
+
* down.** Re-measure; do not quote its list.
|
|
334
|
+
*/
|
|
335
|
+
export declare function onsets(packets: readonly Packet[], options?: OnsetOptions): Onsets;
|
|
336
|
+
/**
|
|
337
|
+
* Cumulative heading, and how many 2π wraps were removed to get it.
|
|
338
|
+
*
|
|
339
|
+
* Decides the harmony in every piece where the chord follows where he is
|
|
340
|
+
* facing. Channel 8 never goes below 0 and reaches 6.28: it is a compass
|
|
341
|
+
* bearing in radians and it wraps at north.
|
|
342
|
+
*
|
|
343
|
+
* **Raw use is not a subtle error, it is a catastrophic one.** Used raw, the
|
|
344
|
+
* music leaps a whole turn every time he passes north — a leap that
|
|
345
|
+
* corresponds to **no movement of his at all**. One capture wraps thirteen
|
|
346
|
+
* times, another four.
|
|
347
|
+
*
|
|
348
|
+
* Deltas are folded into (−π, π] and accumulated. {@link Heading.wraps} is the
|
|
349
|
+
* count removed; **if it is 0, either he never crossed north or this channel
|
|
350
|
+
* is not a heading, and this reading should be doubted before a note is
|
|
351
|
+
* written on it.**
|
|
352
|
+
*
|
|
353
|
+
* Dedupes internally — always — so it is safe to hand this the raw stream.
|
|
354
|
+
*/
|
|
355
|
+
export declare function unwrapHeading(packets: readonly Packet[], channel?: number): Heading;
|
|
356
|
+
/**
|
|
357
|
+
* Which nth of the compass at each moment, and where it changes.
|
|
358
|
+
*
|
|
359
|
+
* Six harmonic stations map onto six sixths of the compass: the chord stops
|
|
360
|
+
* being chosen by a clock or a threshold and starts being chosen by the
|
|
361
|
+
* direction he is facing. He turns, the harmony turns. **The change points are
|
|
362
|
+
* the deliverable** — they are where the chord moves, and they do not fall on
|
|
363
|
+
* bar lines, which is the point.
|
|
364
|
+
*
|
|
365
|
+
* Accepts the {@link Heading} from {@link unwrapHeading} or a bare sequence of
|
|
366
|
+
* unwrapped radians; a bare sequence gets its **indices** as timestamps, which
|
|
367
|
+
* is the one reason to prefer handing over the whole {@link Heading} — the
|
|
368
|
+
* change points are wanted in seconds, not in sample numbers.
|
|
369
|
+
*
|
|
370
|
+
* **A claim this port measured and had to correct.** The skill this comes from
|
|
371
|
+
* says "feeding a raw heading here puts a chord change on every pass of
|
|
372
|
+
* north". It does not: this function takes the heading modulo a turn, so the
|
|
373
|
+
* wrapped channel and the unwrapped path produce the *identical* sextant
|
|
374
|
+
* sequence — verified on the take of 2026-08-16 17:14 and on a synthetic turn
|
|
375
|
+
* through 2π in both directions. The chord choice survives raw input. What
|
|
376
|
+
* does not survive is everything that reads the heading as a **path**: on that
|
|
377
|
+
* synthetic turn the raw channel reports +331° where he turned −29°. So
|
|
378
|
+
* {@link unwrapHeading} stays mandatory — for the turn, the range, and any
|
|
379
|
+
* pitch — and this function is simply not where the damage lands.
|
|
380
|
+
*
|
|
381
|
+
* The sanity bar the atelier used before writing a note: across five usable
|
|
382
|
+
* takes this produced 6 to 32 changes per take, always touching 2 to 4 of the
|
|
383
|
+
* six stations. One chord for a whole take, or a change every eighth, is a
|
|
384
|
+
* mapping to reject at this stage rather than after listening.
|
|
385
|
+
*/
|
|
386
|
+
export declare function sextants(heading: Heading | readonly number[], n?: number): Sextants;
|
|
387
|
+
/**
|
|
388
|
+
* The still spans that cut a piece into sections.
|
|
389
|
+
*
|
|
390
|
+
* **Where his body stops, the harmony changes.** Sections come from him and
|
|
391
|
+
* not from a bar count, and this is the function that says where. Nothing else
|
|
392
|
+
* in these nine channels segments a take as convincingly, and nothing else
|
|
393
|
+
* needs so little interpretation — a still body is a still body.
|
|
394
|
+
*
|
|
395
|
+
* Read per whole second, on the same grid as {@link perSecond}, so a section
|
|
396
|
+
* boundary and a bar boundary are the same object.
|
|
397
|
+
*
|
|
398
|
+
* `threshold` has **no unit**, because the stream declares none. 0.5 on
|
|
399
|
+
* rotation is what the atelier used; it is a choice, and it is undone by one
|
|
400
|
+
* word. The number of stations his body offers is whatever it offers — when
|
|
401
|
+
* six were wanted and the body gave four, the piece took two passes and said so.
|
|
402
|
+
*
|
|
403
|
+
* Dedupes internally — always.
|
|
404
|
+
*/
|
|
405
|
+
export declare function stillness(packets: readonly Packet[], options?: StillnessOptions): Stillness;
|
|
406
|
+
/**
|
|
407
|
+
* Middle value; the mean of the two middle values when the count is even.
|
|
408
|
+
*
|
|
409
|
+
* Preferred over the mean wherever a held-value staircase or a single lurch
|
|
410
|
+
* would drag an average somewhere no second of the take ever was.
|
|
411
|
+
*/
|
|
412
|
+
export declare function median(values: readonly number[]): number;
|
|
413
|
+
/**
|
|
414
|
+
* Arithmetic mean, summed with Neumaier compensation.
|
|
415
|
+
*
|
|
416
|
+
* The compensation is not decoration: a 93 s take is thousands of small
|
|
417
|
+
* magnitudes, and naive summation drifts exactly where the per-second curve is
|
|
418
|
+
* flattest — which is the part of the take that decides where a section opens.
|
|
419
|
+
*
|
|
420
|
+
* Throws on an empty list. An empty mean has no value, and returning 0 would
|
|
421
|
+
* put a number that was never measured into a score.
|
|
422
|
+
*/
|
|
423
|
+
export declare function mean(values: readonly number[]): number;
|
|
424
|
+
/**
|
|
425
|
+
* Population standard deviation — divided by n, not n−1.
|
|
426
|
+
*
|
|
427
|
+
* Population, because a take is not a sample of some larger take: it is all of
|
|
428
|
+
* the body there was. Used by {@link onsets} for the median + kσ threshold.
|
|
429
|
+
*/
|
|
430
|
+
export declare function pstdev(values: readonly number[]): number;
|
|
431
|
+
//# sourceMappingURL=movement.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"movement.d.ts","sourceRoot":"","sources":["../src/movement.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiEG;AAIH,wDAAwD;AACxD,eAAO,MAAM,KAAK,oBAAqB,CAAA;AAEvC,sEAAsE;AACtE,eAAO,MAAM,QAAQ,oBAAqB,CAAA;AAE1C,kEAAkE;AAClE,eAAO,MAAM,QAAQ,oBAAqB,CAAA;AAE1C,0EAA0E;AAC1E,eAAO,MAAM,eAAe,IAAI,CAAA;AAEhC,iCAAiC;AACjC,eAAO,MAAM,MAAM,QAAc,CAAA;AAIjC;;;;;;;;GAQG;AACH,MAAM,WAAW,MAAM;IACrB,0CAA0C;IAC1C,CAAC,EAAE,MAAM,CAAA;IACT,oEAAoE;IACpE,MAAM,EAAE,MAAM,EAAE,CAAA;IAChB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CACvB;AAED,i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