dspx 1.3.7 → 1.4.1
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/README.md +97 -27
- package/binding.gyp +2 -1
- package/dist/StateResilienceConfig.d.ts +17 -0
- package/dist/StateResilienceConfig.d.ts.map +1 -0
- package/dist/StateResilienceConfig.js +2 -0
- package/dist/StateResilienceConfig.js.map +1 -0
- package/dist/bindings.d.ts +119 -9
- package/dist/bindings.d.ts.map +1 -1
- package/dist/bindings.js +177 -12
- package/dist/bindings.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/prebuilds/win32-x64/dspx.node +0 -0
- package/src/native/DspPipeline.cc +385 -108
- package/src/native/adapters/TimeAlignmentStage.cc +743 -0
- package/src/native/adapters/TimeAlignmentStage.h +183 -0
package/README.md
CHANGED
|
@@ -5,11 +5,11 @@
|
|
|
5
5
|
[](https://www.typescriptlang.org/)
|
|
6
6
|
[](./LICENSE)
|
|
7
7
|
|
|
8
|
-
> **A high-performance DSP library with native C++ acceleration,
|
|
8
|
+
> **A high-performance DSP library with native C++ acceleration, state persistence, and comprehensive time-series processing. Built for Node.js backends processing real-time biosignals, audio, and sensor data.**
|
|
9
9
|
|
|
10
10
|
** v1.0.0 Release** Fully tested (500+ tests passing), battle-tested architecture, comprehensive documentation. Ready for production workloads.
|
|
11
11
|
|
|
12
|
-
A modern DSP library built for Node.js backends processing real-time biosignals, audio streams, and sensor data. Features native C++ filters with full state serialization to Redis, enabling seamless processing across service restarts and distributed workers.
|
|
12
|
+
A modern DSP library built for Node.js backends processing real-time biosignals, audio streams, and sensor data. Features native C++ filters with full state serialization (to Redis, S3, or any storage backend), enabling seamless processing across service restarts and distributed workers.
|
|
13
13
|
|
|
14
14
|
---
|
|
15
15
|
|
|
@@ -39,7 +39,7 @@ graph TB
|
|
|
39
39
|
TS_API["TypeScript API<br/>bindings.ts"]
|
|
40
40
|
TS_TYPES["Type Definitions<br/>types.ts"]
|
|
41
41
|
TS_UTILS["Utilities<br/>CircularLogBuffer, TopicRouter"]
|
|
42
|
-
|
|
42
|
+
TS_PERSIST["Persistence Backends<br/>backends.ts (Redis, S3, etc.)"]
|
|
43
43
|
end
|
|
44
44
|
|
|
45
45
|
subgraph "N-API Bridge Layer"
|
|
@@ -69,12 +69,12 @@ graph TB
|
|
|
69
69
|
end
|
|
70
70
|
|
|
71
71
|
subgraph "External Services"
|
|
72
|
-
|
|
72
|
+
PERSIST_DB[("Storage<br/>(Redis, S3, etc.)")]
|
|
73
73
|
end
|
|
74
74
|
|
|
75
75
|
%% Connections
|
|
76
76
|
TS_API --> NAPI
|
|
77
|
-
|
|
77
|
+
TS_PERSIST --> PERSIST_DB
|
|
78
78
|
NAPI --> PIPELINE
|
|
79
79
|
PIPELINE --> ADAPTER_EXAMPLE
|
|
80
80
|
PIPELINE --> ADAPTER_STATELESS
|
|
@@ -97,13 +97,13 @@ graph TB
|
|
|
97
97
|
classDef cppUtils fill:#a8c5e2,stroke:#7a9fbe,color:#000
|
|
98
98
|
classDef external fill:#dc382d,stroke:#a82820,color:#fff
|
|
99
99
|
|
|
100
|
-
class TS_API,TS_TYPES,TS_UTILS,
|
|
100
|
+
class TS_API,TS_TYPES,TS_UTILS,TS_PERSIST tsLayer
|
|
101
101
|
class CORE_MA,CORE_RMS,CORE_MAV,CORE_VAR,CORE_ZSCORE cppCore
|
|
102
102
|
class CORE_ENGINE cppEngine
|
|
103
103
|
class POLICY_MEAN,POLICY_RMS,POLICY_MAV,POLICY_VAR,POLICY_ZSCORE cppPolicy
|
|
104
104
|
class ADAPTER_MA,ADAPTER_RMS,ADAPTER_RECT,ADAPTER_VAR,ADAPTER_ZSCORE cppAdapter
|
|
105
105
|
class CIRCULAR cppUtils
|
|
106
|
-
class
|
|
106
|
+
class PERSIST_DB external
|
|
107
107
|
```
|
|
108
108
|
|
|
109
109
|
### Key Architectural Principles
|
|
@@ -178,7 +178,7 @@ class MovingAverageFilter {
|
|
|
178
178
|
|
|
179
179
|
**3. Layered Design**
|
|
180
180
|
|
|
181
|
-
- **TypeScript Layer**: User-facing API, type safety,
|
|
181
|
+
- **TypeScript Layer**: User-facing API, type safety, state persistence integration
|
|
182
182
|
- **N-API Bridge**: Zero-copy data marshaling between JS and C++
|
|
183
183
|
- **C++ Core**: High-performance DSP algorithms with optimized memory management
|
|
184
184
|
|
|
@@ -192,7 +192,7 @@ State serialization uses a **layered delegation pattern** (see section 2.1):
|
|
|
192
192
|
|
|
193
193
|
Full state serialization to JSON enables:
|
|
194
194
|
|
|
195
|
-
- ✅
|
|
195
|
+
- ✅ State persistence for distributed processing
|
|
196
196
|
- ✅ Process continuity across restarts
|
|
197
197
|
- ✅ State migration between workers
|
|
198
198
|
- ✅ Data integrity validation on deserialization
|
|
@@ -210,7 +210,7 @@ This separation enables:
|
|
|
210
210
|
- ✅ Reuse of core DSP code in other projects
|
|
211
211
|
- ✅ Type-safe TypeScript API with IntelliSense
|
|
212
212
|
- ✅ Zero-copy performance through N-API
|
|
213
|
-
- ✅ Distributed processing with Redis
|
|
213
|
+
- ✅ Distributed processing with state sharing (Redis, S3, etc.)
|
|
214
214
|
|
|
215
215
|
**6. Native C++ Backend**
|
|
216
216
|
|
|
@@ -219,7 +219,7 @@ This separation enables:
|
|
|
219
219
|
- **Optimized Data Structures**: Circular buffers with O(1) operations
|
|
220
220
|
- **Template-Based**: Generic implementation supports int, float, double
|
|
221
221
|
|
|
222
|
-
**7.
|
|
222
|
+
**7. State Persistence**
|
|
223
223
|
|
|
224
224
|
The state serialization includes:
|
|
225
225
|
|
|
@@ -303,14 +303,14 @@ const output = await pipeline.process(input, {
|
|
|
303
303
|
|
|
304
304
|
## 📊 Comparison with Alternatives
|
|
305
305
|
|
|
306
|
-
| Feature | dspx
|
|
307
|
-
| ------------------ |
|
|
308
|
-
| TypeScript Support | ✅ Native
|
|
309
|
-
| Performance | ⚡⚡⚡ Native C++
|
|
310
|
-
| State Persistence | ✅ Redis
|
|
311
|
-
| Multi-Channel | ✅ Built-in
|
|
312
|
-
| Node.js Backend | ✅ Designed for
|
|
313
|
-
| Observability | ✅ Callbacks
|
|
306
|
+
| Feature | dspx | scipy/numpy | dsp.js | Web Audio API |
|
|
307
|
+
| ------------------ | ---------------------- | ------------------- | ---------- | --------------- |
|
|
308
|
+
| TypeScript Support | ✅ Native | ❌ Python-only | ⚠️ Partial | ✅ Browser-only |
|
|
309
|
+
| Performance | ⚡⚡⚡ Native C++ | ⚡⚡⚡⚡ | ⚡ Pure JS | ⚡⚡⚡ |
|
|
310
|
+
| State Persistence | ✅ Yes (Redis/S3/etc.) | ❌ Manual | ❌ None | ❌ None |
|
|
311
|
+
| Multi-Channel | ✅ Built-in | ✅ NumPy arrays | ⚠️ Limited | ✅ AudioBuffer |
|
|
312
|
+
| Node.js Backend | ✅ Designed for | ❌ Context switch | ✅ Yes | ❌ Browser |
|
|
313
|
+
| Observability | ✅ Callbacks | ❌ Print statements | ❌ None | ⚠️ Limited |
|
|
314
314
|
|
|
315
315
|
---
|
|
316
316
|
|
|
@@ -329,7 +329,7 @@ const output = await pipeline.process(input, {
|
|
|
329
329
|
- Browser-only applications (use Web Audio API)
|
|
330
330
|
- Python-based ML pipelines (use SciPy/NumPy)
|
|
331
331
|
- Hard real-time embedded systems (use bare C/C++)
|
|
332
|
-
- Ultra-low latency (<1ms) requirements (
|
|
332
|
+
- Ultra-low latency (<1ms) requirements (state persistence adds ~1-5ms)
|
|
333
333
|
|
|
334
334
|
---
|
|
335
335
|
|
|
@@ -355,7 +355,7 @@ The DSP pipeline adds ~0.3-0.4ms overhead per operation for:
|
|
|
355
355
|
- N-API boundary crossings
|
|
356
356
|
- Output buffer allocation
|
|
357
357
|
|
|
358
|
-
For **maximum FFT performance** (when you don't need multi-stage processing or
|
|
358
|
+
For **maximum FFT performance** (when you don't need multi-stage processing or state persistence), use the direct `FftProcessor`:
|
|
359
359
|
|
|
360
360
|
```javascript
|
|
361
361
|
// ⚡ FASTER: Direct FFT (no pipeline overhead)
|
|
@@ -372,7 +372,7 @@ const result = pipeline.process(signal); // Still faster than pure JS, but ~0.3m
|
|
|
372
372
|
**When to use each:**
|
|
373
373
|
|
|
374
374
|
- **FftProcessor**: Single FFT operations, maximum speed, batch processing
|
|
375
|
-
- **Pipeline**: Multi-stage processing (filter→FFT→analysis),
|
|
375
|
+
- **Pipeline**: Multi-stage processing (filter→FFT→analysis), stateful processing, complex workflows
|
|
376
376
|
|
|
377
377
|
With recent optimizations (loop unrolling, memcpy, single-channel fast paths), dspx FFT is now **4-14x faster than fft.js** across all sizes when measured correctly. See [FFT_BENCHMARK_FIX.md](docs/FFT_BENCHMARK_FIX.md) for benchmark methodology.
|
|
378
378
|
|
|
@@ -766,7 +766,7 @@ Implements a simple moving average (SMA) filter with two modes:
|
|
|
766
766
|
- **Batch mode**: O(n) computation, no state between calls
|
|
767
767
|
- **Moving mode**: O(1) per sample with circular buffer and running sum
|
|
768
768
|
- Per-channel state for multi-channel processing
|
|
769
|
-
- Full state serialization
|
|
769
|
+
- Full state serialization support
|
|
770
770
|
|
|
771
771
|
**Example:**
|
|
772
772
|
|
|
@@ -948,7 +948,7 @@ Implements an efficient RMS filter with two modes:
|
|
|
948
948
|
- **Batch mode**: O(n) computation, no state between calls
|
|
949
949
|
- **Moving mode**: O(1) per sample with circular buffer and running sum of squares
|
|
950
950
|
- Per-channel state for multi-channel processing
|
|
951
|
-
- Full state serialization
|
|
951
|
+
- Full state serialization support
|
|
952
952
|
- Always positive output (magnitude-based)
|
|
953
953
|
|
|
954
954
|
**Example:**
|
|
@@ -999,7 +999,7 @@ Implements an efficient Mean Absolute Value filter with two modes - commonly use
|
|
|
999
999
|
- **Batch mode**: O(n) computation, no state between calls
|
|
1000
1000
|
- **Moving mode**: O(1) per sample with circular buffer and running sum of absolute values
|
|
1001
1001
|
- Per-channel state for multi-channel EMG processing
|
|
1002
|
-
- Full state serialization
|
|
1002
|
+
- Full state serialization support
|
|
1003
1003
|
- Always non-negative output
|
|
1004
1004
|
- Scale-invariant: MAV(k·x) = k·MAV(x)
|
|
1005
1005
|
|
|
@@ -1115,7 +1115,7 @@ Implements variance calculation to measure data spread and variability. Supports
|
|
|
1115
1115
|
- **Moving mode**: O(1) per-sample computation using circular buffer with running sums
|
|
1116
1116
|
- Maintains running sum and running sum of squares for efficient calculation
|
|
1117
1117
|
- Per-channel state for multi-channel processing
|
|
1118
|
-
- Full state serialization
|
|
1118
|
+
- Full state serialization support including buffer contents and running values
|
|
1119
1119
|
- Variance is always non-negative (uses max(0, calculated) to handle floating-point errors)
|
|
1120
1120
|
|
|
1121
1121
|
**Mathematical Note:**
|
|
@@ -1614,7 +1614,77 @@ See the [project roadmap](https://github.com/A-KGeorge/dspx/blob/main/ROADMAP.md
|
|
|
1614
1614
|
|
|
1615
1615
|
---
|
|
1616
1616
|
|
|
1617
|
-
##
|
|
1617
|
+
## �️ State Persistence Resilience
|
|
1618
|
+
|
|
1619
|
+
dspx provides lightweight built-in retry logic for transient failures, with seamless integration for production-grade circuit breakers.
|
|
1620
|
+
|
|
1621
|
+
### Built-in Features
|
|
1622
|
+
|
|
1623
|
+
- **Automatic Retries**: 3 attempts with exponential backoff (configurable)
|
|
1624
|
+
- **Optional Fallback**: Auto-clear state on persistent failures
|
|
1625
|
+
- **Circuit Breaker Ready**: Disabled by default to allow integration with battle-tested libraries
|
|
1626
|
+
|
|
1627
|
+
### Default Configuration
|
|
1628
|
+
|
|
1629
|
+
```typescript
|
|
1630
|
+
import { createDspPipeline } from "dspx";
|
|
1631
|
+
|
|
1632
|
+
const pipeline = createDspPipeline(); // Retries enabled, circuit breaker disabled
|
|
1633
|
+
|
|
1634
|
+
// Save with automatic retries
|
|
1635
|
+
const state = await pipeline.saveState();
|
|
1636
|
+
await redis.set("dsp:state", state);
|
|
1637
|
+
|
|
1638
|
+
// Load with retries (throws on failure)
|
|
1639
|
+
const stateFromRedis = await redis.get("dsp:state");
|
|
1640
|
+
if (stateFromRedis) {
|
|
1641
|
+
await pipeline.loadState(stateFromRedis);
|
|
1642
|
+
}
|
|
1643
|
+
```
|
|
1644
|
+
|
|
1645
|
+
### Production-Grade Circuit Breaking with Opossum
|
|
1646
|
+
|
|
1647
|
+
For critical workloads, wrap state persistence with **[opossum](https://www.npmjs.com/package/opossum)**:
|
|
1648
|
+
|
|
1649
|
+
```bash
|
|
1650
|
+
npm install opossum
|
|
1651
|
+
```
|
|
1652
|
+
|
|
1653
|
+
```typescript
|
|
1654
|
+
import CircuitBreaker from "opossum";
|
|
1655
|
+
|
|
1656
|
+
const saveBreaker = new CircuitBreaker(
|
|
1657
|
+
async (state: string | Buffer) => {
|
|
1658
|
+
await redis.set("dsp:state", state);
|
|
1659
|
+
},
|
|
1660
|
+
{
|
|
1661
|
+
timeout: 2000, // Fail if >2s
|
|
1662
|
+
errorThresholdPercentage: 50, // Trip after 50% failures
|
|
1663
|
+
resetTimeout: 30000, // Try recovery after 30s
|
|
1664
|
+
}
|
|
1665
|
+
);
|
|
1666
|
+
|
|
1667
|
+
saveBreaker.fallback(() => {
|
|
1668
|
+
console.warn("Circuit OPEN - skipping state save");
|
|
1669
|
+
});
|
|
1670
|
+
|
|
1671
|
+
// Usage
|
|
1672
|
+
const state = await pipeline.saveState({ format: "toon" });
|
|
1673
|
+
await saveBreaker.fire(state);
|
|
1674
|
+
```
|
|
1675
|
+
|
|
1676
|
+
**📚 [Full Resilience Documentation](./docs/STATE_RESILIENCE.md)** | **💡 [Opossum Example](./examples/resilience-with-opossum.cjs)**
|
|
1677
|
+
|
|
1678
|
+
Includes examples for:
|
|
1679
|
+
|
|
1680
|
+
- Circuit breaker configuration and monitoring
|
|
1681
|
+
- Prometheus metrics export
|
|
1682
|
+
- Alternative libraries (polly.js, cockatiel)
|
|
1683
|
+
- Production patterns (graceful shutdown, serverless handlers)
|
|
1684
|
+
|
|
1685
|
+
---
|
|
1686
|
+
|
|
1687
|
+
## �🔧 Advanced Features
|
|
1618
1688
|
|
|
1619
1689
|
For production deployments, the library provides comprehensive observability and monitoring capabilities:
|
|
1620
1690
|
|
package/binding.gyp
CHANGED
|
@@ -29,7 +29,8 @@
|
|
|
29
29
|
"src/native/utils/TimeSeriesBuffer.cc",
|
|
30
30
|
"src/native/adapters/FilterStage.cc",
|
|
31
31
|
"src/native/adapters/FilterBankStage.cc",
|
|
32
|
-
"src/native/adapters/FftStage.cc"
|
|
32
|
+
"src/native/adapters/FftStage.cc",
|
|
33
|
+
"src/native/adapters/TimeAlignmentStage.cc"
|
|
33
34
|
],
|
|
34
35
|
"include_dirs": [
|
|
35
36
|
"<!@(node -p \"require('node-addon-api').include\")",
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Configuration for state persistence resilience
|
|
3
|
+
*/
|
|
4
|
+
export interface StateResilienceConfig {
|
|
5
|
+
/**
|
|
6
|
+
* Maximum number of retry attempts for saveState/loadState
|
|
7
|
+
* Default: 3
|
|
8
|
+
*/
|
|
9
|
+
maxRetries?: number;
|
|
10
|
+
/**
|
|
11
|
+
* Fall back to clearState() when loadState fails
|
|
12
|
+
* Enables cold start recovery
|
|
13
|
+
* Default: false
|
|
14
|
+
*/
|
|
15
|
+
fallbackOnLoadFailure?: boolean;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=StateResilienceConfig.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StateResilienceConfig.d.ts","sourceRoot":"","sources":["../src/ts/StateResilienceConfig.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StateResilienceConfig.js","sourceRoot":"","sources":["../src/ts/StateResilienceConfig.ts"],"names":[],"mappings":""}
|
package/dist/bindings.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { ProcessOptions, MovingAverageParams, ExponentialMovingAverageParams, CumulativeMovingAverageParams, KalmanFilterParams, RmsParams, RectifyParams, VarianceParams, ZScoreNormalizeParams, MeanAbsoluteValueParams, WaveformLengthParams, SlopeSignChangeParams, WillisonAmplitudeParams, LinearRegressionParams, LmsFilterParams, InterpolateParams, DecimateParams, ResampleParams, ConvolutionParams, WaveletTransformParams, HilbertEnvelopeParams, PipelineCallbacks, RlsFilterParams, TapCallback, PipelineStateSummary, BeamformerWeightsResult, CspResult, GscPreprocessorParams, ChannelSelectorParams, ChannelSelectParams, ChannelMergeParams, FilterBankParams, ClipDetectionParams, PeakDetectionParams, CspTransformParams, fftParams, stftParams, MelSpectrogramParams, MfccParams } from "./types.js";
|
|
2
|
+
import type { StateResilienceConfig } from "./StateResilienceConfig.js";
|
|
2
3
|
import { type FilterOptions } from "./filters.js";
|
|
3
4
|
/**
|
|
4
5
|
* DSP Processor class that wraps the native C++ DspPipeline
|
|
@@ -11,7 +12,8 @@ declare class DspProcessor {
|
|
|
11
12
|
private logBuffer;
|
|
12
13
|
private tapCallbacks;
|
|
13
14
|
private driftDetector;
|
|
14
|
-
|
|
15
|
+
private stateResilienceConfig;
|
|
16
|
+
constructor(nativeInstance: any, stateResilienceConfig?: StateResilienceConfig);
|
|
15
17
|
/**
|
|
16
18
|
* Generate a Kafka-style topic for a log entry
|
|
17
19
|
*/
|
|
@@ -1082,6 +1084,80 @@ declare class DspProcessor {
|
|
|
1082
1084
|
* });
|
|
1083
1085
|
*/
|
|
1084
1086
|
KalmanFilter(params?: KalmanFilterParams): this;
|
|
1087
|
+
/**
|
|
1088
|
+
* Resample irregular timestamp data to uniform time grid (production-grade).
|
|
1089
|
+
*
|
|
1090
|
+
* This stage solves the problems of irregular sampling:
|
|
1091
|
+
* - Time-based coordinate system (not index-based)
|
|
1092
|
+
* - Gap detection and configurable handling policies
|
|
1093
|
+
* - Clock drift compensation (regression or PLL)
|
|
1094
|
+
* - Multiple interpolation methods (linear, cubic, sinc)
|
|
1095
|
+
* - Proper extrapolation policies
|
|
1096
|
+
*
|
|
1097
|
+
* **Use Cases:**
|
|
1098
|
+
* - IoT sensors with network jitter
|
|
1099
|
+
* - GPS data with dropped packets
|
|
1100
|
+
* - Medical vitals with irregular sampling
|
|
1101
|
+
* - Audio streams with clock drift
|
|
1102
|
+
* - High-frequency trading data with gaps
|
|
1103
|
+
*
|
|
1104
|
+
* @param params - Time alignment parameters
|
|
1105
|
+
* @param params.targetSampleRate - Target uniform sample rate in Hz (required)
|
|
1106
|
+
* @param params.interpolationMethod - Interpolation method: "linear" (default), "cubic", or "sinc"
|
|
1107
|
+
* @param params.gapPolicy - Gap handling: "interpolate" (default), "zero-fill", "hold", "extrapolate", or "error"
|
|
1108
|
+
* @param params.gapThreshold - Gap detection threshold (multiplier of expected interval, default: 2.0)
|
|
1109
|
+
* @param params.driftCompensation - Clock drift compensation: "none" (default), "regression", or "pll"
|
|
1110
|
+
* @returns this instance for method chaining
|
|
1111
|
+
*
|
|
1112
|
+
* @throws {TypeError} If targetSampleRate is not positive
|
|
1113
|
+
* @throws {Error} If gapPolicy="error" and gap is detected during processing
|
|
1114
|
+
*
|
|
1115
|
+
* @example
|
|
1116
|
+
* // IoT sensor with network jitter → uniform 100Hz grid
|
|
1117
|
+
* const pipeline = createDspPipeline();
|
|
1118
|
+
* pipeline
|
|
1119
|
+
* .TimeAlignment({
|
|
1120
|
+
* targetSampleRate: 100, // 100 Hz output
|
|
1121
|
+
* interpolationMethod: "linear", // Fast interpolation
|
|
1122
|
+
* gapPolicy: "interpolate", // Fill gaps with interpolation
|
|
1123
|
+
* gapThreshold: 2.0, // Detect gaps > 2x expected interval
|
|
1124
|
+
* driftCompensation: "regression" // Compensate for clock drift
|
|
1125
|
+
* })
|
|
1126
|
+
* .MovingAverage({ windowDuration: 100 })
|
|
1127
|
+
* .process(irregularSamples, irregularTimestamps, { channels: 1 });
|
|
1128
|
+
*
|
|
1129
|
+
* @example
|
|
1130
|
+
* // GPS tracking with dropped packets → cubic interpolation
|
|
1131
|
+
* const gpsResampler = createDspPipeline();
|
|
1132
|
+
* gpsResampler
|
|
1133
|
+
* .TimeAlignment({
|
|
1134
|
+
* targetSampleRate: 10, // 10 Hz output
|
|
1135
|
+
* interpolationMethod: "cubic", // Smooth interpolation
|
|
1136
|
+
* gapPolicy: "hold", // Hold last value during gaps
|
|
1137
|
+
* gapThreshold: 3.0, // Detect gaps > 300ms
|
|
1138
|
+
* driftCompensation: "pll" // Phase-locked loop compensation
|
|
1139
|
+
* })
|
|
1140
|
+
* .KalmanFilter({ dimensions: 2, processNoise: 1e-5, measurementNoise: 0.01 });
|
|
1141
|
+
*
|
|
1142
|
+
* @example
|
|
1143
|
+
* // High-frequency trading → error on gap detection
|
|
1144
|
+
* const strictResampler = createDspPipeline();
|
|
1145
|
+
* strictResampler
|
|
1146
|
+
* .TimeAlignment({
|
|
1147
|
+
* targetSampleRate: 1000, // 1kHz output
|
|
1148
|
+
* interpolationMethod: "sinc", // Band-limited interpolation
|
|
1149
|
+
* gapPolicy: "error", // Fail if gaps detected
|
|
1150
|
+
* gapThreshold: 1.5, // Strict gap detection
|
|
1151
|
+
* driftCompensation: "none" // Assume perfect clock
|
|
1152
|
+
* });
|
|
1153
|
+
*/
|
|
1154
|
+
TimeAlignment(params: {
|
|
1155
|
+
targetSampleRate: number;
|
|
1156
|
+
interpolationMethod?: "linear" | "cubic" | "sinc";
|
|
1157
|
+
gapPolicy?: "interpolate" | "zero-fill" | "zeroFill" | "hold" | "extrapolate" | "error";
|
|
1158
|
+
gapThreshold?: number;
|
|
1159
|
+
driftCompensation?: "none" | "regression" | "pll";
|
|
1160
|
+
}): this;
|
|
1085
1161
|
/**
|
|
1086
1162
|
* Apply leaky integration (accumulation) using IIR filter.
|
|
1087
1163
|
*
|
|
@@ -1816,17 +1892,26 @@ declare class DspProcessor {
|
|
|
1816
1892
|
* // Free resources when done, pipeline cannot be used after this for processing the input signal since the stages have been disposed
|
|
1817
1893
|
*/
|
|
1818
1894
|
dispose(): void;
|
|
1895
|
+
/**
|
|
1896
|
+
* Shared helper for retry logic with exponential backoff
|
|
1897
|
+
* @private
|
|
1898
|
+
*/
|
|
1899
|
+
private executeWithRetry;
|
|
1819
1900
|
/**
|
|
1820
1901
|
* Save the current pipeline state
|
|
1821
1902
|
* Supports two formats:
|
|
1822
1903
|
* - JSON (default): Returns a string for text-based storage
|
|
1823
1904
|
* - TOON: Returns a Buffer for binary serialization (60-70% smaller, faster)
|
|
1824
1905
|
*
|
|
1906
|
+
* **Resilience Features:**
|
|
1907
|
+
* - Retry with exponential backoff: 3 attempts by default (100ms, 400ms, 1600ms)
|
|
1908
|
+
* - Throws error after all retries exhausted
|
|
1909
|
+
*
|
|
1825
1910
|
* @param options - Optional configuration with format: 'json' | 'toon'
|
|
1826
1911
|
* @returns JSON string (default) or Buffer (if format: 'toon')
|
|
1827
1912
|
*
|
|
1828
1913
|
* @example
|
|
1829
|
-
* // Default JSON format
|
|
1914
|
+
* // Default JSON format with retry
|
|
1830
1915
|
* const stateJson = await pipeline.saveState();
|
|
1831
1916
|
* await redis.set('dsp:state', stateJson);
|
|
1832
1917
|
*
|
|
@@ -1834,6 +1919,8 @@ declare class DspProcessor {
|
|
|
1834
1919
|
* // TOON binary format (smaller, faster)
|
|
1835
1920
|
* const stateBinary = await pipeline.saveState({ format: 'toon' });
|
|
1836
1921
|
* await redis.set('dsp:state', stateBinary);
|
|
1922
|
+
*
|
|
1923
|
+
* @throws Error if all retries fail
|
|
1837
1924
|
*/
|
|
1838
1925
|
saveState(options?: {
|
|
1839
1926
|
format?: "json" | "toon";
|
|
@@ -1842,17 +1929,30 @@ declare class DspProcessor {
|
|
|
1842
1929
|
* Load pipeline state from JSON string or TOON binary Buffer
|
|
1843
1930
|
* Auto-detects format: Buffer → TOON, string → JSON
|
|
1844
1931
|
*
|
|
1932
|
+
* **Resilience Features:**
|
|
1933
|
+
* - Retry with exponential backoff: 3 attempts by default (100ms, 400ms, 1600ms)
|
|
1934
|
+
* - Optional fallback: Calls clearState() on failure (enable with fallbackOnLoadFailure: true)
|
|
1935
|
+
* - By default throws error after retries exhausted
|
|
1936
|
+
*
|
|
1845
1937
|
* @param state - JSON string or TOON Buffer containing the pipeline state
|
|
1846
|
-
* @returns Promise that resolves to true if successful
|
|
1938
|
+
* @returns Promise that resolves to true if successful, false if failed and fell back to clearState
|
|
1847
1939
|
*
|
|
1848
1940
|
* @example
|
|
1849
|
-
* // Load JSON state
|
|
1941
|
+
* // Load JSON state (throws on failure by default)
|
|
1850
1942
|
* const stateJson = await redis.get('dsp:state');
|
|
1851
1943
|
* if (stateJson) {
|
|
1852
1944
|
* await pipeline.loadState(stateJson);
|
|
1853
1945
|
* }
|
|
1854
1946
|
*
|
|
1855
1947
|
* @example
|
|
1948
|
+
* // With automatic fallback enabled
|
|
1949
|
+
* const pipeline = createDspPipeline({ fallbackOnLoadFailure: true });
|
|
1950
|
+
* const success = await pipeline.loadState(stateJson);
|
|
1951
|
+
* if (!success) {
|
|
1952
|
+
* console.log('State load failed, started with fresh state');
|
|
1953
|
+
* }
|
|
1954
|
+
*
|
|
1955
|
+
* @example
|
|
1856
1956
|
* // Load TOON binary state (auto-detected)
|
|
1857
1957
|
* const stateBinary = await redis.getBuffer('dsp:state');
|
|
1858
1958
|
* if (stateBinary) {
|
|
@@ -1897,18 +1997,28 @@ declare class DspProcessor {
|
|
|
1897
1997
|
}
|
|
1898
1998
|
/**
|
|
1899
1999
|
* Create a new DSP pipeline builder
|
|
1900
|
-
* @param
|
|
2000
|
+
* @param stateResilienceConfig - Optional configuration for state persistence resilience
|
|
1901
2001
|
* @returns A new DspProcessor instance
|
|
1902
2002
|
*
|
|
1903
2003
|
* @example
|
|
1904
|
-
* // Create pipeline with
|
|
2004
|
+
* // Create pipeline with default settings (3 retries, no fallback)
|
|
1905
2005
|
* const pipeline = createDspPipeline();
|
|
1906
2006
|
*
|
|
1907
2007
|
* @example
|
|
1908
|
-
* //
|
|
1909
|
-
* const pipeline = createDspPipeline(
|
|
2008
|
+
* // Custom retry configuration
|
|
2009
|
+
* const pipeline = createDspPipeline({
|
|
2010
|
+
* maxRetries: 5,
|
|
2011
|
+
* fallbackOnLoadFailure: true
|
|
2012
|
+
* });
|
|
2013
|
+
*
|
|
2014
|
+
* @example
|
|
2015
|
+
* // Disable retries
|
|
2016
|
+
* const pipeline = createDspPipeline({
|
|
2017
|
+
* maxRetries: 1,
|
|
2018
|
+
* fallbackOnLoadFailure: false
|
|
2019
|
+
* });
|
|
1910
2020
|
*/
|
|
1911
|
-
export declare function createDspPipeline(): DspProcessor;
|
|
2021
|
+
export declare function createDspPipeline(stateResilienceConfig?: StateResilienceConfig): DspProcessor;
|
|
1912
2022
|
export { DspProcessor };
|
|
1913
2023
|
import type { PcaResult, IcaResult, WhiteningResult, PcaTransformParams, IcaTransformParams, WhiteningTransformParams } from "./types.js";
|
|
1914
2024
|
/**
|
package/dist/bindings.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bindings.d.ts","sourceRoot":"","sources":["../src/ts/bindings.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,cAAc,EACd,mBAAmB,EACnB,8BAA8B,EAC9B,6BAA6B,EAC7B,kBAAkB,EAClB,SAAS,EACT,aAAa,EACb,cAAc,EACd,qBAAqB,EACrB,uBAAuB,EACvB,oBAAoB,EACpB,qBAAqB,EACrB,uBAAuB,EACvB,sBAAsB,EACtB,eAAe,EACf,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,sBAAsB,EACtB,qBAAqB,EACrB,iBAAiB,EACjB,eAAe,EAGf,WAAW,EACX,oBAAoB,EACpB,uBAAuB,EACvB,SAAS,EACT,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,EACnB,kBAAkB,EAClB,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,kBAAkB,EAClB,SAAS,EACT,UAAU,EACV,oBAAoB,EACpB,UAAU,EACX,MAAM,YAAY,CAAC;AAGpB,OAAO,EAGL,KAAK,aAAa,EAGnB,MAAM,cAAc,CAAC;AAkCtB;;;GAGG;AACH,cAAM,YAAY;
|
|
1
|
+
{"version":3,"file":"bindings.d.ts","sourceRoot":"","sources":["../src/ts/bindings.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,cAAc,EACd,mBAAmB,EACnB,8BAA8B,EAC9B,6BAA6B,EAC7B,kBAAkB,EAClB,SAAS,EACT,aAAa,EACb,cAAc,EACd,qBAAqB,EACrB,uBAAuB,EACvB,oBAAoB,EACpB,qBAAqB,EACrB,uBAAuB,EACvB,sBAAsB,EACtB,eAAe,EACf,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,sBAAsB,EACtB,qBAAqB,EACrB,iBAAiB,EACjB,eAAe,EAGf,WAAW,EACX,oBAAoB,EACpB,uBAAuB,EACvB,SAAS,EACT,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,EACnB,kBAAkB,EAClB,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,kBAAkB,EAClB,SAAS,EACT,UAAU,EACV,oBAAoB,EACpB,UAAU,EACX,MAAM,YAAY,CAAC;AAGpB,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAGL,KAAK,aAAa,EAGnB,MAAM,cAAc,CAAC;AAkCtB;;;GAGG;AACH,cAAM,YAAY;IAUd,OAAO,CAAC,cAAc;IATxB,OAAO,CAAC,MAAM,CAAgB;IAC9B,OAAO,CAAC,SAAS,CAAC,CAAoB;IACtC,OAAO,CAAC,SAAS,CAAoB;IACrC,OAAO,CAAC,YAAY,CACf;IACL,OAAO,CAAC,aAAa,CAA8B;IACnD,OAAO,CAAC,qBAAqB,CAAwB;gBAG3C,cAAc,EAAE,GAAG,EAC3B,qBAAqB,CAAC,EAAE,qBAAqB;IAc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