runmat 0.5.2-dev.4 → 0.5.2-dev.5
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/artifacts/stdlib.snapshot +0 -0
- package/dist/generated/builtin-examples-catalog.d.ts.map +1 -1
- package/dist/generated/builtin-examples-catalog.js +1 -1
- package/dist/generated/builtin-examples-catalog.js.map +1 -1
- package/dist/generated/builtins-manifest.d.ts.map +1 -1
- package/dist/generated/builtins-manifest.js +0 -23
- package/dist/generated/builtins-manifest.js.map +1 -1
- package/dist/lsp/runmat_lsp.d.ts +3 -3
- package/dist/lsp/runmat_lsp.js +7 -7
- package/dist/lsp/runmat_lsp_bg.wasm +0 -0
- package/dist/lsp/runmat_lsp_bg.wasm.d.ts +3 -3
- package/dist/pkg-web/runmat_wasm_web.d.ts +4 -4
- package/dist/pkg-web/runmat_wasm_web.js +8 -8
- package/dist/pkg-web/runmat_wasm_web_bg.wasm +0 -0
- package/dist/pkg-web/runmat_wasm_web_bg.wasm.d.ts +4 -4
- package/dist/runtime/stdlib.snapshot +0 -0
- package/package.json +1 -1
- package/dist/generated/builtins/rref.d.ts +0 -4
- package/dist/generated/builtins/rref.d.ts.map +0 -1
- package/dist/generated/builtins/rref.js +0 -133
- package/dist/generated/builtins/rref.js.map +0 -1
package/dist/lsp/runmat_lsp.d.ts
CHANGED
|
@@ -42,9 +42,9 @@ export interface InitOutput {
|
|
|
42
42
|
readonly __wbindgen_export_4: WebAssembly.Table;
|
|
43
43
|
readonly __wbindgen_export_5: WebAssembly.Table;
|
|
44
44
|
readonly __externref_table_dealloc: (a: number) => void;
|
|
45
|
-
readonly
|
|
46
|
-
readonly
|
|
47
|
-
readonly
|
|
45
|
+
readonly closure4946_externref_shim: (a: number, b: number, c: any) => void;
|
|
46
|
+
readonly closure4952_externref_shim: (a: number, b: number, c: any) => void;
|
|
47
|
+
readonly closure4995_externref_shim: (a: number, b: number, c: any, d: any) => void;
|
|
48
48
|
readonly __wbindgen_start: () => void;
|
|
49
49
|
}
|
|
50
50
|
|
package/dist/lsp/runmat_lsp.js
CHANGED
|
@@ -414,15 +414,15 @@ export function setCompatMode(mode) {
|
|
|
414
414
|
}
|
|
415
415
|
|
|
416
416
|
function __wbg_adapter_36(arg0, arg1, arg2) {
|
|
417
|
-
wasm.
|
|
417
|
+
wasm.closure4946_externref_shim(arg0, arg1, arg2);
|
|
418
418
|
}
|
|
419
419
|
|
|
420
420
|
function __wbg_adapter_39(arg0, arg1, arg2) {
|
|
421
|
-
wasm.
|
|
421
|
+
wasm.closure4952_externref_shim(arg0, arg1, arg2);
|
|
422
422
|
}
|
|
423
423
|
|
|
424
424
|
function __wbg_adapter_421(arg0, arg1, arg2, arg3) {
|
|
425
|
-
wasm.
|
|
425
|
+
wasm.closure4995_externref_shim(arg0, arg1, arg2, arg3);
|
|
426
426
|
}
|
|
427
427
|
|
|
428
428
|
const __wbindgen_enum_GpuErrorFilter = ["validation", "out-of-memory", "internal"];
|
|
@@ -1296,12 +1296,12 @@ function __wbg_get_imports() {
|
|
|
1296
1296
|
const ret = false;
|
|
1297
1297
|
return ret;
|
|
1298
1298
|
};
|
|
1299
|
-
imports.wbg.
|
|
1300
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1299
|
+
imports.wbg.__wbindgen_closure_wrapper17375 = function(arg0, arg1, arg2) {
|
|
1300
|
+
const ret = makeMutClosure(arg0, arg1, 4947, __wbg_adapter_36);
|
|
1301
1301
|
return ret;
|
|
1302
1302
|
};
|
|
1303
|
-
imports.wbg.
|
|
1304
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1303
|
+
imports.wbg.__wbindgen_closure_wrapper17848 = function(arg0, arg1, arg2) {
|
|
1304
|
+
const ret = makeMutClosure(arg0, arg1, 4953, __wbg_adapter_39);
|
|
1305
1305
|
return ret;
|
|
1306
1306
|
};
|
|
1307
1307
|
imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
|
|
Binary file
|
|
@@ -23,7 +23,7 @@ export const __externref_table_alloc: () => number;
|
|
|
23
23
|
export const __wbindgen_export_4: WebAssembly.Table;
|
|
24
24
|
export const __wbindgen_export_5: WebAssembly.Table;
|
|
25
25
|
export const __externref_table_dealloc: (a: number) => void;
|
|
26
|
-
export const
|
|
27
|
-
export const
|
|
28
|
-
export const
|
|
26
|
+
export const closure4946_externref_shim: (a: number, b: number, c: any) => void;
|
|
27
|
+
export const closure4952_externref_shim: (a: number, b: number, c: any) => void;
|
|
28
|
+
export const closure4995_externref_shim: (a: number, b: number, c: any, d: any) => void;
|
|
29
29
|
export const __wbindgen_start: () => void;
|
|
@@ -136,10 +136,10 @@ export interface InitOutput {
|
|
|
136
136
|
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
137
137
|
readonly __wbindgen_export_6: WebAssembly.Table;
|
|
138
138
|
readonly __externref_table_dealloc: (a: number) => void;
|
|
139
|
-
readonly
|
|
140
|
-
readonly
|
|
141
|
-
readonly
|
|
142
|
-
readonly
|
|
139
|
+
readonly closure2940_externref_shim: (a: number, b: number, c: any) => void;
|
|
140
|
+
readonly closure8016_externref_shim: (a: number, b: number, c: any) => void;
|
|
141
|
+
readonly closure8022_externref_shim: (a: number, b: number, c: any) => void;
|
|
142
|
+
readonly closure8053_externref_shim: (a: number, b: number, c: any, d: any) => void;
|
|
143
143
|
readonly __wbindgen_start: () => void;
|
|
144
144
|
}
|
|
145
145
|
|
|
@@ -585,19 +585,19 @@ export function unsubscribeTraceEvents(id) {
|
|
|
585
585
|
}
|
|
586
586
|
|
|
587
587
|
function __wbg_adapter_56(arg0, arg1, arg2) {
|
|
588
|
-
wasm.
|
|
588
|
+
wasm.closure2940_externref_shim(arg0, arg1, arg2);
|
|
589
589
|
}
|
|
590
590
|
|
|
591
591
|
function __wbg_adapter_59(arg0, arg1, arg2) {
|
|
592
|
-
wasm.
|
|
592
|
+
wasm.closure8016_externref_shim(arg0, arg1, arg2);
|
|
593
593
|
}
|
|
594
594
|
|
|
595
595
|
function __wbg_adapter_62(arg0, arg1, arg2) {
|
|
596
|
-
wasm.
|
|
596
|
+
wasm.closure8022_externref_shim(arg0, arg1, arg2);
|
|
597
597
|
}
|
|
598
598
|
|
|
599
599
|
function __wbg_adapter_616(arg0, arg1, arg2, arg3) {
|
|
600
|
-
wasm.
|
|
600
|
+
wasm.closure8053_externref_shim(arg0, arg1, arg2, arg3);
|
|
601
601
|
}
|
|
602
602
|
|
|
603
603
|
const __wbindgen_enum_GpuErrorFilter = ["validation", "out-of-memory", "internal"];
|
|
@@ -2093,15 +2093,15 @@ function __wbg_get_imports() {
|
|
|
2093
2093
|
return ret;
|
|
2094
2094
|
};
|
|
2095
2095
|
imports.wbg.__wbindgen_closure_wrapper26024 = function(arg0, arg1, arg2) {
|
|
2096
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
2096
|
+
const ret = makeMutClosure(arg0, arg1, 8017, __wbg_adapter_59);
|
|
2097
2097
|
return ret;
|
|
2098
2098
|
};
|
|
2099
2099
|
imports.wbg.__wbindgen_closure_wrapper26439 = function(arg0, arg1, arg2) {
|
|
2100
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
2100
|
+
const ret = makeMutClosure(arg0, arg1, 8023, __wbg_adapter_62);
|
|
2101
2101
|
return ret;
|
|
2102
2102
|
};
|
|
2103
|
-
imports.wbg.
|
|
2104
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
2103
|
+
imports.wbg.__wbindgen_closure_wrapper8160 = function(arg0, arg1, arg2) {
|
|
2104
|
+
const ret = makeMutClosure(arg0, arg1, 2941, __wbg_adapter_56);
|
|
2105
2105
|
return ret;
|
|
2106
2106
|
};
|
|
2107
2107
|
imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
|
|
Binary file
|
|
@@ -69,8 +69,8 @@ export const __wbindgen_export_4: WebAssembly.Table;
|
|
|
69
69
|
export const __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
70
70
|
export const __wbindgen_export_6: WebAssembly.Table;
|
|
71
71
|
export const __externref_table_dealloc: (a: number) => void;
|
|
72
|
-
export const
|
|
73
|
-
export const
|
|
74
|
-
export const
|
|
75
|
-
export const
|
|
72
|
+
export const closure2940_externref_shim: (a: number, b: number, c: any) => void;
|
|
73
|
+
export const closure8016_externref_shim: (a: number, b: number, c: any) => void;
|
|
74
|
+
export const closure8022_externref_shim: (a: number, b: number, c: any) => void;
|
|
75
|
+
export const closure8053_externref_shim: (a: number, b: number, c: any, d: any) => void;
|
|
76
76
|
export const __wbindgen_start: () => void;
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rref.d.ts","sourceRoot":"","sources":["../../../src/generated/builtins/rref.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEpD,QAAA,MAAM,UAAU,EAAE,UAgIjB,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
// @generated by scripts/generate-builtins.cjs
|
|
2
|
-
// Do not edit by hand.
|
|
3
|
-
const builtinDoc = {
|
|
4
|
-
"title": "rref",
|
|
5
|
-
"category": "math/linalg/solve",
|
|
6
|
-
"keywords": [
|
|
7
|
-
"rref",
|
|
8
|
-
"reduced row echelon form",
|
|
9
|
-
"pivot columns",
|
|
10
|
-
"Gaussian elimination",
|
|
11
|
-
"tolerance",
|
|
12
|
-
"gpu"
|
|
13
|
-
],
|
|
14
|
-
"summary": "Compute reduced row echelon form and MATLAB-style pivot column indices.",
|
|
15
|
-
"references": [],
|
|
16
|
-
"gpu_support": {
|
|
17
|
-
"elementwise": false,
|
|
18
|
-
"reduction": false,
|
|
19
|
-
"precisions": [
|
|
20
|
-
"f32",
|
|
21
|
-
"f64"
|
|
22
|
-
],
|
|
23
|
-
"broadcasting": "none",
|
|
24
|
-
"notes": "Invokes the acceleration provider's rref hook when available; the current WGPU backend gathers to the host, runs the shared elimination implementation, and re-uploads R and pivcol to keep downstream residency intact."
|
|
25
|
-
},
|
|
26
|
-
"fusion": {
|
|
27
|
-
"elementwise": false,
|
|
28
|
-
"reduction": false,
|
|
29
|
-
"max_inputs": 1,
|
|
30
|
-
"constants": "inline"
|
|
31
|
-
},
|
|
32
|
-
"requires_feature": null,
|
|
33
|
-
"tested": {
|
|
34
|
-
"unit": "builtins::math::linalg::solve::rref::tests",
|
|
35
|
-
"gpu": "builtins::math::linalg::solve::rref::tests::rref_gpu_provider_round_trip",
|
|
36
|
-
"wgpu": "builtins::math::linalg::solve::rref::tests::rref_wgpu_matches_cpu"
|
|
37
|
-
},
|
|
38
|
-
"description": "`rref(A)` returns the reduced row echelon form of matrix `A`. `[R, pivcol] = rref(A)` also returns the 1-based pivot column indices as a row vector.",
|
|
39
|
-
"behaviors": [
|
|
40
|
-
"Supports real numeric, logical, integer, scalar, vector, matrix, and complex matrix inputs. Logical and integer inputs are promoted to double precision before elimination.",
|
|
41
|
-
"The optional second argument `rref(A, tol)` overrides the pivot tolerance. Tolerance must be a finite, non-negative real scalar.",
|
|
42
|
-
"When tolerance is omitted, RunMat uses MATLAB-compatible scaling: `max(size(A)) * eps(norm(A, inf))`.",
|
|
43
|
-
"Pivot search proceeds left to right and chooses the largest-magnitude entry in the remaining rows of the active column.",
|
|
44
|
-
"Pivot column indices in `pivcol` are MATLAB-style 1-based double values. If no pivots are found, `pivcol` has shape `1 x 0`.",
|
|
45
|
-
"Empty matrices and all-zero matrices return unchanged matrix-shaped output with no pivot columns.",
|
|
46
|
-
"Complex inputs use complex division and magnitudes during pivot selection and elimination."
|
|
47
|
-
],
|
|
48
|
-
"examples": [
|
|
49
|
-
{
|
|
50
|
-
"description": "Computing reduced row echelon form",
|
|
51
|
-
"input": "A = [1 2; 3 4];\nR = rref(A)",
|
|
52
|
-
"output": "R =\n 1 0\n 0 1"
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
"description": "Returning pivot columns",
|
|
56
|
-
"input": "A = [1 2; 2 4];\n[R, pivcol] = rref(A)",
|
|
57
|
-
"output": "R =\n 1 2\n 0 0\npivcol =\n 1"
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
"description": "Applying an explicit tolerance",
|
|
61
|
-
"input": "A = diag([1, 1e-10]);\n[R, pivcol] = rref(A, 1e-9)",
|
|
62
|
-
"output": "R =\n 1 0\n 0 0\npivcol =\n 1"
|
|
63
|
-
},
|
|
64
|
-
{
|
|
65
|
-
"description": "Reducing a row vector",
|
|
66
|
-
"input": "v = [2 4 6];\nR = rref(v)",
|
|
67
|
-
"output": "R =\n 1 2 3"
|
|
68
|
-
},
|
|
69
|
-
{
|
|
70
|
-
"description": "Using rref with gpuArray data",
|
|
71
|
-
"input": "G = gpuArray([1 2; 3 4]);\n[R, pivcol] = rref(G);\nR_host = gather(R)\npiv_host = gather(pivcol)",
|
|
72
|
-
"output": "R_host =\n 1 0\n 0 1\npiv_host =\n 1 2"
|
|
73
|
-
}
|
|
74
|
-
],
|
|
75
|
-
"faqs": [
|
|
76
|
-
{
|
|
77
|
-
"question": "How is the default tolerance chosen?",
|
|
78
|
-
"answer": "RunMat follows MATLAB's dense-matrix rule: `max(size(A)) * eps(norm(A, inf))`. Larger or more highly scaled matrices therefore receive a larger pivot cutoff."
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
"question": "What shape is `pivcol`?",
|
|
82
|
-
"answer": "`pivcol` is always a row vector of 1-based double indices. No pivots returns an empty row vector with shape `1 x 0`."
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
"question": "Does `rref` support complex matrices?",
|
|
86
|
-
"answer": "Yes. Complex values use magnitude-based pivoting and complex arithmetic for row normalization and elimination."
|
|
87
|
-
},
|
|
88
|
-
{
|
|
89
|
-
"question": "Will calling `rref` move GPU data back to the CPU?",
|
|
90
|
-
"answer": "Only when the active provider lacks a native implementation. The current WGPU backend gathers, computes on the host, and re-uploads both outputs so later GPU work can continue with resident tensors."
|
|
91
|
-
}
|
|
92
|
-
],
|
|
93
|
-
"links": [
|
|
94
|
-
{
|
|
95
|
-
"label": "rank",
|
|
96
|
-
"url": "./rank"
|
|
97
|
-
},
|
|
98
|
-
{
|
|
99
|
-
"label": "pinv",
|
|
100
|
-
"url": "./pinv"
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
"label": "lu",
|
|
104
|
-
"url": "./lu"
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
"label": "qr",
|
|
108
|
-
"url": "./qr"
|
|
109
|
-
},
|
|
110
|
-
{
|
|
111
|
-
"label": "gather",
|
|
112
|
-
"url": "./gather"
|
|
113
|
-
}
|
|
114
|
-
],
|
|
115
|
-
"source": {
|
|
116
|
-
"label": "crates/runmat-runtime/src/builtins/math/linalg/solve/rref.rs",
|
|
117
|
-
"url": "crates/runmat-runtime/src/builtins/math/linalg/solve/rref.rs"
|
|
118
|
-
},
|
|
119
|
-
"gpu_residency": "RunMat first offers `rref` to the active acceleration provider through the `rref` hook. Providers without a native implementation gather the input, run the shared host RREF algorithm, and upload both `R` and `pivcol` so downstream GPU kernels can continue without an explicit user-managed transfer.",
|
|
120
|
-
"gpu_behavior": [
|
|
121
|
-
"The current WGPU backend implements `rref` as a provider hook backed by host fallback and re-upload. The builtin is not fused into elementwise kernels; producers flush before `rref` runs, and both outputs are new resident GPU handles when the provider path is active."
|
|
122
|
-
],
|
|
123
|
-
"key": "rref",
|
|
124
|
-
"slug": "rref",
|
|
125
|
-
"aliases": [],
|
|
126
|
-
"categoryPath": [
|
|
127
|
-
"math",
|
|
128
|
-
"linalg",
|
|
129
|
-
"solve"
|
|
130
|
-
]
|
|
131
|
-
};
|
|
132
|
-
export default builtinDoc;
|
|
133
|
-
//# sourceMappingURL=rref.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rref.js","sourceRoot":"","sources":["../../../src/generated/builtins/rref.ts"],"names":[],"mappings":"AAAA,8CAA8C;AAC9C,uBAAuB;AAIvB,MAAM,UAAU,GAAe;IAC7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