@reicek/neataptic-ts 0.1.25 → 0.1.26
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/.github/copilot-instructions.md +11 -0
- package/.github/skills/trace-analyzer-extension/SKILL.md +3 -3
- package/.github/skills/trace-analyzer-extension/assets/extension-checklist.md +1 -1
- package/.github/skills/trace-analyzer-extension/references/analyzer-extension-workflow.md +1 -1
- package/.github/skills/trace-audit-reporting/SKILL.md +3 -3
- package/.github/skills/trace-audit-reporting/references/trace-analysis-workflow.md +1 -1
- package/package.json +19 -13
- package/plans/Flappy_Bird_Folder_Documentation_Pass.md +4 -4
- package/plans/README.md +24 -0
- package/plans/Roadmap.md +62 -40
- package/plans/analyze-trace-solid-split.plans.md +66 -0
- package/plans/architecture-solid-split.plans.md +9 -15
- package/plans/asciiMaze-typescript-repair.plans.md +1 -1
- package/plans/generate-docs-solid-split.plans.md +87 -0
- package/plans/methods-docs.plans.md +25 -1
- package/plans/methods-solid-split.plans.md +14 -14
- package/plans/neat-docs.plans.md +9 -1
- package/plans/neat-test-surface-repair.plans.md +1 -1
- package/plans/render-docs-html-solid-split.plans.md +68 -0
- package/plans/src-no-explicit-any-cleanup.plans.md +1 -1
- package/plans/utils-docs.plans.md +6 -1
- package/scripts/analyze-trace/analyze-trace.analysis.ts +479 -0
- package/scripts/analyze-trace/analyze-trace.constants.ts +35 -0
- package/scripts/analyze-trace/analyze-trace.io.ts +69 -0
- package/scripts/analyze-trace/analyze-trace.report.ts +100 -0
- package/scripts/analyze-trace/analyze-trace.shared.ts +116 -0
- package/scripts/analyze-trace/analyze-trace.ts +45 -0
- package/scripts/analyze-trace/analyze-trace.types.ts +72 -0
- package/scripts/assets/theme.css +80 -23
- package/scripts/copy-examples.ts +239 -0
- package/scripts/export-onnx.ts +223 -0
- package/scripts/generate-bench-tables.ts +378 -37
- package/scripts/generate-docs/generate-docs.constants.ts +107 -0
- package/scripts/generate-docs/generate-docs.order.ts +355 -0
- package/scripts/generate-docs/generate-docs.state.ts +31 -0
- package/scripts/generate-docs/generate-docs.targets.ts +165 -0
- package/scripts/generate-docs/generate-docs.ts +63 -0
- package/scripts/generate-docs/generate-docs.types.ts +112 -0
- package/scripts/generate-docs/output/generate-docs.output.folder-index.utils.ts +167 -0
- package/scripts/generate-docs/output/generate-docs.output.ordering.utils.ts +353 -0
- package/scripts/generate-docs/output/generate-docs.output.readme.utils.ts +420 -0
- package/scripts/generate-docs/output/generate-docs.output.ts +123 -0
- package/scripts/generate-docs/output/generate-docs.output.warnings.utils.ts +219 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.collection.utils.ts +365 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.jsdoc.utils.ts +373 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.normalize.utils.ts +155 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.render.utils.ts +149 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.signature.utils.ts +289 -0
- package/scripts/generate-docs/symbols/generate-docs.symbols.ts +11 -0
- package/scripts/mermaid-cli.mjs +102 -22
- package/scripts/mermaid-cli.ts +736 -0
- package/scripts/render-docs-html/render-docs-html.assets.ts +54 -0
- package/scripts/render-docs-html/render-docs-html.mermaid.ts +245 -0
- package/scripts/{render-docs-html.sidebar.ts → render-docs-html/render-docs-html.navigation.ts} +141 -144
- package/scripts/render-docs-html/render-docs-html.pages.ts +333 -0
- package/scripts/render-docs-html/render-docs-html.shared.ts +333 -0
- package/scripts/render-docs-html/render-docs-html.types.ts +42 -0
- package/scripts/render-docs-html.ts +23 -587
- package/scripts/run-docs.ts +238 -0
- package/scripts/write-dist-docs-pkg.ts +40 -0
- package/src/README.md +75 -75
- package/src/architecture/connection/README.md +5 -5
- package/src/architecture/layer/README.md +508 -508
- package/src/architecture/network/README.md +1458 -1458
- package/src/architecture/network/activate/README.md +694 -694
- package/src/architecture/network/bootstrap/README.md +77 -77
- package/src/architecture/network/connect/README.md +74 -74
- package/src/architecture/network/deterministic/README.md +135 -135
- package/src/architecture/network/evolve/README.md +364 -364
- package/src/architecture/network/gating/README.md +130 -130
- package/src/architecture/network/genetic/README.md +399 -399
- package/src/architecture/network/mutate/README.md +897 -897
- package/src/architecture/network/onnx/README.md +720 -720
- package/src/architecture/network/onnx/export/README.md +728 -728
- package/src/architecture/network/onnx/export/layers/README.md +450 -450
- package/src/architecture/network/onnx/import/README.md +618 -618
- package/src/architecture/network/onnx/schema/README.md +32 -32
- package/src/architecture/network/prune/README.md +245 -245
- package/src/architecture/network/remove/README.md +135 -135
- package/src/architecture/network/runtime/README.md +106 -106
- package/src/architecture/network/serialize/README.md +542 -542
- package/src/architecture/network/slab/README.md +608 -608
- package/src/architecture/network/standalone/README.md +212 -212
- package/src/architecture/network/stats/README.md +84 -84
- package/src/architecture/network/topology/README.md +465 -465
- package/src/architecture/network/training/README.md +200 -200
- package/src/architecture/node/README.md +5 -5
- package/src/architecture/nodePool/README.md +14 -14
- package/src/methods/README.md +99 -99
- package/src/methods/activation/README.md +189 -189
- package/src/methods/cost/README.md +131 -131
- package/src/methods/rate/README.md +86 -86
- package/src/multithreading/README.md +77 -77
- package/src/multithreading/workers/browser/README.md +8 -8
- package/src/multithreading/workers/node/README.md +8 -8
- package/src/neat/README.md +148 -148
- package/src/neat/adaptive/README.md +120 -120
- package/src/neat/adaptive/acceptance/README.md +40 -40
- package/src/neat/adaptive/complexity/README.md +137 -137
- package/src/neat/adaptive/core/README.md +197 -197
- package/src/neat/adaptive/lineage/README.md +90 -90
- package/src/neat/adaptive/mutation/README.md +284 -284
- package/src/neat/compat/README.md +43 -43
- package/src/neat/compat/core/README.md +90 -90
- package/src/neat/diversity/README.md +35 -35
- package/src/neat/diversity/core/README.md +88 -88
- package/src/neat/evaluate/README.md +85 -85
- package/src/neat/evaluate/auto-distance/README.md +75 -75
- package/src/neat/evaluate/entropy-compat/README.md +37 -37
- package/src/neat/evaluate/entropy-sharing/README.md +43 -43
- package/src/neat/evaluate/fitness/README.md +23 -23
- package/src/neat/evaluate/novelty/README.md +120 -120
- package/src/neat/evaluate/objectives/README.md +17 -17
- package/src/neat/evaluate/shared/README.md +94 -94
- package/src/neat/evolve/README.md +96 -96
- package/src/neat/evolve/adaptive/README.md +60 -60
- package/src/neat/evolve/objectives/README.md +63 -63
- package/src/neat/evolve/offspring/README.md +56 -56
- package/src/neat/evolve/population/README.md +171 -171
- package/src/neat/evolve/runtime/README.md +79 -79
- package/src/neat/evolve/speciation/README.md +74 -74
- package/src/neat/evolve/warnings/README.md +10 -10
- package/src/neat/export/README.md +114 -114
- package/src/neat/helpers/README.md +50 -50
- package/src/neat/init/README.md +9 -9
- package/src/neat/lineage/core/README.md +101 -101
- package/src/neat/multiobjective/category/README.md +74 -74
- package/src/neat/multiobjective/crowding/README.md +272 -272
- package/src/neat/multiobjective/dominance/README.md +171 -171
- package/src/neat/multiobjective/fronts/README.md +68 -68
- package/src/neat/multiobjective/metrics/README.md +43 -43
- package/src/neat/multiobjective/objectives/README.md +31 -31
- package/src/neat/multiobjective/shared/README.md +27 -27
- package/src/neat/mutation/README.md +97 -97
- package/src/neat/mutation/add-conn/README.md +115 -115
- package/src/neat/mutation/add-node/README.md +126 -126
- package/src/neat/mutation/flow/README.md +149 -149
- package/src/neat/mutation/repair/README.md +185 -185
- package/src/neat/mutation/select/README.md +117 -117
- package/src/neat/mutation/shared/README.md +32 -32
- package/src/neat/objectives/README.md +25 -25
- package/src/neat/objectives/core/README.md +67 -67
- package/src/neat/pruning/README.md +40 -40
- package/src/neat/pruning/core/README.md +171 -171
- package/src/neat/pruning/facade/README.md +32 -32
- package/src/neat/rng/README.md +104 -104
- package/src/neat/rng/core/README.md +137 -137
- package/src/neat/rng/facade/README.md +50 -50
- package/src/neat/selection/README.md +111 -111
- package/src/neat/selection/core/README.md +227 -227
- package/src/neat/selection/facade/README.md +61 -61
- package/src/neat/shared/README.md +163 -163
- package/src/neat/speciation/README.md +31 -31
- package/src/neat/speciation/threshold/README.md +35 -35
- package/src/neat/species/README.md +25 -25
- package/src/neat/species/core/README.md +20 -20
- package/src/neat/species/core/shared/README.md +18 -18
- package/src/neat/species/history/context/README.md +22 -22
- package/src/neat/telemetry/accessors/README.md +58 -58
- package/src/neat/telemetry/exports/README.md +233 -233
- package/src/neat/telemetry/facade/README.md +252 -252
- package/src/neat/telemetry/facade/archive/README.md +57 -57
- package/src/neat/telemetry/facade/buffer/README.md +43 -43
- package/src/neat/telemetry/facade/lineage/README.md +12 -12
- package/src/neat/telemetry/facade/objectives/README.md +44 -44
- package/src/neat/telemetry/facade/runtime/README.md +26 -26
- package/src/neat/telemetry/facade/species/README.md +27 -27
- package/src/neat/telemetry/metrics/README.md +696 -696
- package/src/neat/telemetry/recorder/README.md +57 -57
- package/src/neat/telemetry/types/README.md +32 -32
- package/src/neat/topology-intent/README.md +75 -75
- package/src/utils/README.md +193 -193
- package/test/examples/asciiMaze/browser-entry/README.md +92 -92
- package/test/examples/asciiMaze/dashboardManager/README.md +109 -109
- package/test/examples/asciiMaze/dashboardManager/telemetry/README.md +28 -28
- package/test/examples/asciiMaze/evolutionEngine/README.md +1527 -1527
- package/test/examples/asciiMaze/mazeMovement/README.md +105 -105
- package/test/examples/asciiMaze/mazeMovement/finalization/README.md +16 -16
- package/test/examples/asciiMaze/mazeMovement/policy/README.md +57 -57
- package/test/examples/asciiMaze/mazeMovement/runtime/README.md +52 -52
- package/test/examples/asciiMaze/mazeMovement/shaping/README.md +46 -46
- package/test/examples/flappy_bird/browser-entry/README.md +508 -508
- package/test/examples/flappy_bird/browser-entry/host/README.md +101 -101
- package/test/examples/flappy_bird/browser-entry/host/resize/README.md +144 -144
- package/test/examples/flappy_bird/browser-entry/network-view/README.md +194 -194
- package/test/examples/flappy_bird/browser-entry/playback/README.md +278 -278
- package/test/examples/flappy_bird/browser-entry/playback/background/README.md +129 -129
- package/test/examples/flappy_bird/browser-entry/playback/background/ground-grid/README.md +502 -502
- package/test/examples/flappy_bird/browser-entry/playback/frame-render/README.md +139 -139
- package/test/examples/flappy_bird/browser-entry/playback/snapshot/README.md +10 -10
- package/test/examples/flappy_bird/browser-entry/playback/trail/README.md +43 -43
- package/test/examples/flappy_bird/browser-entry/playback/worker-channel/README.md +30 -30
- package/test/examples/flappy_bird/browser-entry/runtime/README.md +59 -59
- package/test/examples/flappy_bird/browser-entry/visualization/README.md +276 -276
- package/test/examples/flappy_bird/browser-entry/worker-channel/README.md +16 -16
- package/test/examples/flappy_bird/constants/README.md +1070 -1070
- package/test/examples/flappy_bird/environment/README.md +22 -22
- package/test/examples/flappy_bird/evaluation/README.md +32 -32
- package/test/examples/flappy_bird/evaluation/rollout/README.md +141 -141
- package/test/examples/flappy_bird/flappy-evolution-worker/README.md +425 -425
- package/test/examples/flappy_bird/simulation-shared/README.md +170 -170
- package/test/examples/flappy_bird/simulation-shared/observation/README.md +109 -109
- package/test/examples/flappy_bird/trainer/README.md +325 -325
- package/test/examples/flappy_bird/trainer/evaluation/README.md +74 -74
- package/scripts/analyze-trace.ts +0 -590
- package/scripts/copy-examples.mjs +0 -114
- package/scripts/export-onnx.mjs +0 -86
- package/scripts/generate-bench-tables.mjs +0 -182
- package/scripts/generate-docs.ts +0 -2900
- package/scripts/write-dist-docs-pkg.mjs +0 -16
|
@@ -78,14 +78,6 @@ one consistent view of the active network range.
|
|
|
78
78
|
|
|
79
79
|
Pixel side length for dotted negative-connection square markers.
|
|
80
80
|
|
|
81
|
-
### FLAPPY_NETWORK_DOTTED_CONNECTION_SQUARE_SIDE_PX
|
|
82
|
-
|
|
83
|
-
Pixel side length for dotted negative-connection square markers.
|
|
84
|
-
|
|
85
|
-
### FLAPPY_NETWORK_ENABLED_CONNECTION_ALPHA
|
|
86
|
-
|
|
87
|
-
Stroke alpha used for enabled connection lines.
|
|
88
|
-
|
|
89
81
|
### FLAPPY_NETWORK_DISABLED_CONNECTION_ALPHA
|
|
90
82
|
|
|
91
83
|
Stroke alpha used for disabled connection lines.
|
|
@@ -94,6 +86,14 @@ Stroke alpha used for disabled connection lines.
|
|
|
94
86
|
|
|
95
87
|
Dash pattern used for disabled positive connection lines.
|
|
96
88
|
|
|
89
|
+
### FLAPPY_NETWORK_DOTTED_CONNECTION_ALIGNMENT_EPSILON
|
|
90
|
+
|
|
91
|
+
Tiny alignment epsilon to stabilize axis-aligned dot centering.
|
|
92
|
+
|
|
93
|
+
### FLAPPY_NETWORK_DOTTED_CONNECTION_SQUARE_SIDE_PX
|
|
94
|
+
|
|
95
|
+
Pixel side length for dotted negative-connection square markers.
|
|
96
|
+
|
|
97
97
|
### FLAPPY_NETWORK_DOTTED_CONNECTION_STEP_COMPACT_RATIO
|
|
98
98
|
|
|
99
99
|
Spacing multiplier used to tighten square-dot trail cadence.
|
|
@@ -102,57 +102,53 @@ Spacing multiplier used to tighten square-dot trail cadence.
|
|
|
102
102
|
|
|
103
103
|
Line-width multiplier used to scale dotted-step spacing.
|
|
104
104
|
|
|
105
|
-
###
|
|
105
|
+
### FLAPPY_NETWORK_ENABLED_CONNECTION_ALPHA
|
|
106
106
|
|
|
107
|
-
|
|
107
|
+
Stroke alpha used for enabled connection lines.
|
|
108
108
|
|
|
109
|
-
###
|
|
109
|
+
### FLAPPY_NETWORK_HEADER_LINE_HEIGHT_PX
|
|
110
110
|
|
|
111
|
-
|
|
111
|
+
Vertical spacing between multiline header rows.
|
|
112
112
|
|
|
113
|
-
###
|
|
113
|
+
### FLAPPY_NETWORK_HEADER_PADDING_PX
|
|
114
114
|
|
|
115
|
-
|
|
115
|
+
Left and top padding used by the network header block.
|
|
116
116
|
|
|
117
117
|
### FLAPPY_NETWORK_HIDDEN_NODE_STROKE_WIDTH_PX
|
|
118
118
|
|
|
119
119
|
Stroke width used for hidden and input nodes.
|
|
120
120
|
|
|
121
|
-
###
|
|
122
|
-
|
|
123
|
-
Glow blur radius used for output-node emphasis.
|
|
124
|
-
|
|
125
|
-
### FLAPPY_NETWORK_MIN_RENDER_NODE_HEIGHT_PX
|
|
121
|
+
### FLAPPY_NETWORK_HIDDEN_NODE_VERTICAL_PADDING_PX
|
|
126
122
|
|
|
127
|
-
|
|
123
|
+
Extra vertical padding reserved for hidden-node labels inside rectangles.
|
|
128
124
|
|
|
129
|
-
###
|
|
125
|
+
### FLAPPY_NETWORK_LEGEND_ARCHITECTURE_GAP_PX
|
|
130
126
|
|
|
131
|
-
|
|
127
|
+
Gap between architecture text and the legend container.
|
|
132
128
|
|
|
133
|
-
###
|
|
129
|
+
### FLAPPY_NETWORK_LEGEND_BIAS_LABEL_X_PX
|
|
134
130
|
|
|
135
|
-
|
|
131
|
+
Label x-position for bias legend row text.
|
|
136
132
|
|
|
137
|
-
###
|
|
133
|
+
### FLAPPY_NETWORK_LEGEND_BIAS_SWATCH_SIZE_PX
|
|
138
134
|
|
|
139
|
-
|
|
135
|
+
Side length for bias legend color swatches.
|
|
140
136
|
|
|
141
|
-
###
|
|
137
|
+
### FLAPPY_NETWORK_LEGEND_BIAS_SWATCH_X_PX
|
|
142
138
|
|
|
143
|
-
|
|
139
|
+
X-position for bias legend swatches.
|
|
144
140
|
|
|
145
|
-
###
|
|
141
|
+
### FLAPPY_NETWORK_LEGEND_BIAS_SWATCH_Y_PX
|
|
146
142
|
|
|
147
|
-
|
|
143
|
+
Y-position offset for bias legend swatches.
|
|
148
144
|
|
|
149
145
|
### FLAPPY_NETWORK_LEGEND_BOX_PADDING_PX
|
|
150
146
|
|
|
151
147
|
Shared inner padding used by legend labels and swatches.
|
|
152
148
|
|
|
153
|
-
###
|
|
149
|
+
### FLAPPY_NETWORK_LEGEND_CONNECTION_LABEL_X_PX
|
|
154
150
|
|
|
155
|
-
|
|
151
|
+
Label x-position for connection legend row text.
|
|
156
152
|
|
|
157
153
|
### FLAPPY_NETWORK_LEGEND_CONNECTION_SAMPLE_END_X_PX
|
|
158
154
|
|
|
@@ -162,50 +158,48 @@ End x-position for connection sample lines in legend rows.
|
|
|
162
158
|
|
|
163
159
|
Vertical offset for connection sample lines inside legend rows.
|
|
164
160
|
|
|
165
|
-
###
|
|
161
|
+
### FLAPPY_NETWORK_LEGEND_HEADER_TOP_PADDING_PX
|
|
166
162
|
|
|
167
|
-
|
|
163
|
+
Top offset for the legend title inside the legend box.
|
|
168
164
|
|
|
169
|
-
###
|
|
165
|
+
### FLAPPY_NETWORK_LEGEND_MIN_ARCHITECTURE_TOP_PX
|
|
170
166
|
|
|
171
|
-
|
|
167
|
+
Minimum top bound for architecture text above the legend box.
|
|
172
168
|
|
|
173
|
-
###
|
|
169
|
+
### FLAPPY_NETWORK_MIN_RENDER_NODE_HEIGHT_PX
|
|
174
170
|
|
|
175
|
-
|
|
171
|
+
Minimum render height for any node rectangle.
|
|
176
172
|
|
|
177
|
-
###
|
|
173
|
+
### FLAPPY_NETWORK_OUTPUT_NODE_HEIGHT_REDUCTION_PX
|
|
178
174
|
|
|
179
|
-
|
|
175
|
+
Height reduction applied to output-node rectangles for tighter framing.
|
|
180
176
|
|
|
181
|
-
###
|
|
177
|
+
### FLAPPY_NETWORK_OUTPUT_NODE_SHADOW_BLUR_PX
|
|
182
178
|
|
|
183
|
-
|
|
179
|
+
Glow blur radius used for output-node emphasis.
|
|
180
|
+
|
|
181
|
+
### FLAPPY_NETWORK_OUTPUT_NODE_STROKE_WIDTH_PX
|
|
182
|
+
|
|
183
|
+
Stroke width used for emphasized output nodes.
|
|
184
184
|
|
|
185
185
|
## browser-entry/visualization/visualization.draw.service.ts
|
|
186
186
|
|
|
187
|
-
###
|
|
187
|
+
### drawBiasNodeScene
|
|
188
188
|
|
|
189
189
|
```ts
|
|
190
|
-
|
|
190
|
+
drawBiasNodeScene(
|
|
191
191
|
context: CanvasRenderingContext2D,
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
connectionScale: DynamicColorScale,
|
|
192
|
+
biasNodeScene: BiasNodeScene,
|
|
193
|
+
nodeWidthPx: number,
|
|
195
194
|
): void
|
|
196
195
|
```
|
|
197
196
|
|
|
198
|
-
Draws
|
|
199
|
-
|
|
200
|
-
Connection styling carries semantic meaning: color encodes magnitude and sign,
|
|
201
|
-
while dash patterns and auxiliary marks help distinguish disabled or negative
|
|
202
|
-
edges in a way that still reads quickly on a dense graph.
|
|
197
|
+
Draws a resolved node rectangle and optional bias label.
|
|
203
198
|
|
|
204
199
|
Parameters:
|
|
205
200
|
- `context` - - Render context.
|
|
206
|
-
- `
|
|
207
|
-
- `
|
|
208
|
-
- `connectionScale` - - Dynamic connection color scale.
|
|
201
|
+
- `biasNodeScene` - - Paint-ready node scene.
|
|
202
|
+
- `nodeWidthPx` - - Shared node width.
|
|
209
203
|
|
|
210
204
|
Returns: Nothing.
|
|
211
205
|
|
|
@@ -233,376 +227,382 @@ Parameters:
|
|
|
233
227
|
|
|
234
228
|
Returns: Nothing.
|
|
235
229
|
|
|
236
|
-
###
|
|
230
|
+
### drawLeftAlignedTextRows
|
|
237
231
|
|
|
238
232
|
```ts
|
|
239
|
-
|
|
233
|
+
drawLeftAlignedTextRows(
|
|
240
234
|
context: CanvasRenderingContext2D,
|
|
241
|
-
|
|
235
|
+
request: { lines: string[]; leftPx: number; topPx: number; lineHeightPx: number; font: string; fillStyle: string; },
|
|
242
236
|
): void
|
|
243
237
|
```
|
|
244
238
|
|
|
245
|
-
Draws
|
|
246
|
-
|
|
247
|
-
The header gives viewers a compact architecture summary before they inspect
|
|
248
|
-
individual nodes and edges.
|
|
239
|
+
Draws multiline text rows aligned to a fixed left edge.
|
|
249
240
|
|
|
250
241
|
Parameters:
|
|
251
242
|
- `context` - - Render context.
|
|
252
|
-
- `
|
|
243
|
+
- `request` - - Multiline text draw request.
|
|
253
244
|
|
|
254
245
|
Returns: Nothing.
|
|
255
246
|
|
|
256
|
-
###
|
|
247
|
+
### drawLegendArchitectureLabel
|
|
257
248
|
|
|
258
249
|
```ts
|
|
259
|
-
|
|
250
|
+
drawLegendArchitectureLabel(
|
|
260
251
|
context: CanvasRenderingContext2D,
|
|
261
|
-
|
|
262
|
-
colorScales: NetworkVisualizationColorScales,
|
|
252
|
+
legendSceneContext: LegendSceneContext,
|
|
263
253
|
): void
|
|
264
254
|
```
|
|
265
255
|
|
|
266
|
-
Draws the
|
|
267
|
-
|
|
268
|
-
This legend is what turns the panel from "colorful art" into an interpretable
|
|
269
|
-
instrument: it tells the viewer what each weight and bias color actually
|
|
270
|
-
means numerically.
|
|
256
|
+
Draws the architecture label block above the legend frame.
|
|
271
257
|
|
|
272
258
|
Parameters:
|
|
273
259
|
- `context` - - Render context.
|
|
274
|
-
- `
|
|
275
|
-
- `colorScales` - - Connection and bias color scales.
|
|
260
|
+
- `legendSceneContext` - - Legend scene context.
|
|
276
261
|
|
|
277
262
|
Returns: Nothing.
|
|
278
263
|
|
|
279
|
-
###
|
|
264
|
+
### drawLegendBiasRow
|
|
280
265
|
|
|
281
266
|
```ts
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
267
|
+
drawLegendBiasRow(
|
|
268
|
+
context: CanvasRenderingContext2D,
|
|
269
|
+
legendSceneContext: LegendSceneContext,
|
|
270
|
+
biasLegendRow: ColorLegendRow,
|
|
271
|
+
biasRowTopPx: number,
|
|
272
|
+
): void
|
|
287
273
|
```
|
|
288
274
|
|
|
289
|
-
|
|
275
|
+
Draws a single bias legend row.
|
|
290
276
|
|
|
291
277
|
Parameters:
|
|
292
|
-
- `
|
|
293
|
-
- `
|
|
294
|
-
- `
|
|
278
|
+
- `context` - - Render context.
|
|
279
|
+
- `legendSceneContext` - - Legend scene context.
|
|
280
|
+
- `biasLegendRow` - - Legend row.
|
|
281
|
+
- `biasRowTopPx` - - Row top coordinate.
|
|
295
282
|
|
|
296
|
-
Returns:
|
|
283
|
+
Returns: Nothing.
|
|
297
284
|
|
|
298
|
-
###
|
|
285
|
+
### drawLegendBiasSection
|
|
299
286
|
|
|
300
287
|
```ts
|
|
301
|
-
|
|
288
|
+
drawLegendBiasSection(
|
|
302
289
|
context: CanvasRenderingContext2D,
|
|
303
|
-
|
|
290
|
+
legendSceneContext: LegendSceneContext,
|
|
304
291
|
): void
|
|
305
292
|
```
|
|
306
293
|
|
|
307
|
-
Draws
|
|
294
|
+
Draws the bias legend section.
|
|
308
295
|
|
|
309
296
|
Parameters:
|
|
310
297
|
- `context` - - Render context.
|
|
311
|
-
- `
|
|
298
|
+
- `legendSceneContext` - - Legend scene context.
|
|
312
299
|
|
|
313
300
|
Returns: Nothing.
|
|
314
301
|
|
|
315
|
-
###
|
|
302
|
+
### drawLegendConnectionRow
|
|
316
303
|
|
|
317
304
|
```ts
|
|
318
|
-
|
|
305
|
+
drawLegendConnectionRow(
|
|
319
306
|
context: CanvasRenderingContext2D,
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
): BiasNodeScene
|
|
307
|
+
legendSceneContext: LegendSceneContext,
|
|
308
|
+
connectionLegendRow: ColorLegendRow,
|
|
309
|
+
connectionRowTopPx: number,
|
|
310
|
+
): void
|
|
325
311
|
```
|
|
326
312
|
|
|
327
|
-
|
|
313
|
+
Draws a single connection legend row.
|
|
328
314
|
|
|
329
315
|
Parameters:
|
|
330
316
|
- `context` - - Render context.
|
|
331
|
-
- `
|
|
332
|
-
- `
|
|
333
|
-
- `
|
|
334
|
-
- `biasScale` - - Bias color scale.
|
|
317
|
+
- `legendSceneContext` - - Legend scene context.
|
|
318
|
+
- `connectionLegendRow` - - Legend row.
|
|
319
|
+
- `connectionRowTopPx` - - Row top coordinate.
|
|
335
320
|
|
|
336
|
-
Returns:
|
|
321
|
+
Returns: Nothing.
|
|
337
322
|
|
|
338
|
-
###
|
|
323
|
+
### drawLegendConnectionSection
|
|
339
324
|
|
|
340
325
|
```ts
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
):
|
|
326
|
+
drawLegendConnectionSection(
|
|
327
|
+
context: CanvasRenderingContext2D,
|
|
328
|
+
legendSceneContext: LegendSceneContext,
|
|
329
|
+
): void
|
|
345
330
|
```
|
|
346
331
|
|
|
347
|
-
|
|
332
|
+
Draws the connection-weight legend section.
|
|
348
333
|
|
|
349
334
|
Parameters:
|
|
350
|
-
- `
|
|
351
|
-
- `
|
|
335
|
+
- `context` - - Render context.
|
|
336
|
+
- `legendSceneContext` - - Legend scene context.
|
|
352
337
|
|
|
353
|
-
Returns:
|
|
338
|
+
Returns: Nothing.
|
|
354
339
|
|
|
355
|
-
###
|
|
340
|
+
### drawLegendFrame
|
|
356
341
|
|
|
357
342
|
```ts
|
|
358
|
-
|
|
343
|
+
drawLegendFrame(
|
|
359
344
|
context: CanvasRenderingContext2D,
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
): BiasNodeLabelMetrics
|
|
345
|
+
legendSceneContext: LegendSceneContext,
|
|
346
|
+
): void
|
|
363
347
|
```
|
|
364
348
|
|
|
365
|
-
|
|
349
|
+
Draws the legend container frame.
|
|
366
350
|
|
|
367
351
|
Parameters:
|
|
368
352
|
- `context` - - Render context.
|
|
369
|
-
- `
|
|
370
|
-
- `nodeDimensions` - - Shared node dimensions.
|
|
353
|
+
- `legendSceneContext` - - Legend scene context.
|
|
371
354
|
|
|
372
|
-
Returns:
|
|
355
|
+
Returns: Nothing.
|
|
373
356
|
|
|
374
|
-
###
|
|
357
|
+
### drawLegendHeader
|
|
375
358
|
|
|
376
359
|
```ts
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
): number
|
|
360
|
+
drawLegendHeader(
|
|
361
|
+
context: CanvasRenderingContext2D,
|
|
362
|
+
legendSceneContext: LegendSceneContext,
|
|
363
|
+
): void
|
|
382
364
|
```
|
|
383
365
|
|
|
384
|
-
|
|
366
|
+
Draws the legend title row.
|
|
385
367
|
|
|
386
368
|
Parameters:
|
|
387
|
-
- `
|
|
388
|
-
- `
|
|
389
|
-
- `isOutputNode` - - Whether the node is an output node.
|
|
369
|
+
- `context` - - Render context.
|
|
370
|
+
- `legendSceneContext` - - Legend scene context.
|
|
390
371
|
|
|
391
|
-
Returns:
|
|
372
|
+
Returns: Nothing.
|
|
392
373
|
|
|
393
|
-
###
|
|
374
|
+
### drawNetworkColorLegend
|
|
394
375
|
|
|
395
376
|
```ts
|
|
396
|
-
|
|
377
|
+
drawNetworkColorLegend(
|
|
397
378
|
context: CanvasRenderingContext2D,
|
|
398
|
-
|
|
399
|
-
|
|
379
|
+
architectureLabel: string,
|
|
380
|
+
colorScales: NetworkVisualizationColorScales,
|
|
400
381
|
): void
|
|
401
382
|
```
|
|
402
383
|
|
|
403
|
-
Draws
|
|
384
|
+
Draws the color legend for connections and node bias values.
|
|
385
|
+
|
|
386
|
+
This legend is what turns the panel from "colorful art" into an interpretable
|
|
387
|
+
instrument: it tells the viewer what each weight and bias color actually
|
|
388
|
+
means numerically.
|
|
404
389
|
|
|
405
390
|
Parameters:
|
|
406
391
|
- `context` - - Render context.
|
|
407
|
-
- `
|
|
408
|
-
- `
|
|
392
|
+
- `architectureLabel` - - Compact architecture description.
|
|
393
|
+
- `colorScales` - - Connection and bias color scales.
|
|
409
394
|
|
|
410
395
|
Returns: Nothing.
|
|
411
396
|
|
|
412
|
-
###
|
|
397
|
+
### drawNetworkVisualizationHeader
|
|
413
398
|
|
|
414
399
|
```ts
|
|
415
|
-
|
|
400
|
+
drawNetworkVisualizationHeader(
|
|
416
401
|
context: CanvasRenderingContext2D,
|
|
417
|
-
|
|
402
|
+
architectureLabel: string,
|
|
403
|
+
): void
|
|
418
404
|
```
|
|
419
405
|
|
|
420
|
-
|
|
406
|
+
Draws network architecture header text.
|
|
407
|
+
|
|
408
|
+
The header gives viewers a compact architecture summary before they inspect
|
|
409
|
+
individual nodes and edges.
|
|
421
410
|
|
|
422
411
|
Parameters:
|
|
423
412
|
- `context` - - Render context.
|
|
413
|
+
- `architectureLabel` - - Header label.
|
|
424
414
|
|
|
425
|
-
Returns:
|
|
415
|
+
Returns: Nothing.
|
|
426
416
|
|
|
427
|
-
###
|
|
417
|
+
### drawSquareDottedConnection
|
|
428
418
|
|
|
429
419
|
```ts
|
|
430
|
-
|
|
420
|
+
drawSquareDottedConnection(
|
|
431
421
|
context: CanvasRenderingContext2D,
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
): LegendSceneContext
|
|
422
|
+
input: { fromXPx: number; fromYPx: number; toXPx: number; toYPx: number; color: string; lineWidthPx: number; },
|
|
423
|
+
): void
|
|
435
424
|
```
|
|
436
425
|
|
|
437
|
-
|
|
426
|
+
Draws a square-dotted connection stroke for negative weights.
|
|
438
427
|
|
|
439
428
|
Parameters:
|
|
440
429
|
- `context` - - Render context.
|
|
441
|
-
- `
|
|
442
|
-
- `colorScales` - - Connection and bias color scales.
|
|
430
|
+
- `input` - - Dotted-stroke endpoints and style.
|
|
443
431
|
|
|
444
|
-
Returns:
|
|
432
|
+
Returns: Nothing.
|
|
445
433
|
|
|
446
|
-
###
|
|
434
|
+
### drawWeightedConnectionScene
|
|
447
435
|
|
|
448
436
|
```ts
|
|
449
|
-
|
|
437
|
+
drawWeightedConnectionScene(
|
|
450
438
|
context: CanvasRenderingContext2D,
|
|
451
|
-
|
|
439
|
+
weightedConnectionScene: WeightedConnectionScene,
|
|
452
440
|
): void
|
|
453
441
|
```
|
|
454
442
|
|
|
455
|
-
Draws
|
|
443
|
+
Draws a previously resolved weighted connection scene.
|
|
456
444
|
|
|
457
445
|
Parameters:
|
|
458
446
|
- `context` - - Render context.
|
|
459
|
-
- `
|
|
447
|
+
- `weightedConnectionScene` - - Render-ready connection scene.
|
|
460
448
|
|
|
461
449
|
Returns: Nothing.
|
|
462
450
|
|
|
463
|
-
###
|
|
451
|
+
### drawWeightedConnectionsLayer
|
|
464
452
|
|
|
465
453
|
```ts
|
|
466
|
-
|
|
454
|
+
drawWeightedConnectionsLayer(
|
|
467
455
|
context: CanvasRenderingContext2D,
|
|
468
|
-
|
|
456
|
+
runtimeConnections: VisualNetworkConnectionLike[],
|
|
457
|
+
positionByNodeIndex: Map<number, PositionedNetworkNodeLike>,
|
|
458
|
+
connectionScale: DynamicColorScale,
|
|
469
459
|
): void
|
|
470
460
|
```
|
|
471
461
|
|
|
472
|
-
Draws
|
|
462
|
+
Draws weighted connection lines.
|
|
463
|
+
|
|
464
|
+
Connection styling carries semantic meaning: color encodes magnitude and sign,
|
|
465
|
+
while dash patterns and auxiliary marks help distinguish disabled or negative
|
|
466
|
+
edges in a way that still reads quickly on a dense graph.
|
|
473
467
|
|
|
474
468
|
Parameters:
|
|
475
469
|
- `context` - - Render context.
|
|
476
|
-
- `
|
|
470
|
+
- `runtimeConnections` - - Runtime connection list.
|
|
471
|
+
- `positionByNodeIndex` - - Node layout map.
|
|
472
|
+
- `connectionScale` - - Dynamic connection color scale.
|
|
477
473
|
|
|
478
474
|
Returns: Nothing.
|
|
479
475
|
|
|
480
|
-
###
|
|
476
|
+
### resolveBiasNodeHeightPx
|
|
481
477
|
|
|
482
478
|
```ts
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
479
|
+
resolveBiasNodeHeightPx(
|
|
480
|
+
nodeDimensions: NetworkNodeDimensionsLike,
|
|
481
|
+
biasNodeLabelMetrics: BiasNodeLabelMetrics,
|
|
482
|
+
isOutputNode: boolean,
|
|
483
|
+
): number
|
|
487
484
|
```
|
|
488
485
|
|
|
489
|
-
|
|
486
|
+
Resolves node rectangle height from label metrics and node role.
|
|
490
487
|
|
|
491
488
|
Parameters:
|
|
492
|
-
- `
|
|
493
|
-
- `
|
|
489
|
+
- `nodeDimensions` - - Shared node dimensions.
|
|
490
|
+
- `biasNodeLabelMetrics` - - Measured label metrics.
|
|
491
|
+
- `isOutputNode` - - Whether the node is an output node.
|
|
494
492
|
|
|
495
|
-
Returns:
|
|
493
|
+
Returns: Render height for the node rectangle.
|
|
496
494
|
|
|
497
|
-
###
|
|
495
|
+
### resolveBiasNodeLabelMetrics
|
|
498
496
|
|
|
499
497
|
```ts
|
|
500
|
-
|
|
498
|
+
resolveBiasNodeLabelMetrics(
|
|
501
499
|
context: CanvasRenderingContext2D,
|
|
502
|
-
|
|
503
|
-
|
|
500
|
+
nodeLabel: string,
|
|
501
|
+
nodeDimensions: NetworkNodeDimensionsLike,
|
|
502
|
+
): BiasNodeLabelMetrics
|
|
504
503
|
```
|
|
505
504
|
|
|
506
|
-
|
|
505
|
+
Measures a bias label and resolves its font declaration.
|
|
507
506
|
|
|
508
507
|
Parameters:
|
|
509
508
|
- `context` - - Render context.
|
|
510
|
-
- `
|
|
509
|
+
- `nodeLabel` - - Bias label string.
|
|
510
|
+
- `nodeDimensions` - - Shared node dimensions.
|
|
511
511
|
|
|
512
|
-
Returns:
|
|
512
|
+
Returns: Measured label metrics.
|
|
513
513
|
|
|
514
|
-
###
|
|
514
|
+
### resolveBiasNodePaintStyle
|
|
515
515
|
|
|
516
516
|
```ts
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
connectionRowTopPx: number,
|
|
522
|
-
): void
|
|
517
|
+
resolveBiasNodePaintStyle(
|
|
518
|
+
positionedNode: PositionedNetworkNodeLike,
|
|
519
|
+
biasScale: DynamicColorScale,
|
|
520
|
+
): BiasNodePaintStyle
|
|
523
521
|
```
|
|
524
522
|
|
|
525
|
-
|
|
523
|
+
Resolves node fill, stroke, and glow styling.
|
|
526
524
|
|
|
527
525
|
Parameters:
|
|
528
|
-
- `
|
|
529
|
-
- `
|
|
530
|
-
- `connectionLegendRow` - - Legend row.
|
|
531
|
-
- `connectionRowTopPx` - - Row top coordinate.
|
|
526
|
+
- `positionedNode` - - Positioned node payload.
|
|
527
|
+
- `biasScale` - - Bias color scale.
|
|
532
528
|
|
|
533
|
-
Returns:
|
|
529
|
+
Returns: Node paint style.
|
|
534
530
|
|
|
535
|
-
###
|
|
531
|
+
### resolveBiasNodeScene
|
|
536
532
|
|
|
537
533
|
```ts
|
|
538
|
-
|
|
534
|
+
resolveBiasNodeScene(
|
|
539
535
|
context: CanvasRenderingContext2D,
|
|
540
|
-
|
|
541
|
-
|
|
536
|
+
positionedNode: PositionedNetworkNodeLike,
|
|
537
|
+
nodeDimensions: NetworkNodeDimensionsLike,
|
|
538
|
+
halfNodeWidthPx: number,
|
|
539
|
+
biasScale: DynamicColorScale,
|
|
540
|
+
): BiasNodeScene
|
|
542
541
|
```
|
|
543
542
|
|
|
544
|
-
|
|
543
|
+
Resolves all paint attributes needed to render a single node.
|
|
545
544
|
|
|
546
545
|
Parameters:
|
|
547
546
|
- `context` - - Render context.
|
|
548
|
-
- `
|
|
547
|
+
- `positionedNode` - - Positioned node payload.
|
|
548
|
+
- `nodeDimensions` - - Shared node dimensions.
|
|
549
|
+
- `halfNodeWidthPx` - - Cached half node width.
|
|
550
|
+
- `biasScale` - - Bias color scale.
|
|
549
551
|
|
|
550
|
-
Returns:
|
|
552
|
+
Returns: Paint-ready node scene.
|
|
551
553
|
|
|
552
|
-
###
|
|
554
|
+
### resolveLegendSceneContext
|
|
553
555
|
|
|
554
556
|
```ts
|
|
555
|
-
|
|
557
|
+
resolveLegendSceneContext(
|
|
556
558
|
context: CanvasRenderingContext2D,
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
): void
|
|
559
|
+
architectureLabel: string,
|
|
560
|
+
colorScales: NetworkVisualizationColorScales,
|
|
561
|
+
): LegendSceneContext
|
|
561
562
|
```
|
|
562
563
|
|
|
563
|
-
|
|
564
|
+
Resolves the legend rows, layout, and architecture label bounds.
|
|
564
565
|
|
|
565
566
|
Parameters:
|
|
566
567
|
- `context` - - Render context.
|
|
567
|
-
- `
|
|
568
|
-
- `
|
|
569
|
-
- `biasRowTopPx` - - Row top coordinate.
|
|
568
|
+
- `architectureLabel` - - Multiline architecture label.
|
|
569
|
+
- `colorScales` - - Connection and bias color scales.
|
|
570
570
|
|
|
571
|
-
Returns:
|
|
571
|
+
Returns: Legend scene context.
|
|
572
572
|
|
|
573
|
-
###
|
|
573
|
+
### resolveWeightedConnectionScene
|
|
574
574
|
|
|
575
575
|
```ts
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
576
|
+
resolveWeightedConnectionScene(
|
|
577
|
+
runtimeConnection: VisualNetworkConnectionLike,
|
|
578
|
+
positionByNodeIndex: Map<number, PositionedNetworkNodeLike>,
|
|
579
|
+
connectionScale: DynamicColorScale,
|
|
580
|
+
): WeightedConnectionScene | undefined
|
|
580
581
|
```
|
|
581
582
|
|
|
582
|
-
|
|
583
|
+
Resolves a renderable connection scene from runtime data and node positions.
|
|
583
584
|
|
|
584
585
|
Parameters:
|
|
585
|
-
- `
|
|
586
|
-
- `
|
|
586
|
+
- `runtimeConnection` - - Candidate runtime connection.
|
|
587
|
+
- `positionByNodeIndex` - - Node layout map.
|
|
588
|
+
- `connectionScale` - - Connection color scale.
|
|
587
589
|
|
|
588
|
-
Returns:
|
|
590
|
+
Returns: Renderable connection scene, when both endpoint nodes exist.
|
|
589
591
|
|
|
590
|
-
###
|
|
592
|
+
### shouldHideNetworkColorLegend
|
|
591
593
|
|
|
592
594
|
```ts
|
|
593
|
-
|
|
595
|
+
shouldHideNetworkColorLegend(
|
|
594
596
|
context: CanvasRenderingContext2D,
|
|
595
|
-
|
|
596
|
-
): void
|
|
597
|
+
): boolean
|
|
597
598
|
```
|
|
598
599
|
|
|
599
|
-
|
|
600
|
+
Determines whether the responsive viewport intentionally hides the overlay legend.
|
|
600
601
|
|
|
601
602
|
Parameters:
|
|
602
603
|
- `context` - - Render context.
|
|
603
|
-
- `input` - - Dotted-stroke endpoints and style.
|
|
604
604
|
|
|
605
|
-
Returns:
|
|
605
|
+
Returns: True when the legend should be omitted.
|
|
606
606
|
|
|
607
607
|
## browser-entry/visualization/visualization.legend.utils.ts
|
|
608
608
|
|
|
@@ -632,49 +632,49 @@ Parameters:
|
|
|
632
632
|
|
|
633
633
|
Returns: Legend rows.
|
|
634
634
|
|
|
635
|
-
###
|
|
635
|
+
### resolveDefaultNetworkLegendLayout
|
|
636
636
|
|
|
637
637
|
```ts
|
|
638
|
-
|
|
638
|
+
resolveDefaultNetworkLegendLayout(
|
|
639
639
|
context: CanvasRenderingContext2D,
|
|
640
|
-
|
|
641
|
-
biasLegendRows: ColorLegendRow[],
|
|
640
|
+
network: default | undefined,
|
|
642
641
|
): NetworkLegendLayout
|
|
643
642
|
```
|
|
644
643
|
|
|
645
|
-
Resolves
|
|
644
|
+
Resolves default legend layout from internal tier definitions.
|
|
646
645
|
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
646
|
+
This convenience helper is used when the caller wants a layout driven by the
|
|
647
|
+
currently active network and does not need to assemble the intermediate rows
|
|
648
|
+
manually.
|
|
650
649
|
|
|
651
650
|
Parameters:
|
|
652
651
|
- `context` - - Render context.
|
|
653
|
-
- `
|
|
654
|
-
- `biasLegendRows` - - Bias legend rows.
|
|
652
|
+
- `network` - - Active network instance.
|
|
655
653
|
|
|
656
|
-
Returns:
|
|
654
|
+
Returns: Legend layout.
|
|
657
655
|
|
|
658
|
-
###
|
|
656
|
+
### resolveNetworkLegendLayout
|
|
659
657
|
|
|
660
658
|
```ts
|
|
661
|
-
|
|
659
|
+
resolveNetworkLegendLayout(
|
|
662
660
|
context: CanvasRenderingContext2D,
|
|
663
|
-
|
|
661
|
+
connectionLegendRows: ColorLegendRow[],
|
|
662
|
+
biasLegendRows: ColorLegendRow[],
|
|
664
663
|
): NetworkLegendLayout
|
|
665
664
|
```
|
|
666
665
|
|
|
667
|
-
Resolves
|
|
666
|
+
Resolves network legend layout from canvas constraints.
|
|
668
667
|
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
668
|
+
The legend layout adapts between regular and compact modes so the network
|
|
669
|
+
panel can stay informative on smaller viewports without swallowing the whole
|
|
670
|
+
canvas.
|
|
672
671
|
|
|
673
672
|
Parameters:
|
|
674
673
|
- `context` - - Render context.
|
|
675
|
-
- `
|
|
674
|
+
- `connectionLegendRows` - - Connection legend rows.
|
|
675
|
+
- `biasLegendRows` - - Bias legend rows.
|
|
676
676
|
|
|
677
|
-
Returns:
|
|
677
|
+
Returns: Computed legend layout.
|
|
678
678
|
|
|
679
679
|
## browser-entry/visualization/visualization.colors.utils.ts
|
|
680
680
|
|
|
@@ -704,27 +704,23 @@ Parameters:
|
|
|
704
704
|
|
|
705
705
|
Returns: Ordered tier list.
|
|
706
706
|
|
|
707
|
-
###
|
|
707
|
+
### resolveBiasRangeColor
|
|
708
708
|
|
|
709
709
|
```ts
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
tiers: ColorTier[],
|
|
713
|
-
aboveTierColor: string,
|
|
710
|
+
resolveBiasRangeColor(
|
|
711
|
+
nodeBias: number,
|
|
714
712
|
): string
|
|
715
713
|
```
|
|
716
714
|
|
|
717
|
-
Resolves
|
|
715
|
+
Resolves bias color for a raw node bias.
|
|
718
716
|
|
|
719
|
-
|
|
720
|
-
|
|
717
|
+
Bias colors follow the same diverging logic as connection colors so the legend
|
|
718
|
+
remains conceptually consistent across channels.
|
|
721
719
|
|
|
722
720
|
Parameters:
|
|
723
|
-
- `
|
|
724
|
-
- `tiers` - - Ordered tier list.
|
|
725
|
-
- `aboveTierColor` - - Fallback color for values above the last tier.
|
|
721
|
+
- `nodeBias` - - Node bias.
|
|
726
722
|
|
|
727
|
-
Returns:
|
|
723
|
+
Returns: Tier color.
|
|
728
724
|
|
|
729
725
|
### resolveConnectionRangeColor
|
|
730
726
|
|
|
@@ -744,24 +740,6 @@ Parameters:
|
|
|
744
740
|
|
|
745
741
|
Returns: Tier color.
|
|
746
742
|
|
|
747
|
-
### resolveBiasRangeColor
|
|
748
|
-
|
|
749
|
-
```ts
|
|
750
|
-
resolveBiasRangeColor(
|
|
751
|
-
nodeBias: number,
|
|
752
|
-
): string
|
|
753
|
-
```
|
|
754
|
-
|
|
755
|
-
Resolves bias color for a raw node bias.
|
|
756
|
-
|
|
757
|
-
Bias colors follow the same diverging logic as connection colors so the legend
|
|
758
|
-
remains conceptually consistent across channels.
|
|
759
|
-
|
|
760
|
-
Parameters:
|
|
761
|
-
- `nodeBias` - - Node bias.
|
|
762
|
-
|
|
763
|
-
Returns: Tier color.
|
|
764
|
-
|
|
765
743
|
### resolveNetworkVisualizationColorScales
|
|
766
744
|
|
|
767
745
|
```ts
|
|
@@ -781,6 +759,28 @@ Parameters:
|
|
|
781
759
|
|
|
782
760
|
Returns: Dynamic scales used by graph drawing and legend rows.
|
|
783
761
|
|
|
762
|
+
### resolveTierColor
|
|
763
|
+
|
|
764
|
+
```ts
|
|
765
|
+
resolveTierColor(
|
|
766
|
+
value: number,
|
|
767
|
+
tiers: ColorTier[],
|
|
768
|
+
aboveTierColor: string,
|
|
769
|
+
): string
|
|
770
|
+
```
|
|
771
|
+
|
|
772
|
+
Resolves a color from ordered tier definitions.
|
|
773
|
+
|
|
774
|
+
This is the final classification step that maps one numeric weight or bias to
|
|
775
|
+
the swatch color the renderer should paint.
|
|
776
|
+
|
|
777
|
+
Parameters:
|
|
778
|
+
- `value` - - Numeric value to classify.
|
|
779
|
+
- `tiers` - - Ordered tier list.
|
|
780
|
+
- `aboveTierColor` - - Fallback color for values above the last tier.
|
|
781
|
+
|
|
782
|
+
Returns: Resolved color string.
|
|
783
|
+
|
|
784
784
|
## browser-entry/visualization/visualization.topology.utils.ts
|
|
785
785
|
|
|
786
786
|
Shared topology formatting helpers used by network-view and visualization.
|