@neilberkman/sidereon 1.0.1 → 1.1.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/CHANGELOG.md +30 -1
- package/THIRD-PARTY-NOTICES.md +2 -2
- package/package.json +1 -1
- package/pkg/sidereon.d.ts +2060 -1953
- package/pkg/sidereon.js +26 -5
- package/pkg/sidereon_bg.wasm +0 -0
- package/pkg/sidereon_bg.wasm.d.ts +1945 -1944
- package/pkg-node/sidereon.d.ts +115 -9
- package/pkg-node/sidereon.js +27 -5
- package/pkg-node/sidereon_bg.wasm +0 -0
- package/pkg-node/sidereon_bg.wasm.d.ts +1945 -1944
package/pkg-node/sidereon.d.ts
CHANGED
|
@@ -6,6 +6,102 @@ export type Vec3 = [number, number, number] | Float64Array;
|
|
|
6
6
|
export type Vec4 = [number, number, number, number] | Float64Array;
|
|
7
7
|
export type Matrix3 = number[] | Float64Array;
|
|
8
8
|
|
|
9
|
+
export interface SourceSensor {
|
|
10
|
+
/** Sensor position in a caller-chosen 2D or 3D Cartesian frame, in metres. */
|
|
11
|
+
positionM: number[] | Float64Array;
|
|
12
|
+
/** Optional propagation-speed override for this sensor, in metres per second. */
|
|
13
|
+
propagationSpeedMS?: number;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export type SourceLocateMode = "toa" | "ToA" | "TOA" | "tdoa" | "TDOA";
|
|
17
|
+
|
|
18
|
+
export interface SourceSolveModeObject {
|
|
19
|
+
mode?: SourceLocateMode;
|
|
20
|
+
referenceSensor?: number;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export type SourceSolveMode = SourceLocateMode | SourceSolveModeObject;
|
|
24
|
+
|
|
25
|
+
export interface SourceLocateOptions {
|
|
26
|
+
mode?: SourceLocateMode;
|
|
27
|
+
/** Reference sensor index for TDOA mode; defaults to zero. */
|
|
28
|
+
referenceSensor?: number;
|
|
29
|
+
/** Timing standard deviation used for covariance, CRLB, and influence scores. */
|
|
30
|
+
timingSigmaS?: number;
|
|
31
|
+
/**
|
|
32
|
+
* Whether to compute per-sensor leave-one-out influence diagnostics.
|
|
33
|
+
* Defaults to true. Set to false to skip one nonlinear re-solve per sensor;
|
|
34
|
+
* perSensorInfluence is then empty and every other output is bit-identical.
|
|
35
|
+
*/
|
|
36
|
+
includeInfluence?: boolean;
|
|
37
|
+
loss?: "linear" | "softL1" | "soft_l1" | "huber" | "cauchy" | "arctan";
|
|
38
|
+
fScaleS?: number;
|
|
39
|
+
ftol?: number;
|
|
40
|
+
xtol?: number;
|
|
41
|
+
gtol?: number;
|
|
42
|
+
maxNfev?: number;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface SourceInitialGuess {
|
|
46
|
+
positionM: number[];
|
|
47
|
+
originTimeS: number | null;
|
|
48
|
+
residualRmsS: number;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface SourceResidual {
|
|
52
|
+
sensorIndex: number;
|
|
53
|
+
referenceSensorIndex: number | null;
|
|
54
|
+
residualS: number;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export interface SourceSensorInfluence {
|
|
58
|
+
sensorIndex: number;
|
|
59
|
+
residualS: number;
|
|
60
|
+
leaveOneOutResidualS: number | null;
|
|
61
|
+
positionDeltaM: number | null;
|
|
62
|
+
originTimeDeltaS: number | null;
|
|
63
|
+
/** First-derivative robust-loss weight for the full-solution residual. */
|
|
64
|
+
lossWeight: number;
|
|
65
|
+
/**
|
|
66
|
+
* max(abs(residualS), abs(leaveOneOutResidualS)) / timingSigmaS, or
|
|
67
|
+
* abs(residualS) / timingSigmaS when the leave-one-out solve is unavailable.
|
|
68
|
+
* Robust-loss downweighting is reported separately in lossWeight.
|
|
69
|
+
*/
|
|
70
|
+
score: number;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export interface SourceCovariance {
|
|
74
|
+
state: number[][];
|
|
75
|
+
positionM2: number[][];
|
|
76
|
+
originTimeS2: number | null;
|
|
77
|
+
timingSigmaS: number;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export interface SourceGeometryQuality {
|
|
81
|
+
tier: "RankDeficient" | "ZeroRedundancy" | "Weak" | "Nominal";
|
|
82
|
+
redundancy: number;
|
|
83
|
+
rank: number;
|
|
84
|
+
conditionNumber: number;
|
|
85
|
+
gdop: number;
|
|
86
|
+
raimCheckable: boolean;
|
|
87
|
+
covarianceValidated: boolean;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export interface SourceSolution {
|
|
91
|
+
positionM: number[];
|
|
92
|
+
originTimeS: number | null;
|
|
93
|
+
covariance: SourceCovariance | null;
|
|
94
|
+
residuals: SourceResidual[];
|
|
95
|
+
perSensorInfluence: SourceSensorInfluence[];
|
|
96
|
+
geometryQuality: SourceGeometryQuality;
|
|
97
|
+
initialGuess: SourceInitialGuess;
|
|
98
|
+
status: number;
|
|
99
|
+
nfev: number;
|
|
100
|
+
njev: number;
|
|
101
|
+
cost: number;
|
|
102
|
+
optimality: number;
|
|
103
|
+
}
|
|
104
|
+
|
|
9
105
|
export interface ExactProductIdentityInput {
|
|
10
106
|
family: "sp3" | "ionex" | "clk" | "nav";
|
|
11
107
|
analysisCenter: string;
|
|
@@ -9417,13 +9513,11 @@ export function cfarCaPfaFromMultiplier(searched_cells: number, multiplier: numb
|
|
|
9417
9513
|
export function cfarCaThreshold(searched_cells: number, false_alarm_probability: number, noise_level: number): number;
|
|
9418
9514
|
|
|
9419
9515
|
/**
|
|
9420
|
-
*
|
|
9516
|
+
* Deprecated alias for [`closed_form_initial_guess`].
|
|
9421
9517
|
*
|
|
9422
|
-
*
|
|
9423
|
-
* Per-sensor speed overrides are not used by the closed-form equations, but
|
|
9424
|
-
* they are used by [`locateSource`] during iterative refinement.
|
|
9518
|
+
* @deprecated Use `closedFormInitialGuess` instead.
|
|
9425
9519
|
*/
|
|
9426
|
-
export function chanHoInitialGuess(sensors:
|
|
9520
|
+
export function chanHoInitialGuess(sensors: SourceSensor[], arrivalTimesS: number[] | Float64Array, propagationSpeedMS: number, mode: SourceSolveMode): SourceInitialGuess;
|
|
9427
9521
|
|
|
9428
9522
|
/**
|
|
9429
9523
|
* Returns `true` when a diff has any findings.
|
|
@@ -9435,6 +9529,15 @@ export function changed(diff: any): boolean;
|
|
|
9435
9529
|
*/
|
|
9436
9530
|
export function civilToJ2000Seconds(year: number, month: number, day: number, hour: number, minute: number, second: number): number;
|
|
9437
9531
|
|
|
9532
|
+
/**
|
|
9533
|
+
* Compute the closed-form spherical-intersection seed used by [`locateSource`].
|
|
9534
|
+
*
|
|
9535
|
+
* `mode` is `"toa"`, `"tdoa"`, or `{ mode: "tdoa", referenceSensor }`.
|
|
9536
|
+
* Per-sensor speed overrides are not used by the closed-form equations, but
|
|
9537
|
+
* they are used by [`locateSource`] during iterative refinement.
|
|
9538
|
+
*/
|
|
9539
|
+
export function closedFormInitialGuess(sensors: SourceSensor[], arrivalTimesS: number[] | Float64Array, propagationSpeedMS: number, mode: SourceSolveMode): SourceInitialGuess;
|
|
9540
|
+
|
|
9438
9541
|
/**
|
|
9439
9542
|
* Carrier-to-noise-density ratio, dB-Hz. `otherLossesDb` defaults to 0.
|
|
9440
9543
|
*/
|
|
@@ -10759,9 +10862,12 @@ export function loadSp3(bytes: Uint8Array): Sp3;
|
|
|
10759
10862
|
* the same dimension. `arrivalTimesS` is an aligned seconds array,
|
|
10760
10863
|
* `propagationSpeedMS` is the call-level speed in metres per second, and
|
|
10761
10864
|
* `options` may include `mode`, `referenceSensor`, `timingSigmaS`, `loss`,
|
|
10762
|
-
* `fScaleS`, `ftol`, `xtol`, `gtol`, and `
|
|
10865
|
+
* `fScaleS`, `ftol`, `xtol`, `gtol`, `maxNfev`, and `includeInfluence`.
|
|
10866
|
+
* `includeInfluence` defaults to `true`; set it to `false` to skip the
|
|
10867
|
+
* per-sensor leave-one-out re-solves and return an empty `perSensorInfluence`
|
|
10868
|
+
* array without changing any other output.
|
|
10763
10869
|
*/
|
|
10764
|
-
export function locateSource(sensors:
|
|
10870
|
+
export function locateSource(sensors: SourceSensor[], arrivalTimesS: number[] | Float64Array, propagationSpeedMS: number, options?: SourceLocateOptions | null): SourceSolution;
|
|
10765
10871
|
|
|
10766
10872
|
export function lunarSolarEclipses(start_unix_us: bigint, end_unix_us: bigint, step_s: number, tolerance_s: number): any;
|
|
10767
10873
|
|
|
@@ -12098,12 +12204,12 @@ export function sourceDop(sensors: any, source_position_m: any, propagation_spee
|
|
|
12098
12204
|
/**
|
|
12099
12205
|
* Return the plain mode object for TDOA solves against `referenceSensor`.
|
|
12100
12206
|
*/
|
|
12101
|
-
export function sourceSolveModeTdoa(
|
|
12207
|
+
export function sourceSolveModeTdoa(referenceSensor: number): { mode: "tdoa"; referenceSensor: number };
|
|
12102
12208
|
|
|
12103
12209
|
/**
|
|
12104
12210
|
* Return the plain mode value for absolute time-of-arrival solves.
|
|
12105
12211
|
*/
|
|
12106
|
-
export function sourceSolveModeToa():
|
|
12212
|
+
export function sourceSolveModeToa(): "toa";
|
|
12107
12213
|
|
|
12108
12214
|
/**
|
|
12109
12215
|
* Return the cataloged relationship between an SP3 filename epoch and its
|
package/pkg-node/sidereon.js
CHANGED
|
@@ -22783,11 +22783,9 @@ function cfarCaThreshold(searched_cells, false_alarm_probability, noise_level) {
|
|
|
22783
22783
|
exports.cfarCaThreshold = cfarCaThreshold;
|
|
22784
22784
|
|
|
22785
22785
|
/**
|
|
22786
|
-
*
|
|
22786
|
+
* Deprecated alias for [`closed_form_initial_guess`].
|
|
22787
22787
|
*
|
|
22788
|
-
*
|
|
22789
|
-
* Per-sensor speed overrides are not used by the closed-form equations, but
|
|
22790
|
-
* they are used by [`locateSource`] during iterative refinement.
|
|
22788
|
+
* @deprecated Use `closedFormInitialGuess` instead.
|
|
22791
22789
|
* @param {any} sensors
|
|
22792
22790
|
* @param {any} arrival_times_s
|
|
22793
22791
|
* @param {number} propagation_speed_m_s
|
|
@@ -22833,6 +22831,27 @@ function civilToJ2000Seconds(year, month, day, hour, minute, second) {
|
|
|
22833
22831
|
}
|
|
22834
22832
|
exports.civilToJ2000Seconds = civilToJ2000Seconds;
|
|
22835
22833
|
|
|
22834
|
+
/**
|
|
22835
|
+
* Compute the closed-form spherical-intersection seed used by [`locateSource`].
|
|
22836
|
+
*
|
|
22837
|
+
* `mode` is `"toa"`, `"tdoa"`, or `{ mode: "tdoa", referenceSensor }`.
|
|
22838
|
+
* Per-sensor speed overrides are not used by the closed-form equations, but
|
|
22839
|
+
* they are used by [`locateSource`] during iterative refinement.
|
|
22840
|
+
* @param {any} sensors
|
|
22841
|
+
* @param {any} arrival_times_s
|
|
22842
|
+
* @param {number} propagation_speed_m_s
|
|
22843
|
+
* @param {any} mode
|
|
22844
|
+
* @returns {any}
|
|
22845
|
+
*/
|
|
22846
|
+
function closedFormInitialGuess(sensors, arrival_times_s, propagation_speed_m_s, mode) {
|
|
22847
|
+
const ret = wasm.closedFormInitialGuess(sensors, arrival_times_s, propagation_speed_m_s, mode);
|
|
22848
|
+
if (ret[2]) {
|
|
22849
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
22850
|
+
}
|
|
22851
|
+
return takeFromExternrefTable0(ret[0]);
|
|
22852
|
+
}
|
|
22853
|
+
exports.closedFormInitialGuess = closedFormInitialGuess;
|
|
22854
|
+
|
|
22836
22855
|
/**
|
|
22837
22856
|
* Carrier-to-noise-density ratio, dB-Hz. `otherLossesDb` defaults to 0.
|
|
22838
22857
|
* @param {number} eirp_dbw
|
|
@@ -26487,7 +26506,10 @@ exports.loadSp3 = loadSp3;
|
|
|
26487
26506
|
* the same dimension. `arrivalTimesS` is an aligned seconds array,
|
|
26488
26507
|
* `propagationSpeedMS` is the call-level speed in metres per second, and
|
|
26489
26508
|
* `options` may include `mode`, `referenceSensor`, `timingSigmaS`, `loss`,
|
|
26490
|
-
* `fScaleS`, `ftol`, `xtol`, `gtol`, and `
|
|
26509
|
+
* `fScaleS`, `ftol`, `xtol`, `gtol`, `maxNfev`, and `includeInfluence`.
|
|
26510
|
+
* `includeInfluence` defaults to `true`; set it to `false` to skip the
|
|
26511
|
+
* per-sensor leave-one-out re-solves and return an empty `perSensorInfluence`
|
|
26512
|
+
* array without changing any other output.
|
|
26491
26513
|
* @param {any} sensors
|
|
26492
26514
|
* @param {any} arrival_times_s
|
|
26493
26515
|
* @param {number} propagation_speed_m_s
|
|
Binary file
|