@luma.gl/graph 10.0.0-alpha.9 → 10.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +4 -4
- package/THIRD-PARTY-NOTICES.md +19 -0
- package/dist/arrow/arrow-colors.cjs +99 -18
- package/dist/arrow/arrow-colors.d.ts +27 -10
- package/dist/arrow/arrow-colors.d.ts.map +1 -1
- package/dist/arrow/arrow-colors.js +107 -24
- package/dist/arrow/arrow-colors.js.map +1 -1
- package/dist/arrow/arrow-utils/arrow-paths.cjs +4 -3
- package/dist/arrow/arrow-utils/arrow-paths.d.ts.map +1 -1
- package/dist/arrow/arrow-utils/arrow-paths.js +5 -4
- package/dist/arrow/arrow-utils/arrow-paths.js.map +1 -1
- package/dist/arrow/cpu/arrow-coordinate-projection.cjs +30 -0
- package/dist/arrow/cpu/arrow-coordinate-projection.d.ts +5 -0
- package/dist/arrow/cpu/arrow-coordinate-projection.d.ts.map +1 -0
- package/dist/arrow/cpu/arrow-coordinate-projection.js +9 -0
- package/dist/arrow/cpu/arrow-coordinate-projection.js.map +1 -0
- package/dist/arrow/cpu/arrow-cpu-pipelines.cjs +31 -0
- package/dist/arrow/cpu/arrow-cpu-pipelines.d.ts +2 -0
- package/dist/arrow/cpu/arrow-cpu-pipelines.d.ts.map +1 -0
- package/dist/arrow/cpu/arrow-cpu-pipelines.js +5 -0
- package/dist/arrow/cpu/arrow-cpu-pipelines.js.map +1 -0
- package/dist/arrow/cpu/arrow-cpu-vector-adapters.cjs +99 -0
- package/dist/arrow/cpu/arrow-cpu-vector-adapters.d.ts +9 -0
- package/dist/arrow/cpu/arrow-cpu-vector-adapters.d.ts.map +1 -0
- package/dist/arrow/cpu/arrow-cpu-vector-adapters.js +100 -0
- package/dist/arrow/cpu/arrow-cpu-vector-adapters.js.map +1 -0
- package/dist/arrow/geoarrow/arrow-geoarrow-adapter.cjs +9 -371
- package/dist/arrow/geoarrow/arrow-geoarrow-adapter.d.ts +8 -28
- package/dist/arrow/geoarrow/arrow-geoarrow-adapter.d.ts.map +1 -1
- package/dist/arrow/geoarrow/arrow-geoarrow-adapter.js +4 -381
- package/dist/arrow/geoarrow/arrow-geoarrow-adapter.js.map +1 -1
- package/dist/arrow/geoarrow/arrow-geoarrow-conversion.cjs +11 -11
- package/dist/arrow/geoarrow/arrow-geoarrow-conversion.d.ts +2 -0
- package/dist/arrow/geoarrow/arrow-geoarrow-conversion.d.ts.map +1 -1
- package/dist/arrow/geoarrow/arrow-geoarrow-conversion.js +4 -4
- package/dist/arrow/geoarrow/arrow-geoarrow-conversion.js.map +1 -1
- package/dist/arrow/geoarrow/arrow-polygon-tessellation.cjs +2 -2
- package/dist/arrow/geoarrow/arrow-polygon-tessellation.js +1 -1
- package/dist/arrow/geoarrow/arrow-polygon-tessellation.js.map +1 -1
- package/dist/arrow/gpu/arrow-column-gpu-vector.cjs +27 -8
- package/dist/arrow/gpu/arrow-column-gpu-vector.d.ts +11 -1
- package/dist/arrow/gpu/arrow-column-gpu-vector.d.ts.map +1 -1
- package/dist/arrow/gpu/arrow-column-gpu-vector.js +33 -8
- package/dist/arrow/gpu/arrow-column-gpu-vector.js.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-table-conversion.cjs +68 -3
- package/dist/arrow/gpu/arrow-gpu-table-conversion.d.ts +9 -2
- package/dist/arrow/gpu/arrow-gpu-table-conversion.d.ts.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-table-conversion.js +76 -3
- package/dist/arrow/gpu/arrow-gpu-table-conversion.js.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-vector-adapters.cjs +8 -6
- package/dist/arrow/gpu/arrow-gpu-vector-adapters.d.ts +1 -0
- package/dist/arrow/gpu/arrow-gpu-vector-adapters.d.ts.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-vector-adapters.js +17 -7
- package/dist/arrow/gpu/arrow-gpu-vector-adapters.js.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-vector-conversion.cjs +35 -5
- package/dist/arrow/gpu/arrow-gpu-vector-conversion.d.ts +6 -1
- package/dist/arrow/gpu/arrow-gpu-vector-conversion.d.ts.map +1 -1
- package/dist/arrow/gpu/arrow-gpu-vector-conversion.js +40 -5
- package/dist/arrow/gpu/arrow-gpu-vector-conversion.js.map +1 -1
- package/dist/arrow/index.cjs +19 -2
- package/dist/arrow/index.cjs.map +3 -3
- package/dist/arrow/index.d.ts +5 -2
- package/dist/arrow/index.d.ts.map +1 -1
- package/dist/arrow/index.js +4 -1
- package/dist/arrow/index.js.map +1 -1
- package/dist/arrow/internal.cjs.map +2 -2
- package/dist/dist.dev.js +3820 -1646
- package/dist/dist.min.js +450 -136
- package/dist/experimental/index.cjs.map +1 -1
- package/dist/experimental/simulation/index.cjs.map +1 -1
- package/dist/experimental-models.cjs +21 -0
- package/dist/experimental-models.d.ts +2 -0
- package/dist/experimental-models.d.ts.map +1 -0
- package/dist/experimental-models.js +5 -0
- package/dist/experimental-models.js.map +1 -0
- package/dist/experimental-simulation.cjs +21 -0
- package/dist/experimental-simulation.d.ts +2 -0
- package/dist/experimental-simulation.d.ts.map +1 -0
- package/dist/experimental-simulation.js +5 -0
- package/dist/experimental-simulation.js.map +1 -0
- package/dist/geospatial/gpu-point-spatial-query.cjs +2 -15
- package/dist/geospatial/gpu-point-spatial-query.d.ts.map +1 -1
- package/dist/geospatial/gpu-point-spatial-query.js +2 -15
- package/dist/geospatial/gpu-point-spatial-query.js.map +1 -1
- package/dist/geospatial/index.cjs.map +2 -2
- package/dist/gpu-a5/index.cjs.map +1 -1
- package/dist/gpu-core/compiled-gpu-graph.cjs +47 -0
- package/dist/gpu-core/compiled-gpu-graph.d.ts +5 -0
- package/dist/gpu-core/compiled-gpu-graph.d.ts.map +1 -1
- package/dist/gpu-core/compiled-gpu-graph.js +54 -1
- package/dist/gpu-core/compiled-gpu-graph.js.map +1 -1
- package/dist/gpu-core/gpu-command-graph-compiler.cjs +11 -2
- package/dist/gpu-core/gpu-command-graph-compiler.d.ts +2 -1
- package/dist/gpu-core/gpu-command-graph-compiler.d.ts.map +1 -1
- package/dist/gpu-core/gpu-command-graph-compiler.js +13 -2
- package/dist/gpu-core/gpu-command-graph-compiler.js.map +1 -1
- package/dist/gpu-core/gpu-command-graph-types.d.ts +16 -1
- package/dist/gpu-core/gpu-command-graph-types.d.ts.map +1 -1
- package/dist/gpu-core/gpu-command-graph-types.js.map +1 -1
- package/dist/gpu-core/gpu-command-graph.cjs +34 -11
- package/dist/gpu-core/gpu-command-graph.d.ts +17 -8
- package/dist/gpu-core/gpu-command-graph.d.ts.map +1 -1
- package/dist/gpu-core/gpu-command-graph.js +39 -11
- package/dist/gpu-core/gpu-command-graph.js.map +1 -1
- package/dist/gpu-core/gpu-cpu-execution.cjs +279 -0
- package/dist/gpu-core/gpu-cpu-execution.d.ts +22 -0
- package/dist/gpu-core/gpu-cpu-execution.d.ts.map +1 -0
- package/dist/gpu-core/gpu-cpu-execution.js +294 -0
- package/dist/gpu-core/gpu-cpu-execution.js.map +1 -0
- package/dist/gpu-core/gpu-cpu-operation.cjs +54 -0
- package/dist/gpu-core/gpu-cpu-operation.d.ts +40 -0
- package/dist/gpu-core/gpu-cpu-operation.d.ts.map +1 -0
- package/dist/gpu-core/gpu-cpu-operation.js +35 -0
- package/dist/gpu-core/gpu-cpu-operation.js.map +1 -0
- package/dist/gpu-core/gpu-dispatch-utils.cjs +7 -3
- package/dist/gpu-core/gpu-dispatch-utils.d.ts +2 -0
- package/dist/gpu-core/gpu-dispatch-utils.d.ts.map +1 -1
- package/dist/gpu-core/gpu-dispatch-utils.js +4 -1
- package/dist/gpu-core/gpu-dispatch-utils.js.map +1 -1
- package/dist/gpu-core/gpu-expression-operation.cjs +2 -2
- package/dist/gpu-core/gpu-expression-operation.d.ts +1 -1
- package/dist/gpu-core/gpu-expression-operation.d.ts.map +1 -1
- package/dist/gpu-core/gpu-expression-operation.js +1 -1
- package/dist/gpu-core/gpu-expression-operation.js.map +1 -1
- package/dist/gpu-core/gpu-expression-plan.cjs +5 -1
- package/dist/gpu-core/gpu-expression-plan.d.ts +3 -2
- package/dist/gpu-core/gpu-expression-plan.d.ts.map +1 -1
- package/dist/gpu-core/gpu-expression-plan.js +7 -1
- package/dist/gpu-core/gpu-expression-plan.js.map +1 -1
- package/dist/gpu-core/gpu-graph-compiler.cjs +48 -0
- package/dist/gpu-core/gpu-graph-compiler.d.ts +1 -0
- package/dist/gpu-core/gpu-graph-compiler.d.ts.map +1 -1
- package/dist/gpu-core/gpu-graph-compiler.js +50 -0
- package/dist/gpu-core/gpu-graph-compiler.js.map +1 -1
- package/dist/gpu-core/gpu-graph.d.ts +2 -2
- package/dist/gpu-core/gpu-graph.d.ts.map +1 -1
- package/dist/gpu-core/gpu-graph.js.map +1 -1
- package/dist/gpu-core/gpu-grid-aggregation.cjs +2 -5
- package/dist/gpu-core/gpu-grid-aggregation.d.ts.map +1 -1
- package/dist/gpu-core/gpu-grid-aggregation.js +2 -5
- package/dist/gpu-core/gpu-grid-aggregation.js.map +1 -1
- package/dist/gpu-core/gpu-grid-binning.cjs +2 -5
- package/dist/gpu-core/gpu-grid-binning.d.ts.map +1 -1
- package/dist/gpu-core/gpu-grid-binning.js +2 -5
- package/dist/gpu-core/gpu-grid-binning.js.map +1 -1
- package/dist/gpu-core/gpu-grid-coordinate.cjs +41 -0
- package/dist/gpu-core/gpu-grid-coordinate.d.ts +7 -0
- package/dist/gpu-core/gpu-grid-coordinate.d.ts.map +1 -0
- package/dist/gpu-core/gpu-grid-coordinate.js +24 -0
- package/dist/gpu-core/gpu-grid-coordinate.js.map +1 -0
- package/dist/gpu-core/gpu-grid-index-internals.cjs +2 -15
- package/dist/gpu-core/gpu-grid-index-internals.d.ts.map +1 -1
- package/dist/gpu-core/gpu-grid-index-internals.js +2 -15
- package/dist/gpu-core/gpu-grid-index-internals.js.map +1 -1
- package/dist/gpu-core/gpu-grid-index-query.cjs +2 -16
- package/dist/gpu-core/gpu-grid-index-query.d.ts.map +1 -1
- package/dist/gpu-core/gpu-grid-index-query.js +2 -16
- package/dist/gpu-core/gpu-grid-index-query.js.map +1 -1
- package/dist/gpu-core/gpu-group-aggregation.cjs +7 -15
- package/dist/gpu-core/gpu-group-aggregation.d.ts.map +1 -1
- package/dist/gpu-core/gpu-group-aggregation.js +7 -18
- package/dist/gpu-core/gpu-group-aggregation.js.map +1 -1
- package/dist/gpu-core/gpu-operation.d.ts +4 -4
- package/dist/gpu-core/gpu-operation.d.ts.map +1 -1
- package/dist/gpu-core/gpu-operation.js.map +1 -1
- package/dist/gpu-core/gpu-reduction.cjs +6 -14
- package/dist/gpu-core/gpu-reduction.d.ts.map +1 -1
- package/dist/gpu-core/gpu-reduction.js +6 -15
- package/dist/gpu-core/gpu-reduction.js.map +1 -1
- package/dist/gpu-core/gpu-render-operation.cjs +39 -0
- package/dist/gpu-core/gpu-render-operation.d.ts +21 -0
- package/dist/gpu-core/gpu-render-operation.d.ts.map +1 -0
- package/dist/gpu-core/gpu-render-operation.js +22 -0
- package/dist/gpu-core/gpu-render-operation.js.map +1 -0
- package/dist/gpu-core/gpu-scan.cjs +46 -32
- package/dist/gpu-core/gpu-scan.d.ts.map +1 -1
- package/dist/gpu-core/gpu-scan.js +56 -44
- package/dist/gpu-core/gpu-scan.js.map +1 -1
- package/dist/gpu-core/gpu-segmented-reduction.cjs +12 -9
- package/dist/gpu-core/gpu-segmented-reduction.d.ts +1 -1
- package/dist/gpu-core/gpu-segmented-reduction.d.ts.map +1 -1
- package/dist/gpu-core/gpu-segmented-reduction.js +12 -9
- package/dist/gpu-core/gpu-segmented-reduction.js.map +1 -1
- package/dist/gpu-core/gpu-segmented-scan.cjs +73 -16
- package/dist/gpu-core/gpu-segmented-scan.d.ts.map +1 -1
- package/dist/gpu-core/gpu-segmented-scan.js +73 -16
- package/dist/gpu-core/gpu-segmented-scan.js.map +1 -1
- package/dist/gpu-core/gpu-semantic-aggregation-operation.cjs +112 -0
- package/dist/gpu-core/gpu-semantic-aggregation-operation.d.ts +71 -0
- package/dist/gpu-core/gpu-semantic-aggregation-operation.d.ts.map +1 -0
- package/dist/gpu-core/gpu-semantic-aggregation-operation.js +92 -0
- package/dist/gpu-core/gpu-semantic-aggregation-operation.js.map +1 -0
- package/dist/gpu-core/gpu-shader-pass-kernel.cjs +267 -0
- package/dist/gpu-core/gpu-shader-pass-kernel.d.ts +29 -0
- package/dist/gpu-core/gpu-shader-pass-kernel.d.ts.map +1 -0
- package/dist/gpu-core/gpu-shader-pass-kernel.js +260 -0
- package/dist/gpu-core/gpu-shader-pass-kernel.js.map +1 -0
- package/dist/gpu-core/gpu-shader-pass-operation.cjs +85 -0
- package/dist/gpu-core/gpu-shader-pass-operation.d.ts +32 -0
- package/dist/gpu-core/gpu-shader-pass-operation.d.ts.map +1 -0
- package/dist/gpu-core/gpu-shader-pass-operation.js +74 -0
- package/dist/gpu-core/gpu-shader-pass-operation.js.map +1 -0
- package/dist/gpu-core/gpu-texture-plan.d.ts +3 -2
- package/dist/gpu-core/gpu-texture-plan.d.ts.map +1 -1
- package/dist/gpu-core/gpu-texture-plan.js.map +1 -1
- package/dist/gpu-core/index.cjs +32 -0
- package/dist/gpu-core/index.cjs.map +3 -3
- package/dist/gpu-core/index.d.ts +21 -1
- package/dist/gpu-core/index.d.ts.map +1 -1
- package/dist/gpu-core/index.js +10 -0
- package/dist/gpu-core/index.js.map +1 -1
- package/dist/gpu-data/color-conversion.cjs +105 -0
- package/dist/gpu-data/color-conversion.d.ts +30 -0
- package/dist/gpu-data/color-conversion.d.ts.map +1 -0
- package/dist/gpu-data/color-conversion.js +109 -0
- package/dist/gpu-data/color-conversion.js.map +1 -0
- package/dist/gpu-data/cpu-data.cjs +60 -0
- package/dist/gpu-data/cpu-data.d.ts +28 -0
- package/dist/gpu-data/cpu-data.d.ts.map +1 -0
- package/dist/gpu-data/cpu-data.js +41 -0
- package/dist/gpu-data/cpu-data.js.map +1 -0
- package/dist/gpu-data/cpu-gpu-vector-transfer.cjs +98 -0
- package/dist/gpu-data/cpu-gpu-vector-transfer.d.ts +9 -0
- package/dist/gpu-data/cpu-gpu-vector-transfer.d.ts.map +1 -0
- package/dist/gpu-data/cpu-gpu-vector-transfer.js +85 -0
- package/dist/gpu-data/cpu-gpu-vector-transfer.js.map +1 -0
- package/dist/gpu-data/cpu-vector.cjs +42 -0
- package/dist/gpu-data/cpu-vector.d.ts +17 -0
- package/dist/gpu-data/cpu-vector.d.ts.map +1 -0
- package/dist/gpu-data/cpu-vector.js +21 -0
- package/dist/gpu-data/cpu-vector.js.map +1 -0
- package/dist/gpu-data/gpu-data-buffer-props.cjs +41 -0
- package/dist/gpu-data/gpu-data-buffer-props.d.ts +5 -0
- package/dist/gpu-data/gpu-data-buffer-props.d.ts.map +1 -0
- package/dist/gpu-data/gpu-data-buffer-props.js +19 -0
- package/dist/gpu-data/gpu-data-buffer-props.js.map +1 -0
- package/dist/gpu-data/gpu-vector-wgsl-layout.cjs +50 -0
- package/dist/gpu-data/gpu-vector-wgsl-layout.d.ts +41 -0
- package/dist/gpu-data/gpu-vector-wgsl-layout.d.ts.map +1 -0
- package/dist/gpu-data/gpu-vector-wgsl-layout.js +45 -0
- package/dist/gpu-data/gpu-vector-wgsl-layout.js.map +1 -0
- package/dist/gpu-data/index.cjs +21 -2
- package/dist/gpu-data/index.cjs.map +3 -3
- package/dist/gpu-data/index.d.ts +6 -0
- package/dist/gpu-data/index.d.ts.map +1 -1
- package/dist/gpu-data/index.js +5 -0
- package/dist/gpu-data/index.js.map +1 -1
- package/dist/gpu-dataframe/gpu-data-frame-query.cjs +8 -19
- package/dist/gpu-dataframe/gpu-data-frame-query.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-data-frame-query.js +14 -26
- package/dist/gpu-dataframe/gpu-data-frame-query.js.map +1 -1
- package/dist/gpu-dataframe/gpu-expression-shader.cjs +87 -5
- package/dist/gpu-dataframe/gpu-expression-shader.d.ts +2 -1
- package/dist/gpu-dataframe/gpu-expression-shader.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-expression-shader.js +101 -5
- package/dist/gpu-dataframe/gpu-expression-shader.js.map +1 -1
- package/dist/gpu-dataframe/gpu-expression.cjs +177 -2
- package/dist/gpu-dataframe/gpu-expression.d.ts +60 -2
- package/dist/gpu-dataframe/gpu-expression.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-expression.js +187 -0
- package/dist/gpu-dataframe/gpu-expression.js.map +1 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-compiler.cjs +0 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-compiler.js +0 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-query.cjs +2 -2
- package/dist/gpu-dataframe/gpu-global-aggregation-query.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-global-aggregation-query.js +5 -3
- package/dist/gpu-dataframe/gpu-global-aggregation-query.js.map +1 -1
- package/dist/gpu-dataframe/gpu-global-sort-compiler.cjs +23 -11
- package/dist/gpu-dataframe/gpu-global-sort-compiler.d.ts +1 -1
- package/dist/gpu-dataframe/gpu-global-sort-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-global-sort-compiler.js +24 -12
- package/dist/gpu-dataframe/gpu-global-sort-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-group-aggregation-compiler.cjs +0 -1
- package/dist/gpu-dataframe/gpu-group-aggregation-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-group-aggregation-compiler.js +0 -1
- package/dist/gpu-dataframe/gpu-group-aggregation-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-group-by-query.cjs +2 -2
- package/dist/gpu-dataframe/gpu-group-by-query.js +5 -3
- package/dist/gpu-dataframe/gpu-group-by-query.js.map +1 -1
- package/dist/gpu-dataframe/gpu-histogram-compiler.cjs +0 -1
- package/dist/gpu-dataframe/gpu-histogram-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-histogram-compiler.js +0 -1
- package/dist/gpu-dataframe/gpu-histogram-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-join-compiler.cjs +0 -2
- package/dist/gpu-dataframe/gpu-join-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-join-compiler.js +0 -2
- package/dist/gpu-dataframe/gpu-join-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-query-compiler.cjs +3 -1
- package/dist/gpu-dataframe/gpu-query-compiler.d.ts +0 -1
- package/dist/gpu-dataframe/gpu-query-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-query-compiler.js +3 -1
- package/dist/gpu-dataframe/gpu-query-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-sort-compiler.cjs +0 -1
- package/dist/gpu-dataframe/gpu-sort-compiler.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-sort-compiler.js +0 -1
- package/dist/gpu-dataframe/gpu-sort-compiler.js.map +1 -1
- package/dist/gpu-dataframe/gpu-sort-query.cjs +13 -5
- package/dist/gpu-dataframe/gpu-sort-query.d.ts +4 -1
- package/dist/gpu-dataframe/gpu-sort-query.d.ts.map +1 -1
- package/dist/gpu-dataframe/gpu-sort-query.js +14 -5
- package/dist/gpu-dataframe/gpu-sort-query.js.map +1 -1
- package/dist/gpu-dataframe/index.cjs +20 -2
- package/dist/gpu-dataframe/index.cjs.map +3 -3
- package/dist/gpu-dataframe/index.d.ts +6 -2
- package/dist/gpu-dataframe/index.d.ts.map +1 -1
- package/dist/gpu-dataframe/index.js +3 -1
- package/dist/gpu-dataframe/index.js.map +1 -1
- package/dist/gpu-dataframe/portable-expression.cjs +167 -0
- package/dist/gpu-dataframe/portable-expression.d.ts +21 -0
- package/dist/gpu-dataframe/portable-expression.d.ts.map +1 -0
- package/dist/gpu-dataframe/portable-expression.js +162 -0
- package/dist/gpu-dataframe/portable-expression.js.map +1 -0
- package/dist/gpu-dggs/benchmarks.cjs.map +1 -1
- package/dist/gpu-dggs/index.cjs.map +1 -1
- package/dist/gpu-dggs-benchmarks.cjs +21 -0
- package/dist/gpu-dggs-benchmarks.d.ts +2 -0
- package/dist/gpu-dggs-benchmarks.d.ts.map +1 -0
- package/dist/gpu-dggs-benchmarks.js +5 -0
- package/dist/gpu-dggs-benchmarks.js.map +1 -0
- package/dist/gpu-geometry/index.cjs.map +1 -1
- package/dist/gpu-graph/index.cjs +8 -0
- package/dist/gpu-graph/index.cjs.map +3 -3
- package/dist/gpu-graph/index.d.ts +4 -0
- package/dist/gpu-graph/index.d.ts.map +1 -1
- package/dist/gpu-graph/index.js +2 -0
- package/dist/gpu-graph/index.js.map +1 -1
- package/dist/gpu-graph-algorithms/benchmarks.cjs.map +2 -2
- package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.cjs +2 -15
- package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.d.ts.map +1 -1
- package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.js +2 -15
- package/dist/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.js.map +1 -1
- package/dist/gpu-graph-algorithms/index.cjs.map +2 -2
- package/dist/gpu-graph-algorithms-benchmarks.cjs +21 -0
- package/dist/gpu-graph-algorithms-benchmarks.d.ts +2 -0
- package/dist/gpu-graph-algorithms-benchmarks.d.ts.map +1 -0
- package/dist/gpu-graph-algorithms-benchmarks.js +5 -0
- package/dist/gpu-graph-algorithms-benchmarks.js.map +1 -0
- package/dist/gpu-h3/index.cjs.map +1 -1
- package/dist/gpu-physics/gpu-physics-ensemble-terrain.cjs +116 -0
- package/dist/gpu-physics/gpu-physics-ensemble-terrain.d.ts +42 -0
- package/dist/gpu-physics/gpu-physics-ensemble-terrain.d.ts.map +1 -0
- package/dist/gpu-physics/gpu-physics-ensemble-terrain.js +90 -0
- package/dist/gpu-physics/gpu-physics-ensemble-terrain.js.map +1 -0
- package/dist/gpu-physics/gpu-physics-ensemble.cjs +97 -5
- package/dist/gpu-physics/gpu-physics-ensemble.d.ts +31 -2
- package/dist/gpu-physics/gpu-physics-ensemble.d.ts.map +1 -1
- package/dist/gpu-physics/gpu-physics-ensemble.js +99 -3
- package/dist/gpu-physics/gpu-physics-ensemble.js.map +1 -1
- package/dist/gpu-physics/gpu-rigid-body-world.cjs +568 -77
- package/dist/gpu-physics/gpu-rigid-body-world.d.ts +86 -0
- package/dist/gpu-physics/gpu-rigid-body-world.d.ts.map +1 -1
- package/dist/gpu-physics/gpu-rigid-body-world.js +617 -76
- package/dist/gpu-physics/gpu-rigid-body-world.js.map +1 -1
- package/dist/gpu-physics/index.cjs +23 -2
- package/dist/gpu-physics/index.cjs.map +3 -3
- package/dist/gpu-physics/index.d.ts +9 -2
- package/dist/gpu-physics/index.d.ts.map +1 -1
- package/dist/gpu-physics/index.js +6 -1
- package/dist/gpu-physics/index.js.map +1 -1
- package/dist/gpu-physics/rigid-body-bounds-shaders.cjs +21 -8
- package/dist/gpu-physics/rigid-body-bounds-shaders.d.ts +2 -1
- package/dist/gpu-physics/rigid-body-bounds-shaders.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-bounds-shaders.js +15 -1
- package/dist/gpu-physics/rigid-body-bounds-shaders.js.map +1 -1
- package/dist/gpu-physics/rigid-body-convex-shaders.cjs +3 -2
- package/dist/gpu-physics/rigid-body-convex-shaders.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-convex-shaders.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-convex-shaders.js +3 -2
- package/dist/gpu-physics/rigid-body-convex-shaders.js.map +1 -1
- package/dist/gpu-physics/rigid-body-ensemble-reset.cjs +36 -7
- package/dist/gpu-physics/rigid-body-ensemble-reset.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-ensemble-reset.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-ensemble-reset.js +42 -7
- package/dist/gpu-physics/rigid-body-ensemble-reset.js.map +1 -1
- package/dist/gpu-physics/rigid-body-ensemble-transaction.cjs +23 -1
- package/dist/gpu-physics/rigid-body-ensemble-transaction.d.ts +4 -1
- package/dist/gpu-physics/rigid-body-ensemble-transaction.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-ensemble-transaction.js +25 -1
- package/dist/gpu-physics/rigid-body-ensemble-transaction.js.map +1 -1
- package/dist/gpu-physics/rigid-body-geometry.cjs +41 -4
- package/dist/gpu-physics/rigid-body-geometry.d.ts +10 -1
- package/dist/gpu-physics/rigid-body-geometry.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-geometry.js +44 -3
- package/dist/gpu-physics/rigid-body-geometry.js.map +1 -1
- package/dist/gpu-physics/rigid-body-height-field-shader.cjs +80 -0
- package/dist/gpu-physics/rigid-body-height-field-shader.d.ts +3 -0
- package/dist/gpu-physics/rigid-body-height-field-shader.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-height-field-shader.js +56 -0
- package/dist/gpu-physics/rigid-body-height-field-shader.js.map +1 -0
- package/dist/gpu-physics/rigid-body-height-field.cjs +166 -0
- package/dist/gpu-physics/rigid-body-height-field.d.ts +55 -0
- package/dist/gpu-physics/rigid-body-height-field.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-height-field.js +184 -0
- package/dist/gpu-physics/rigid-body-height-field.js.map +1 -0
- package/dist/gpu-physics/rigid-body-mesh-query-shaders.cjs +4 -2
- package/dist/gpu-physics/rigid-body-mesh-query-shaders.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-mesh-query-shaders.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-mesh-query-shaders.js +4 -2
- package/dist/gpu-physics/rigid-body-mesh-query-shaders.js.map +1 -1
- package/dist/gpu-physics/rigid-body-mesh.cjs +72 -17
- package/dist/gpu-physics/rigid-body-mesh.d.ts +3 -0
- package/dist/gpu-physics/rigid-body-mesh.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-mesh.js +76 -20
- package/dist/gpu-physics/rigid-body-mesh.js.map +1 -1
- package/dist/gpu-physics/rigid-body-parallel-shaders.cjs +24 -9
- package/dist/gpu-physics/rigid-body-parallel-shaders.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-parallel-shaders.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-parallel-shaders.js +28 -9
- package/dist/gpu-physics/rigid-body-parallel-shaders.js.map +1 -1
- package/dist/gpu-physics/rigid-body-properties.cjs +4 -4
- package/dist/gpu-physics/rigid-body-properties.d.ts +6 -0
- package/dist/gpu-physics/rigid-body-properties.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-properties.js +1 -1
- package/dist/gpu-physics/rigid-body-properties.js.map +1 -1
- package/dist/gpu-physics/rigid-body-publication.cjs +2 -2
- package/dist/gpu-physics/rigid-body-publication.js +1 -1
- package/dist/gpu-physics/rigid-body-publication.js.map +1 -1
- package/dist/gpu-physics/rigid-body-query-geometry.cjs +22 -4
- package/dist/gpu-physics/rigid-body-query-geometry.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-query-geometry.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-query-geometry.js +22 -4
- package/dist/gpu-physics/rigid-body-query-geometry.js.map +1 -1
- package/dist/gpu-physics/rigid-body-shaders.cjs +12 -6
- package/dist/gpu-physics/rigid-body-shaders.d.ts +1 -1
- package/dist/gpu-physics/rigid-body-shaders.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-shaders.js +15 -7
- package/dist/gpu-physics/rigid-body-shaders.js.map +1 -1
- package/dist/gpu-physics/rigid-body-shape-properties.cjs +2 -0
- package/dist/gpu-physics/rigid-body-shape-properties.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-shape-properties.js +2 -0
- package/dist/gpu-physics/rigid-body-shape-properties.js.map +1 -1
- package/dist/gpu-physics/rigid-body-terrain-atlas.cjs +287 -0
- package/dist/gpu-physics/rigid-body-terrain-atlas.d.ts +87 -0
- package/dist/gpu-physics/rigid-body-terrain-atlas.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-atlas.js +275 -0
- package/dist/gpu-physics/rigid-body-terrain-atlas.js.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-lod.cjs +240 -0
- package/dist/gpu-physics/rigid-body-terrain-lod.d.ts +76 -0
- package/dist/gpu-physics/rigid-body-terrain-lod.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-lod.js +247 -0
- package/dist/gpu-physics/rigid-body-terrain-lod.js.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-stitch.cjs +215 -0
- package/dist/gpu-physics/rigid-body-terrain-stitch.d.ts +25 -0
- package/dist/gpu-physics/rigid-body-terrain-stitch.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-stitch.js +218 -0
- package/dist/gpu-physics/rigid-body-terrain-stitch.js.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-stream.cjs +263 -0
- package/dist/gpu-physics/rigid-body-terrain-stream.d.ts +97 -0
- package/dist/gpu-physics/rigid-body-terrain-stream.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-terrain-stream.js +250 -0
- package/dist/gpu-physics/rigid-body-terrain-stream.js.map +1 -0
- package/dist/gpu-physics/rigid-body-triggers.cjs +1 -0
- package/dist/gpu-physics/rigid-body-triggers.d.ts.map +1 -1
- package/dist/gpu-physics/rigid-body-triggers.js +1 -0
- package/dist/gpu-physics/rigid-body-triggers.js.map +1 -1
- package/dist/gpu-physics/rigid-body-vehicle.cjs +145 -0
- package/dist/gpu-physics/rigid-body-vehicle.d.ts +47 -0
- package/dist/gpu-physics/rigid-body-vehicle.d.ts.map +1 -0
- package/dist/gpu-physics/rigid-body-vehicle.js +119 -0
- package/dist/gpu-physics/rigid-body-vehicle.js.map +1 -0
- package/dist/gpu-pointcloud/index.cjs.map +1 -1
- package/dist/gpu-project/benchmarks.cjs.map +2 -2
- package/dist/gpu-project/coordinate-projection-graph.cjs +59 -0
- package/dist/gpu-project/coordinate-projection-graph.d.ts +23 -0
- package/dist/gpu-project/coordinate-projection-graph.d.ts.map +1 -0
- package/dist/gpu-project/coordinate-projection-graph.js +40 -0
- package/dist/gpu-project/coordinate-projection-graph.js.map +1 -0
- package/dist/gpu-project/cpu-geoarrow.cjs +112 -0
- package/dist/gpu-project/cpu-geoarrow.d.ts +10 -0
- package/dist/gpu-project/cpu-geoarrow.d.ts.map +1 -0
- package/dist/gpu-project/cpu-geoarrow.js +103 -0
- package/dist/gpu-project/cpu-geoarrow.js.map +1 -0
- package/dist/gpu-project/cpu-geometry-pipelines.cjs +134 -0
- package/dist/gpu-project/cpu-geometry-pipelines.d.ts +19 -0
- package/dist/gpu-project/cpu-geometry-pipelines.d.ts.map +1 -0
- package/dist/gpu-project/cpu-geometry-pipelines.js +114 -0
- package/dist/gpu-project/cpu-geometry-pipelines.js.map +1 -0
- package/dist/gpu-project/cpu-projection-operation.cjs +54 -0
- package/dist/gpu-project/cpu-projection-operation.d.ts +14 -0
- package/dist/gpu-project/cpu-projection-operation.d.ts.map +1 -0
- package/dist/gpu-project/cpu-projection-operation.js +37 -0
- package/dist/gpu-project/cpu-projection-operation.js.map +1 -0
- package/dist/gpu-project/crs.cjs.map +3 -3
- package/dist/gpu-project/crs.d.ts +1 -1
- package/dist/gpu-project/geoarrow.cjs +36 -0
- package/dist/gpu-project/geoarrow.cjs.map +6 -0
- package/dist/gpu-project/geoarrow.d.ts +3 -0
- package/dist/gpu-project/geoarrow.d.ts.map +1 -0
- package/dist/gpu-project/geoarrow.js +7 -0
- package/dist/gpu-project/geoarrow.js.map +1 -0
- package/dist/gpu-project/graph.cjs +27 -0
- package/dist/gpu-project/graph.cjs.map +6 -0
- package/dist/gpu-project/graph.d.ts +2 -0
- package/dist/gpu-project/graph.d.ts.map +1 -0
- package/dist/gpu-project/graph.js +6 -0
- package/dist/gpu-project/graph.js.map +1 -0
- package/dist/gpu-project/index.cjs +3 -0
- package/dist/gpu-project/index.cjs.map +3 -3
- package/dist/gpu-project/index.d.ts +1 -0
- package/dist/gpu-project/index.d.ts.map +1 -1
- package/dist/gpu-project/index.js +1 -0
- package/dist/gpu-project/index.js.map +1 -1
- package/dist/gpu-project/projection-crs-benchmark.cjs +2 -2
- package/dist/gpu-project/projection-crs-benchmark.d.ts +1 -1
- package/dist/gpu-project/projection-crs-benchmark.js +1 -1
- package/dist/gpu-project/projection-crs-input.cjs +7 -7
- package/dist/gpu-project/projection-crs-input.d.ts +1 -1
- package/dist/gpu-project/projection-crs-input.js +4 -4
- package/dist/gpu-project/projection-engine.d.ts +2 -2
- package/dist/gpu-project-benchmarks.cjs +21 -0
- package/dist/gpu-project-benchmarks.d.ts +2 -0
- package/dist/gpu-project-benchmarks.d.ts.map +1 -0
- package/dist/gpu-project-benchmarks.js +5 -0
- package/dist/gpu-project-benchmarks.js.map +1 -0
- package/dist/gpu-project-crs.cjs +21 -0
- package/dist/gpu-project-crs.d.ts +2 -0
- package/dist/gpu-project-crs.d.ts.map +1 -0
- package/dist/gpu-project-crs.js +5 -0
- package/dist/gpu-project-crs.js.map +1 -0
- package/dist/gpu-project-geoarrow.cjs +21 -0
- package/dist/gpu-project-geoarrow.d.ts +2 -0
- package/dist/gpu-project-geoarrow.d.ts.map +1 -0
- package/dist/gpu-project-geoarrow.js +5 -0
- package/dist/gpu-project-geoarrow.js.map +1 -0
- package/dist/gpu-project-graph.cjs +21 -0
- package/dist/gpu-project-graph.d.ts +2 -0
- package/dist/gpu-project-graph.d.ts.map +1 -0
- package/dist/gpu-project-graph.js +5 -0
- package/dist/gpu-project-graph.js.map +1 -0
- package/dist/gpu-simple-graph/compiled-gpu-expression-graph.cjs +75 -5
- package/dist/gpu-simple-graph/compiled-gpu-expression-graph.d.ts +5 -1
- package/dist/gpu-simple-graph/compiled-gpu-expression-graph.d.ts.map +1 -1
- package/dist/gpu-simple-graph/compiled-gpu-expression-graph.js +86 -6
- package/dist/gpu-simple-graph/compiled-gpu-expression-graph.js.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-lowering.cjs +9 -0
- package/dist/gpu-simple-graph/gpu-simple-graph-lowering.d.ts +2 -0
- package/dist/gpu-simple-graph/gpu-simple-graph-lowering.d.ts.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-lowering.js +10 -0
- package/dist/gpu-simple-graph/gpu-simple-graph-lowering.js.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-transfer.d.ts +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-transfer.d.ts.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-value.d.ts +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph-value.d.ts.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph.cjs +126 -10
- package/dist/gpu-simple-graph/gpu-simple-graph.d.ts +36 -11
- package/dist/gpu-simple-graph/gpu-simple-graph.d.ts.map +1 -1
- package/dist/gpu-simple-graph/gpu-simple-graph.js +137 -12
- package/dist/gpu-simple-graph/gpu-simple-graph.js.map +1 -1
- package/dist/gpu-simple-graph/index.cjs.map +3 -3
- package/dist/gpu-simple-graph/index.d.ts +1 -1
- package/dist/gpu-simple-graph/index.d.ts.map +1 -1
- package/dist/gpu-simple-graph/index.js.map +1 -1
- package/dist/gpu-simple-graph/operation/gpu-data-evaluator.cjs +25 -0
- package/dist/gpu-simple-graph/operation/gpu-data-evaluator.d.ts +7 -1
- package/dist/gpu-simple-graph/operation/gpu-data-evaluator.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operation/gpu-data-evaluator.js +28 -0
- package/dist/gpu-simple-graph/operation/gpu-data-evaluator.js.map +1 -1
- package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.cjs +7 -0
- package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.d.ts +2 -0
- package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.js +7 -0
- package/dist/gpu-simple-graph/operation/gpu-vector-evaluator.js.map +1 -1
- package/dist/gpu-simple-graph/operation/operation.d.ts +1 -1
- package/dist/gpu-simple-graph/operation/operation.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operations/convert-colors.cjs +6 -6
- package/dist/gpu-simple-graph/operations/convert-colors.d.ts +5 -1
- package/dist/gpu-simple-graph/operations/convert-colors.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operations/convert-colors.js +12 -7
- package/dist/gpu-simple-graph/operations/convert-colors.js.map +1 -1
- package/dist/gpu-simple-graph/operations/cpu/convert-colors.cjs +16 -33
- package/dist/gpu-simple-graph/operations/cpu/convert-colors.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operations/cpu/convert-colors.js +22 -35
- package/dist/gpu-simple-graph/operations/cpu/convert-colors.js.map +1 -1
- package/dist/gpu-simple-graph/operations/cpu/index.cjs.map +3 -3
- package/dist/gpu-simple-graph/operations/webgl/index.cjs.map +3 -3
- package/dist/gpu-simple-graph/operations/webgpu/convert-colors.cjs +31 -13
- package/dist/gpu-simple-graph/operations/webgpu/convert-colors.d.ts.map +1 -1
- package/dist/gpu-simple-graph/operations/webgpu/convert-colors.js +42 -13
- package/dist/gpu-simple-graph/operations/webgpu/convert-colors.js.map +1 -1
- package/dist/gpu-simple-graph/operations/webgpu/index.cjs.map +1 -1
- package/dist/gpu-simple-graph-cpu.cjs +21 -0
- package/dist/gpu-simple-graph-cpu.d.ts +2 -0
- package/dist/gpu-simple-graph-cpu.d.ts.map +1 -0
- package/dist/gpu-simple-graph-cpu.js +5 -0
- package/dist/gpu-simple-graph-cpu.js.map +1 -0
- package/dist/gpu-simple-graph-webgl.cjs +21 -0
- package/dist/gpu-simple-graph-webgl.d.ts +2 -0
- package/dist/gpu-simple-graph-webgl.d.ts.map +1 -0
- package/dist/gpu-simple-graph-webgl.js +5 -0
- package/dist/gpu-simple-graph-webgl.js.map +1 -0
- package/dist/gpu-simple-graph-webgpu.cjs +21 -0
- package/dist/gpu-simple-graph-webgpu.d.ts +2 -0
- package/dist/gpu-simple-graph-webgpu.d.ts.map +1 -0
- package/dist/gpu-simple-graph-webgpu.js +5 -0
- package/dist/gpu-simple-graph-webgpu.js.map +1 -0
- package/dist/gpu-sql/gpu-sql.cjs +159 -328
- package/dist/gpu-sql/gpu-sql.d.ts +1 -1
- package/dist/gpu-sql/gpu-sql.d.ts.map +1 -1
- package/dist/gpu-sql/gpu-sql.js +186 -340
- package/dist/gpu-sql/gpu-sql.js.map +1 -1
- package/dist/gpu-sql/index.cjs.map +3 -3
- package/dist/gpu-tables/index.cjs.map +2 -2
- package/dist/gpu-tables/table/gpu-table.cjs +2 -2
- package/dist/gpu-tables/table/gpu-table.d.ts.map +1 -1
- package/dist/gpu-tables/table/gpu-table.js +2 -2
- package/dist/gpu-tables/table/gpu-table.js.map +1 -1
- package/dist/gpu-timeseries/index.cjs.map +1 -1
- package/dist/index.cjs +11 -0
- package/dist/index.cjs.map +3 -3
- package/dist/index.d.ts +7 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/package.json +30 -16
- package/src/arrow/arrow-colors.ts +194 -33
- package/src/arrow/arrow-utils/arrow-paths.ts +5 -3
- package/src/arrow/cpu/arrow-coordinate-projection.ts +18 -0
- package/src/arrow/cpu/arrow-cpu-pipelines.ts +9 -0
- package/src/arrow/cpu/arrow-cpu-vector-adapters.ts +153 -0
- package/src/arrow/geoarrow/arrow-geoarrow-adapter.ts +21 -493
- package/src/arrow/geoarrow/arrow-geoarrow-conversion.ts +7 -5
- package/src/arrow/geoarrow/arrow-polygon-tessellation.ts +1 -1
- package/src/arrow/gpu/arrow-column-gpu-vector.ts +67 -14
- package/src/arrow/gpu/arrow-gpu-table-conversion.ts +96 -4
- package/src/arrow/gpu/arrow-gpu-vector-adapters.ts +20 -7
- package/src/arrow/gpu/arrow-gpu-vector-conversion.ts +49 -6
- package/src/arrow/index.ts +14 -0
- package/src/experimental-models.ts +5 -0
- package/src/experimental-simulation.ts +5 -0
- package/src/geospatial/gpu-point-spatial-query.ts +2 -15
- package/src/gpu-core/compiled-gpu-graph.ts +73 -1
- package/src/gpu-core/gpu-command-graph-compiler.ts +25 -2
- package/src/gpu-core/gpu-command-graph-types.ts +20 -0
- package/src/gpu-core/gpu-command-graph.ts +48 -11
- package/src/gpu-core/gpu-cpu-execution.ts +345 -0
- package/src/gpu-core/gpu-cpu-operation.ts +65 -0
- package/src/gpu-core/gpu-dispatch-utils.ts +13 -1
- package/src/gpu-core/gpu-expression-operation.ts +1 -1
- package/src/gpu-core/gpu-expression-plan.ts +11 -3
- package/src/gpu-core/gpu-graph-compiler.ts +61 -0
- package/src/gpu-core/gpu-graph.ts +3 -3
- package/src/gpu-core/gpu-grid-aggregation.ts +2 -5
- package/src/gpu-core/gpu-grid-binning.ts +2 -5
- package/src/gpu-core/gpu-grid-coordinate.ts +24 -0
- package/src/gpu-core/gpu-grid-index-internals.ts +2 -15
- package/src/gpu-core/gpu-grid-index-query.ts +2 -16
- package/src/gpu-core/gpu-group-aggregation.ts +38 -50
- package/src/gpu-core/gpu-operation.ts +9 -7
- package/src/gpu-core/gpu-reduction.ts +32 -42
- package/src/gpu-core/gpu-render-operation.ts +42 -0
- package/src/gpu-core/gpu-scan.ts +59 -45
- package/src/gpu-core/gpu-segmented-reduction.ts +20 -10
- package/src/gpu-core/gpu-segmented-scan.ts +82 -17
- package/src/gpu-core/gpu-semantic-aggregation-operation.ts +150 -0
- package/src/gpu-core/gpu-shader-pass-kernel.ts +307 -0
- package/src/gpu-core/gpu-shader-pass-operation.ts +103 -0
- package/src/gpu-core/gpu-texture-plan.ts +3 -2
- package/src/gpu-core/index.ts +39 -0
- package/src/gpu-data/color-conversion.ts +158 -0
- package/src/gpu-data/cpu-data.ts +62 -0
- package/src/gpu-data/cpu-gpu-vector-transfer.ts +110 -0
- package/src/gpu-data/cpu-vector.ts +31 -0
- package/src/gpu-data/gpu-data-buffer-props.ts +25 -0
- package/src/gpu-data/gpu-vector-wgsl-layout.ts +79 -0
- package/src/gpu-data/index.ts +15 -0
- package/src/gpu-dataframe/gpu-data-frame-query.ts +24 -31
- package/src/gpu-dataframe/gpu-expression-shader.ts +128 -7
- package/src/gpu-dataframe/gpu-expression.ts +259 -1
- package/src/gpu-dataframe/gpu-global-aggregation-compiler.ts +0 -1
- package/src/gpu-dataframe/gpu-global-aggregation-query.ts +5 -3
- package/src/gpu-dataframe/gpu-global-sort-compiler.ts +26 -12
- package/src/gpu-dataframe/gpu-group-aggregation-compiler.ts +0 -1
- package/src/gpu-dataframe/gpu-group-by-query.ts +5 -3
- package/src/gpu-dataframe/gpu-histogram-compiler.ts +0 -1
- package/src/gpu-dataframe/gpu-join-compiler.ts +0 -2
- package/src/gpu-dataframe/gpu-query-compiler.ts +3 -3
- package/src/gpu-dataframe/gpu-sort-compiler.ts +0 -1
- package/src/gpu-dataframe/gpu-sort-query.ts +31 -5
- package/src/gpu-dataframe/index.ts +26 -2
- package/src/gpu-dataframe/portable-expression.ts +194 -0
- package/src/gpu-dggs-benchmarks.ts +5 -0
- package/src/gpu-graph/index.ts +17 -0
- package/src/gpu-graph-algorithms/gpu-graph-spatial-force-layout-internals.ts +2 -15
- package/src/gpu-graph-algorithms-benchmarks.ts +5 -0
- package/src/gpu-physics/gpu-physics-ensemble-terrain.ts +114 -0
- package/src/gpu-physics/gpu-physics-ensemble.ts +147 -4
- package/src/gpu-physics/gpu-rigid-body-world.ts +797 -102
- package/src/gpu-physics/index.ts +38 -0
- package/src/gpu-physics/rigid-body-bounds-shaders.ts +16 -1
- package/src/gpu-physics/rigid-body-convex-shaders.ts +3 -2
- package/src/gpu-physics/rigid-body-ensemble-reset.ts +48 -8
- package/src/gpu-physics/rigid-body-ensemble-transaction.ts +34 -1
- package/src/gpu-physics/rigid-body-geometry.ts +49 -4
- package/src/gpu-physics/rigid-body-height-field-shader.ts +56 -0
- package/src/gpu-physics/rigid-body-height-field.ts +257 -0
- package/src/gpu-physics/rigid-body-mesh-query-shaders.ts +4 -2
- package/src/gpu-physics/rigid-body-mesh.ts +97 -26
- package/src/gpu-physics/rigid-body-parallel-shaders.ts +32 -9
- package/src/gpu-physics/rigid-body-properties.ts +5 -2
- package/src/gpu-physics/rigid-body-publication.ts +1 -1
- package/src/gpu-physics/rigid-body-query-geometry.ts +22 -4
- package/src/gpu-physics/rigid-body-shaders.ts +19 -7
- package/src/gpu-physics/rigid-body-shape-properties.ts +2 -0
- package/src/gpu-physics/rigid-body-terrain-atlas.ts +378 -0
- package/src/gpu-physics/rigid-body-terrain-lod.ts +332 -0
- package/src/gpu-physics/rigid-body-terrain-stitch.ts +286 -0
- package/src/gpu-physics/rigid-body-terrain-stream.ts +323 -0
- package/src/gpu-physics/rigid-body-triggers.ts +1 -0
- package/src/gpu-physics/rigid-body-vehicle.ts +166 -0
- package/src/gpu-project/README.md +2 -2
- package/src/gpu-project/coordinate-projection-graph.ts +59 -0
- package/src/gpu-project/cpu-geoarrow.ts +135 -0
- package/src/gpu-project/cpu-geometry-pipelines.ts +159 -0
- package/src/gpu-project/cpu-projection-operation.ts +49 -0
- package/src/gpu-project/crs.ts +2 -2
- package/src/gpu-project/geoarrow.ts +11 -0
- package/src/gpu-project/graph.ts +10 -0
- package/src/gpu-project/index.ts +2 -0
- package/src/gpu-project/projection-crs-benchmark.ts +2 -2
- package/src/gpu-project/projection-crs-input.ts +4 -4
- package/src/gpu-project/projection-engine.ts +2 -2
- package/src/gpu-project-benchmarks.ts +5 -0
- package/src/gpu-project-crs.ts +5 -0
- package/src/gpu-project-geoarrow.ts +5 -0
- package/src/gpu-project-graph.ts +5 -0
- package/src/gpu-simple-graph/compiled-gpu-expression-graph.ts +97 -6
- package/src/gpu-simple-graph/gpu-simple-graph-lowering.ts +11 -0
- package/src/gpu-simple-graph/gpu-simple-graph-transfer.ts +1 -1
- package/src/gpu-simple-graph/gpu-simple-graph-value.ts +1 -1
- package/src/gpu-simple-graph/gpu-simple-graph.ts +163 -19
- package/src/gpu-simple-graph/index.ts +1 -0
- package/src/gpu-simple-graph/operation/gpu-data-evaluator.ts +25 -1
- package/src/gpu-simple-graph/operation/gpu-vector-evaluator.ts +7 -0
- package/src/gpu-simple-graph/operation/operation.ts +1 -1
- package/src/gpu-simple-graph/operations/convert-colors.ts +22 -7
- package/src/gpu-simple-graph/operations/cpu/convert-colors.ts +31 -48
- package/src/gpu-simple-graph/operations/swizzle.ts +1 -1
- package/src/gpu-simple-graph/operations/webgpu/convert-colors.ts +47 -13
- package/src/gpu-simple-graph-cpu.ts +5 -0
- package/src/gpu-simple-graph-webgl.ts +5 -0
- package/src/gpu-simple-graph-webgpu.ts +5 -0
- package/src/gpu-sql/gpu-sql.ts +238 -354
- package/src/gpu-tables/table/gpu-table.ts +2 -1
- package/src/index.ts +21 -0
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
// luma.gl
|
|
2
|
+
// SPDX-License-Identifier: MIT
|
|
3
|
+
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
|
+
|
|
5
|
+
import {getLeafLayoutInfo, makeShaderBlockLayout} from '@luma.gl/shaders/types';
|
|
6
|
+
import {getGPUVectorFormatInfo} from './gpu-vector-format';
|
|
7
|
+
|
|
8
|
+
/** Scalar formats with matching 32-bit WGSL component representations. */
|
|
9
|
+
export type GPUVectorWGSLScalarFormat = 'float32' | 'sint32' | 'uint32';
|
|
10
|
+
|
|
11
|
+
/** Packed 32-bit numeric formats with a corresponding WGSL value type. */
|
|
12
|
+
export type GPUVectorWGSLFormat =
|
|
13
|
+
| GPUVectorWGSLScalarFormat
|
|
14
|
+
| `${GPUVectorWGSLScalarFormat}x${2 | 3 | 4}`;
|
|
15
|
+
|
|
16
|
+
/** Packed row metadata and the layout of the corresponding native WGSL storage value. */
|
|
17
|
+
export type GPUVectorWGSLLayout = {
|
|
18
|
+
/** The packed GPUVector format. */
|
|
19
|
+
format: GPUVectorWGSLFormat;
|
|
20
|
+
/** Number of scalar components in a row. */
|
|
21
|
+
components: 1 | 2 | 3 | 4;
|
|
22
|
+
/** GPUVector format of an individual component. */
|
|
23
|
+
componentType: GPUVectorWGSLScalarFormat;
|
|
24
|
+
/** WGSL type of an individual component. */
|
|
25
|
+
scalarType: 'f32' | 'i32' | 'u32';
|
|
26
|
+
/** WGSL scalar or vector type for one row. */
|
|
27
|
+
shaderType: 'f32' | 'i32' | 'u32' | `vec${2 | 3 | 4}<${'f32' | 'i32' | 'u32'}>`;
|
|
28
|
+
/** Number of bytes occupied by the components of one row. */
|
|
29
|
+
byteLength: number;
|
|
30
|
+
/** Distance in bytes between rows in a tightly packed GPUVector. */
|
|
31
|
+
packedByteStride: number;
|
|
32
|
+
/** Required byte alignment of the value in a native WGSL storage buffer. */
|
|
33
|
+
storageAlignment: number;
|
|
34
|
+
/** Distance in bytes between elements in a native WGSL storage array of this value type. */
|
|
35
|
+
nativeArrayByteStride: number;
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Describes packed GPUVector rows and the corresponding native WGSL storage array.
|
|
40
|
+
*
|
|
41
|
+
* @param format - Packed 32-bit scalar or vector format.
|
|
42
|
+
* @returns Layout metadata in bytes. The helper does not allocate or modify storage.
|
|
43
|
+
* @throws If the format has no supported 32-bit WGSL representation.
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* ```ts
|
|
47
|
+
* const layout = getGPUVectorWGSLLayout('float32x3');
|
|
48
|
+
* layout.packedByteStride; // 12
|
|
49
|
+
* layout.nativeArrayByteStride; // 16
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
export function getGPUVectorWGSLLayout(format: GPUVectorWGSLFormat): GPUVectorWGSLLayout {
|
|
53
|
+
const {components, signedDataType, primitiveType, byteLength, elementFormat, normalized} =
|
|
54
|
+
getGPUVectorFormatInfo(format);
|
|
55
|
+
if (
|
|
56
|
+
normalized ||
|
|
57
|
+
elementFormat !== format ||
|
|
58
|
+
(signedDataType !== 'float32' && signedDataType !== 'sint32' && signedDataType !== 'uint32') ||
|
|
59
|
+
primitiveType === 'f16'
|
|
60
|
+
) {
|
|
61
|
+
throw new Error('Expected a packed 32-bit numeric vector format');
|
|
62
|
+
}
|
|
63
|
+
const scalarType = primitiveType;
|
|
64
|
+
const shaderType = components === 1 ? scalarType : (`vec${components}<${scalarType}>` as const);
|
|
65
|
+
const layout = 'wgsl-storage';
|
|
66
|
+
const {alignment} = getLeafLayoutInfo(shaderType, layout);
|
|
67
|
+
const arrayLayout = makeShaderBlockLayout({values: [shaderType, 2]}, {layout});
|
|
68
|
+
return {
|
|
69
|
+
format,
|
|
70
|
+
components,
|
|
71
|
+
componentType: signedDataType,
|
|
72
|
+
scalarType,
|
|
73
|
+
shaderType,
|
|
74
|
+
byteLength,
|
|
75
|
+
packedByteStride: byteLength,
|
|
76
|
+
storageAlignment: alignment * Uint32Array.BYTES_PER_ELEMENT,
|
|
77
|
+
nativeArrayByteStride: arrayLayout.byteLength / 2
|
|
78
|
+
};
|
|
79
|
+
}
|
package/src/gpu-data/index.ts
CHANGED
|
@@ -68,3 +68,18 @@ export {
|
|
|
68
68
|
export {getGPUVectorChunks, type GPUVectorChunk} from './gpu-vector-chunks';
|
|
69
69
|
|
|
70
70
|
export type {GPUVectorLike, GPUVectorInput} from './gpu-vector-like';
|
|
71
|
+
|
|
72
|
+
export {CPUData, type CPUDataProps} from './cpu-data';
|
|
73
|
+
export {CPUVector, type CPUVectorProps} from './cpu-vector';
|
|
74
|
+
|
|
75
|
+
export {makeGPUVectorFromCPUVector, makeCPUVectorFromGPUVector} from './cpu-gpu-vector-transfer';
|
|
76
|
+
|
|
77
|
+
export {
|
|
78
|
+
getGPUVectorWGSLLayout,
|
|
79
|
+
type GPUVectorWGSLFormat,
|
|
80
|
+
type GPUVectorWGSLLayout,
|
|
81
|
+
type GPUVectorWGSLScalarFormat
|
|
82
|
+
} from './gpu-vector-wgsl-layout';
|
|
83
|
+
|
|
84
|
+
export {convertCPUColors, resolveColorOutputFormat} from './color-conversion';
|
|
85
|
+
export type {ColorOutputFormat, ColorConversionOptions} from './color-conversion';
|
|
@@ -6,7 +6,14 @@
|
|
|
6
6
|
import type {GPUTypeMap} from '@luma.gl/graph/gpu-tables';
|
|
7
7
|
import type {GPUCommandGraph} from '@luma.gl/graph/gpu-core';
|
|
8
8
|
import type {GPUDataFrame} from './gpu-data-frame';
|
|
9
|
-
import {
|
|
9
|
+
import {
|
|
10
|
+
getGPUExpressionColumnNames,
|
|
11
|
+
getGPUExpressionResultFormats,
|
|
12
|
+
GPUExpression,
|
|
13
|
+
isBooleanExpressionNode,
|
|
14
|
+
isGPUScalarFunction,
|
|
15
|
+
type GPUExpressionNode
|
|
16
|
+
} from './gpu-expression';
|
|
10
17
|
import {
|
|
11
18
|
GPUDataFrameAggregationQuery,
|
|
12
19
|
type GPUDataFrameGlobalAggregationDefinitions,
|
|
@@ -331,10 +338,9 @@ function assertDataFrameDerivedColumns<T extends GPUTypeMap>(
|
|
|
331
338
|
}
|
|
332
339
|
assertDataFrameDerivedExpression(derivedColumn.expression, logicalColumns);
|
|
333
340
|
|
|
334
|
-
const referencedFormats =
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
)
|
|
341
|
+
const referencedFormats = getGPUExpressionResultFormats(
|
|
342
|
+
derivedColumn.expression.node,
|
|
343
|
+
logicalFormats
|
|
338
344
|
);
|
|
339
345
|
if (referencedFormats.size > 1) {
|
|
340
346
|
throw new Error(`GPUDataFrame derived column "${derivedColumn.name}" mixes scalar formats`);
|
|
@@ -416,15 +422,27 @@ function assertSelectedQueryColumns(
|
|
|
416
422
|
|
|
417
423
|
function isNumericExpressionNode(node: GPUExpressionNode): boolean {
|
|
418
424
|
switch (node.kind) {
|
|
425
|
+
case 'conditional':
|
|
426
|
+
return (
|
|
427
|
+
(isBooleanExpressionNode(node.condition) ||
|
|
428
|
+
((node.condition.kind === 'literal' || node.condition.kind === 'parameter') &&
|
|
429
|
+
node.condition.value === null)) &&
|
|
430
|
+
isNumericExpressionNode(node.whenTrue) &&
|
|
431
|
+
isNumericExpressionNode(node.otherwise)
|
|
432
|
+
);
|
|
433
|
+
case 'cast':
|
|
434
|
+
return !node.format.includes('x') && isNumericExpressionNode(node.operand);
|
|
419
435
|
case 'column':
|
|
420
436
|
return true;
|
|
421
437
|
case 'literal':
|
|
422
438
|
case 'parameter':
|
|
423
439
|
return node.value === null || typeof node.value === 'number';
|
|
424
440
|
case 'unary':
|
|
425
|
-
return node.operator === 'negate';
|
|
441
|
+
return node.operator === 'negate' || isGPUScalarFunction(node.operator);
|
|
426
442
|
case 'binary':
|
|
427
443
|
return (
|
|
444
|
+
node.operator === 'coalesce' ||
|
|
445
|
+
node.operator === 'nullif' ||
|
|
428
446
|
node.operator === 'add' ||
|
|
429
447
|
node.operator === 'subtract' ||
|
|
430
448
|
node.operator === 'multiply' ||
|
|
@@ -434,28 +452,3 @@ function isNumericExpressionNode(node: GPUExpressionNode): boolean {
|
|
|
434
452
|
return false;
|
|
435
453
|
}
|
|
436
454
|
}
|
|
437
|
-
|
|
438
|
-
function isBooleanExpressionNode(node: GPUExpressionNode): boolean {
|
|
439
|
-
switch (node.kind) {
|
|
440
|
-
case 'column':
|
|
441
|
-
return false;
|
|
442
|
-
case 'literal':
|
|
443
|
-
case 'parameter':
|
|
444
|
-
return typeof node.value === 'boolean';
|
|
445
|
-
case 'unary':
|
|
446
|
-
return node.operator === 'not' || node.operator === 'is-valid' || node.operator === 'is-null';
|
|
447
|
-
case 'binary':
|
|
448
|
-
return (
|
|
449
|
-
node.operator === 'equal' ||
|
|
450
|
-
node.operator === 'not-equal' ||
|
|
451
|
-
node.operator === 'greater-than' ||
|
|
452
|
-
node.operator === 'greater-than-or-equal' ||
|
|
453
|
-
node.operator === 'less-than' ||
|
|
454
|
-
node.operator === 'less-than-or-equal' ||
|
|
455
|
-
node.operator === 'and' ||
|
|
456
|
-
node.operator === 'or'
|
|
457
|
-
);
|
|
458
|
-
default:
|
|
459
|
-
return false;
|
|
460
|
-
}
|
|
461
|
-
}
|
|
@@ -5,7 +5,9 @@
|
|
|
5
5
|
|
|
6
6
|
import type {GPUTypeMap} from '@luma.gl/graph/gpu-tables';
|
|
7
7
|
import type {GPUDataFrame} from './gpu-data-frame';
|
|
8
|
+
import {getGPUExpressionCastWGSL} from '../gpu-core/gpu-expression-cast';
|
|
8
9
|
import type {GPUDataFrameDerivedColumn} from './gpu-data-frame-query';
|
|
10
|
+
import {isGPUScalarFunction, type GPUExpressionUnaryOperator} from './gpu-expression';
|
|
9
11
|
import type {
|
|
10
12
|
GPUExpression,
|
|
11
13
|
GPUExpressionBinaryOperator,
|
|
@@ -52,6 +54,7 @@ export type GPUQueryExpressionShaderPlan = {
|
|
|
52
54
|
controls: readonly GPUQueryExpressionControl[];
|
|
53
55
|
outputs: readonly GPUQueryExpressionOutput[];
|
|
54
56
|
statements: readonly string[];
|
|
57
|
+
usesCasts: boolean;
|
|
55
58
|
condition: string;
|
|
56
59
|
};
|
|
57
60
|
|
|
@@ -74,13 +77,8 @@ export function makeGPUQueryExpressionShaderPlan<T extends GPUTypeMap>(
|
|
|
74
77
|
source: GPUDataFrame<T>,
|
|
75
78
|
predicates: readonly GPUExpression<boolean, string>[],
|
|
76
79
|
derivedColumns: readonly GPUDataFrameDerivedColumn[] = [],
|
|
77
|
-
selectedColumns: readonly string[] = []
|
|
78
|
-
allowEmptyPredicates = false
|
|
80
|
+
selectedColumns: readonly string[] = []
|
|
79
81
|
): GPUQueryExpressionShaderPlan {
|
|
80
|
-
if (predicates.length === 0 && derivedColumns.length === 0 && !allowEmptyPredicates) {
|
|
81
|
-
throw new Error('GPUDataFrame filtering requires at least one predicate');
|
|
82
|
-
}
|
|
83
|
-
|
|
84
82
|
const planner = new GPUQueryExpressionShaderPlanner(source, derivedColumns);
|
|
85
83
|
const outputs = selectedColumns.flatMap(name => {
|
|
86
84
|
const derived = derivedColumns.find(column => column.name === name);
|
|
@@ -118,6 +116,7 @@ export function makeGPUQueryExpressionShaderPlan<T extends GPUTypeMap>(
|
|
|
118
116
|
controls: planner.controls,
|
|
119
117
|
outputs,
|
|
120
118
|
statements: planner.statements,
|
|
119
|
+
usesCasts: planner.usesCasts,
|
|
121
120
|
condition: conditions.join(' && ') || 'true'
|
|
122
121
|
};
|
|
123
122
|
}
|
|
@@ -178,6 +177,7 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
178
177
|
readonly columns: GPUQueryExpressionColumn[] = [];
|
|
179
178
|
readonly controls: GPUQueryExpressionControl[] = [];
|
|
180
179
|
readonly statements: string[] = [];
|
|
180
|
+
usesCasts = false;
|
|
181
181
|
|
|
182
182
|
private readonly source: GPUDataFrame<T>;
|
|
183
183
|
private readonly columnsByName = new Map<string, GPUQueryExpressionColumn>();
|
|
@@ -231,6 +231,43 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
231
231
|
return this.emitControl(node.value, undefined, expected);
|
|
232
232
|
case 'parameter':
|
|
233
233
|
return this.emitControl(node.value, node.name, expected);
|
|
234
|
+
case 'cast': {
|
|
235
|
+
const format = node.format;
|
|
236
|
+
if (format !== 'float32' && format !== 'sint32' && format !== 'uint32') {
|
|
237
|
+
throw new Error('GPUDataFrame casts require scalar 32-bit formats');
|
|
238
|
+
}
|
|
239
|
+
const operand = this.emit(node.operand, this.inferFormat(node.operand) ?? 'float32');
|
|
240
|
+
if (operand.format === 'boolean') {
|
|
241
|
+
throw new Error('GPUDataFrame casts require numeric expressions');
|
|
242
|
+
}
|
|
243
|
+
const floatToInteger = operand.format === 'float32' && format !== 'float32';
|
|
244
|
+
const valid = floatToInteger
|
|
245
|
+
? `(${operand.valid} && (bitcast<u32>(${operand.value}) & 0x7fffffffu) < 0x7f800000u)`
|
|
246
|
+
: operand.valid;
|
|
247
|
+
const input = floatToInteger ? `select(0.0, ${operand.value}, ${valid})` : operand.value;
|
|
248
|
+
this.usesCasts ||= floatToInteger;
|
|
249
|
+
return this.addValue(
|
|
250
|
+
format,
|
|
251
|
+
getGPUExpressionCastWGSL(input, operand.format, format, 'truncate'),
|
|
252
|
+
valid,
|
|
253
|
+
operand.nullable || floatToInteger
|
|
254
|
+
);
|
|
255
|
+
}
|
|
256
|
+
case 'conditional': {
|
|
257
|
+
const condition = this.emit(node.condition, 'boolean');
|
|
258
|
+
this.assertBoolean(condition);
|
|
259
|
+
const format =
|
|
260
|
+
this.inferFormat(node) ?? (expected === 'boolean' ? undefined : expected) ?? 'float32';
|
|
261
|
+
const whenTrue = this.emit(node.whenTrue, format);
|
|
262
|
+
const otherwise = this.emit(node.otherwise, format);
|
|
263
|
+
const match = `(${condition.valid} && ${condition.value})`;
|
|
264
|
+
return this.addValue(
|
|
265
|
+
format,
|
|
266
|
+
`select(${otherwise.value}, ${whenTrue.value}, ${match})`,
|
|
267
|
+
`select(${otherwise.valid}, ${whenTrue.valid}, ${match})`,
|
|
268
|
+
whenTrue.nullable || otherwise.nullable
|
|
269
|
+
);
|
|
270
|
+
}
|
|
234
271
|
case 'unary':
|
|
235
272
|
return this.emitUnary(node.operator, node.operand, expected);
|
|
236
273
|
case 'binary':
|
|
@@ -297,7 +334,7 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
297
334
|
}
|
|
298
335
|
|
|
299
336
|
private emitUnary(
|
|
300
|
-
operator:
|
|
337
|
+
operator: GPUExpressionUnaryOperator,
|
|
301
338
|
operandNode: GPUExpressionNode,
|
|
302
339
|
expected?: GPUQueryValueFormat
|
|
303
340
|
): GPUQueryExpressionShaderValue {
|
|
@@ -315,6 +352,52 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
315
352
|
const operand = this.emit(operandNode, this.inferFormat(operandNode));
|
|
316
353
|
return this.addValue('boolean', `!${operand.valid}`, 'true');
|
|
317
354
|
}
|
|
355
|
+
case 'sqrt':
|
|
356
|
+
case 'ln':
|
|
357
|
+
case 'log10':
|
|
358
|
+
case 'asin':
|
|
359
|
+
case 'acos': {
|
|
360
|
+
const operand = this.emit(operandNode, this.inferFormat(operandNode) ?? 'float32');
|
|
361
|
+
if (operand.format !== 'float32') {
|
|
362
|
+
throw new Error('GPUDataFrame domain-sensitive functions require Float32 input');
|
|
363
|
+
}
|
|
364
|
+
const value = operand.value;
|
|
365
|
+
const domain =
|
|
366
|
+
operator === 'sqrt'
|
|
367
|
+
? `${value} >= 0.0`
|
|
368
|
+
: operator === 'ln' || operator === 'log10'
|
|
369
|
+
? `${value} > 0.0`
|
|
370
|
+
: `abs(${value}) <= 1.0`;
|
|
371
|
+
const valid = `(${operand.valid} && (bitcast<u32>(${value}) & 0x7fffffffu) < 0x7f800000u && (${domain}))`;
|
|
372
|
+
const input = `select(1.0, ${value}, ${valid})`;
|
|
373
|
+
const result =
|
|
374
|
+
operator === 'log10'
|
|
375
|
+
? `(log2(${input}) / log2(10.0))`
|
|
376
|
+
: `${operator === 'ln' ? 'log' : operator}(${input})`;
|
|
377
|
+
return this.addValue('float32', result, valid, true);
|
|
378
|
+
}
|
|
379
|
+
case 'abs':
|
|
380
|
+
case 'floor':
|
|
381
|
+
case 'ceiling':
|
|
382
|
+
case 'round':
|
|
383
|
+
case 'trunc': {
|
|
384
|
+
const format = this.inferFormat(operandNode) ?? 'float32';
|
|
385
|
+
if (format === 'boolean' || (operator === 'abs' && format === 'sint32')) {
|
|
386
|
+
throw new Error('GPUDataFrame scalar function requires a supported numeric format');
|
|
387
|
+
}
|
|
388
|
+
const operand = this.emit(operandNode, format);
|
|
389
|
+
if (format !== 'float32') {
|
|
390
|
+
return operand;
|
|
391
|
+
}
|
|
392
|
+
const value = operand.value;
|
|
393
|
+
const functionName = operator === 'ceiling' ? 'ceil' : operator;
|
|
394
|
+
const rounded = `trunc(${value})`;
|
|
395
|
+
const result =
|
|
396
|
+
operator === 'round'
|
|
397
|
+
? `(${rounded} + select(0.0, sign(${value}), abs(${value} - ${rounded}) >= 0.5))`
|
|
398
|
+
: `${functionName}(${value})`;
|
|
399
|
+
return this.addValue(format, result, operand.valid, operand.nullable);
|
|
400
|
+
}
|
|
318
401
|
case 'negate': {
|
|
319
402
|
const format = this.inferFormat(operandNode) ?? expected ?? 'float32';
|
|
320
403
|
if (format === 'boolean' || format === 'uint32') {
|
|
@@ -369,6 +452,22 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
369
452
|
}
|
|
370
453
|
const left = this.emit(leftNode, format);
|
|
371
454
|
const right = this.emit(rightNode, format);
|
|
455
|
+
if (operator === 'coalesce') {
|
|
456
|
+
return this.addValue(
|
|
457
|
+
format,
|
|
458
|
+
`select(${right.value}, ${left.value}, ${left.valid})`,
|
|
459
|
+
`(${left.valid} || ${right.valid})`,
|
|
460
|
+
left.nullable && right.nullable
|
|
461
|
+
);
|
|
462
|
+
}
|
|
463
|
+
if (operator === 'nullif') {
|
|
464
|
+
return this.addValue(
|
|
465
|
+
format,
|
|
466
|
+
left.value,
|
|
467
|
+
`(${left.valid} && !(${right.valid} && ${left.value} == ${right.value}))`,
|
|
468
|
+
true
|
|
469
|
+
);
|
|
470
|
+
}
|
|
372
471
|
const symbol = getGPUQueryBinaryOperator(operator);
|
|
373
472
|
const value = `(${left.value} ${symbol} ${right.value})`;
|
|
374
473
|
const valid = `${left.valid} && ${right.valid}`;
|
|
@@ -389,10 +488,32 @@ class GPUQueryExpressionShaderPlanner<T extends GPUTypeMap> {
|
|
|
389
488
|
case 'literal':
|
|
390
489
|
case 'parameter':
|
|
391
490
|
return typeof node.value === 'boolean' ? 'boolean' : undefined;
|
|
491
|
+
case 'cast':
|
|
492
|
+
if (node.format === 'float32' || node.format === 'sint32' || node.format === 'uint32') {
|
|
493
|
+
return node.format;
|
|
494
|
+
}
|
|
495
|
+
throw new Error('GPUDataFrame casts require scalar 32-bit formats');
|
|
496
|
+
case 'conditional': {
|
|
497
|
+
const whenTrue = this.inferFormat(node.whenTrue);
|
|
498
|
+
const otherwise = this.inferFormat(node.otherwise);
|
|
499
|
+
if (
|
|
500
|
+
whenTrue === 'boolean' ||
|
|
501
|
+
otherwise === 'boolean' ||
|
|
502
|
+
(whenTrue && otherwise && whenTrue !== otherwise)
|
|
503
|
+
) {
|
|
504
|
+
throw new Error('GPUDataFrame CASE branches require matching numeric formats');
|
|
505
|
+
}
|
|
506
|
+
return whenTrue ?? otherwise;
|
|
507
|
+
}
|
|
392
508
|
case 'unary':
|
|
509
|
+
if (isGPUScalarFunction(node.operator)) {
|
|
510
|
+
return this.inferFormat(node.operand) ?? 'float32';
|
|
511
|
+
}
|
|
393
512
|
return node.operator === 'negate' ? this.inferFormat(node.operand) : 'boolean';
|
|
394
513
|
case 'binary':
|
|
395
514
|
if (
|
|
515
|
+
node.operator === 'coalesce' ||
|
|
516
|
+
node.operator === 'nullif' ||
|
|
396
517
|
node.operator === 'add' ||
|
|
397
518
|
node.operator === 'subtract' ||
|
|
398
519
|
node.operator === 'multiply' ||
|
|
@@ -3,14 +3,58 @@
|
|
|
3
3
|
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
4
|
// SPDX-FileComment: Independently implemented for WebGPU; inspired by NVIDIA RAPIDS cuDF.
|
|
5
5
|
|
|
6
|
+
import {
|
|
7
|
+
getGPUVectorWGSLLayout,
|
|
8
|
+
type GPUVectorWGSLFormat as GPUExpressionNumericFormat
|
|
9
|
+
} from '@luma.gl/graph/gpu-data';
|
|
10
|
+
|
|
11
|
+
/** Numeric values, including fixed-width vectors. */
|
|
12
|
+
export type GPUExpressionNumericValue = number | readonly number[] | null;
|
|
13
|
+
|
|
6
14
|
/** Portable scalar values accepted by GPU-resident dataframe expressions. */
|
|
7
15
|
export type GPUExpressionValue = number | boolean | null;
|
|
8
16
|
|
|
9
17
|
/** Closed unary operations that can be lowered safely into generated WGSL. */
|
|
10
|
-
export type GPUExpressionUnaryOperator =
|
|
18
|
+
export type GPUExpressionUnaryOperator =
|
|
19
|
+
| 'not'
|
|
20
|
+
| 'is-valid'
|
|
21
|
+
| 'is-null'
|
|
22
|
+
| 'negate'
|
|
23
|
+
| GPUScalarFunction;
|
|
24
|
+
|
|
25
|
+
const scalarFunctions = [
|
|
26
|
+
'abs',
|
|
27
|
+
'floor',
|
|
28
|
+
'ceiling',
|
|
29
|
+
'round',
|
|
30
|
+
'trunc',
|
|
31
|
+
'sqrt',
|
|
32
|
+
'ln',
|
|
33
|
+
'log10',
|
|
34
|
+
'asin',
|
|
35
|
+
'acos'
|
|
36
|
+
] as const;
|
|
37
|
+
|
|
38
|
+
/** Numeric functions supported by GPU DataFrame expressions. */
|
|
39
|
+
export type GPUScalarFunction = (typeof scalarFunctions)[number];
|
|
40
|
+
|
|
41
|
+
/** Tests a canonical, lowercase scalar function name. @internal */
|
|
42
|
+
export function isGPUScalarFunction(name: unknown): name is GPUScalarFunction {
|
|
43
|
+
return scalarFunctions.some(functionName => functionName === name);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/** Applies a supported numeric function while preserving the operand's format and nulls. */
|
|
47
|
+
export function scalarFunction<Columns extends string>(
|
|
48
|
+
name: GPUScalarFunction,
|
|
49
|
+
expression: GPUExpression<number | null, Columns>
|
|
50
|
+
): GPUExpression<number | null, Columns> {
|
|
51
|
+
return makeUnaryExpression(name, expression);
|
|
52
|
+
}
|
|
11
53
|
|
|
12
54
|
/** Closed binary operations that can be lowered safely into generated WGSL. */
|
|
13
55
|
export type GPUExpressionBinaryOperator =
|
|
56
|
+
| 'coalesce'
|
|
57
|
+
| 'nullif'
|
|
14
58
|
| 'add'
|
|
15
59
|
| 'subtract'
|
|
16
60
|
| 'multiply'
|
|
@@ -26,6 +70,18 @@ export type GPUExpressionBinaryOperator =
|
|
|
26
70
|
|
|
27
71
|
/** Immutable, renderer-independent dataframe expression syntax. */
|
|
28
72
|
export type GPUExpressionNode =
|
|
73
|
+
| Readonly<{
|
|
74
|
+
kind: 'vector';
|
|
75
|
+
format: GPUExpressionNumericFormat;
|
|
76
|
+
components: readonly GPUExpressionNode[];
|
|
77
|
+
}>
|
|
78
|
+
| Readonly<{kind: 'cast'; format: GPUExpressionNumericFormat; operand: GPUExpressionNode}>
|
|
79
|
+
| Readonly<{
|
|
80
|
+
kind: 'conditional';
|
|
81
|
+
condition: GPUExpressionNode;
|
|
82
|
+
whenTrue: GPUExpressionNode;
|
|
83
|
+
otherwise: GPUExpressionNode;
|
|
84
|
+
}>
|
|
29
85
|
| Readonly<{kind: 'column'; name: string}>
|
|
30
86
|
| Readonly<{kind: 'literal'; value: GPUExpressionValue}>
|
|
31
87
|
| Readonly<{kind: 'parameter'; name: string; value: GPUExpressionValue}>
|
|
@@ -233,9 +289,61 @@ export function getGPUExpressionColumnNames(expression: GPUExpression<any, strin
|
|
|
233
289
|
return Array.from(columnNames);
|
|
234
290
|
}
|
|
235
291
|
|
|
292
|
+
/** Resolves format constraints from result-producing nodes. @internal */
|
|
293
|
+
export function getGPUExpressionResultFormats(
|
|
294
|
+
node: GPUExpressionNode,
|
|
295
|
+
columns: ReadonlyMap<string, string | undefined>,
|
|
296
|
+
formats = new Set<string | undefined>()
|
|
297
|
+
): Set<string | undefined> {
|
|
298
|
+
switch (node.kind) {
|
|
299
|
+
case 'column':
|
|
300
|
+
formats.add(columns.get(node.name));
|
|
301
|
+
break;
|
|
302
|
+
case 'cast':
|
|
303
|
+
formats.add(node.format);
|
|
304
|
+
break;
|
|
305
|
+
case 'unary':
|
|
306
|
+
if (isGPUScalarFunction(node.operator)) {
|
|
307
|
+
const input = getGPUExpressionResultFormats(node.operand, columns);
|
|
308
|
+
for (const format of input.size ? input : ['float32']) formats.add(format);
|
|
309
|
+
} else {
|
|
310
|
+
getGPUExpressionResultFormats(node.operand, columns, formats);
|
|
311
|
+
}
|
|
312
|
+
break;
|
|
313
|
+
case 'binary':
|
|
314
|
+
getGPUExpressionResultFormats(node.left, columns, formats);
|
|
315
|
+
getGPUExpressionResultFormats(node.right, columns, formats);
|
|
316
|
+
break;
|
|
317
|
+
case 'conditional':
|
|
318
|
+
getGPUExpressionResultFormats(node.whenTrue, columns, formats);
|
|
319
|
+
getGPUExpressionResultFormats(node.otherwise, columns, formats);
|
|
320
|
+
break;
|
|
321
|
+
}
|
|
322
|
+
return formats;
|
|
323
|
+
}
|
|
324
|
+
|
|
236
325
|
/** Clones every closed node so caller-owned child objects cannot alter an immutable query plan. */
|
|
237
326
|
function cloneFrozenGPUExpressionNode(node: GPUExpressionNode): GPUExpressionNode {
|
|
238
327
|
switch (node.kind) {
|
|
328
|
+
case 'vector':
|
|
329
|
+
return Object.freeze({
|
|
330
|
+
kind: 'vector',
|
|
331
|
+
format: node.format,
|
|
332
|
+
components: Object.freeze(node.components.map(cloneFrozenGPUExpressionNode))
|
|
333
|
+
});
|
|
334
|
+
case 'cast':
|
|
335
|
+
return Object.freeze({
|
|
336
|
+
kind: 'cast',
|
|
337
|
+
format: node.format,
|
|
338
|
+
operand: cloneFrozenGPUExpressionNode(node.operand)
|
|
339
|
+
});
|
|
340
|
+
case 'conditional':
|
|
341
|
+
return Object.freeze({
|
|
342
|
+
kind: 'conditional',
|
|
343
|
+
condition: cloneFrozenGPUExpressionNode(node.condition),
|
|
344
|
+
whenTrue: cloneFrozenGPUExpressionNode(node.whenTrue),
|
|
345
|
+
otherwise: cloneFrozenGPUExpressionNode(node.otherwise)
|
|
346
|
+
});
|
|
239
347
|
case 'column':
|
|
240
348
|
return Object.freeze({kind: 'column', name: node.name});
|
|
241
349
|
case 'literal':
|
|
@@ -262,6 +370,18 @@ function cloneFrozenGPUExpressionNode(node: GPUExpressionNode): GPUExpressionNod
|
|
|
262
370
|
|
|
263
371
|
function collectGPUExpressionColumnNames(node: GPUExpressionNode, columnNames: Set<string>): void {
|
|
264
372
|
switch (node.kind) {
|
|
373
|
+
case 'vector':
|
|
374
|
+
for (const component of node.components)
|
|
375
|
+
collectGPUExpressionColumnNames(component, columnNames);
|
|
376
|
+
break;
|
|
377
|
+
case 'cast':
|
|
378
|
+
collectGPUExpressionColumnNames(node.operand, columnNames);
|
|
379
|
+
break;
|
|
380
|
+
case 'conditional':
|
|
381
|
+
collectGPUExpressionColumnNames(node.condition, columnNames);
|
|
382
|
+
collectGPUExpressionColumnNames(node.whenTrue, columnNames);
|
|
383
|
+
collectGPUExpressionColumnNames(node.otherwise, columnNames);
|
|
384
|
+
break;
|
|
265
385
|
case 'column':
|
|
266
386
|
columnNames.add(node.name);
|
|
267
387
|
break;
|
|
@@ -307,3 +427,141 @@ function assertValidExpressionValue(
|
|
|
307
427
|
throw new Error(`GPUDataFrame ${kind} values must be finite numbers, booleans, or null`);
|
|
308
428
|
}
|
|
309
429
|
}
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* Constructs a fixed-width numeric vector. A null component makes the whole row null.
|
|
433
|
+
*
|
|
434
|
+
* @example
|
|
435
|
+
* ```ts
|
|
436
|
+
* const position = vector('float32x3', [column('x'), column('y'), column('z')]);
|
|
437
|
+
* ```
|
|
438
|
+
*/
|
|
439
|
+
export function vector<Columns extends string>(
|
|
440
|
+
format: GPUExpressionNumericFormat,
|
|
441
|
+
components: readonly GPUExpression<number | null, Columns>[]
|
|
442
|
+
): GPUExpression<readonly number[] | null, Columns> {
|
|
443
|
+
const width = getGPUVectorWGSLLayout(format).components;
|
|
444
|
+
if (![2, 3, 4].includes(width) || components.length !== width)
|
|
445
|
+
throw new Error('Vector width must match its format');
|
|
446
|
+
return new GPUExpression({
|
|
447
|
+
kind: 'vector',
|
|
448
|
+
format,
|
|
449
|
+
components: components.map(component => component.node)
|
|
450
|
+
});
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* Converts a numeric expression to the requested format while preserving its width.
|
|
455
|
+
*
|
|
456
|
+
* @example
|
|
457
|
+
* ```ts
|
|
458
|
+
* const position = vector('sint32x2', [column('x'), column('y')]);
|
|
459
|
+
* const floatPosition = cast(position, 'float32x2');
|
|
460
|
+
* ```
|
|
461
|
+
*/
|
|
462
|
+
export function cast<Value extends GPUExpressionNumericValue, Columns extends string>(
|
|
463
|
+
expression: GPUExpression<Value, Columns>,
|
|
464
|
+
format: GPUExpressionNumericFormat
|
|
465
|
+
): GPUExpression<Value, Columns> {
|
|
466
|
+
return new GPUExpression(makeGPUCastNode(expression.node, format));
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
export function makeGPUCastNode<Format extends GPUExpressionNumericFormat>(
|
|
470
|
+
operand: GPUExpressionNode,
|
|
471
|
+
format: Format
|
|
472
|
+
): {kind: 'cast'; format: Format; operand: GPUExpressionNode} {
|
|
473
|
+
const width = getGPUVectorWGSLLayout(format).components;
|
|
474
|
+
const operandWidth = getKnownExpressionWidth(operand);
|
|
475
|
+
if (operandWidth !== undefined && operandWidth !== width) {
|
|
476
|
+
throw new Error('Numeric casts must preserve width');
|
|
477
|
+
}
|
|
478
|
+
return {kind: 'cast', format, operand};
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
function getKnownExpressionWidth(node: GPUExpressionNode): number | undefined {
|
|
482
|
+
switch (node.kind) {
|
|
483
|
+
case 'vector':
|
|
484
|
+
case 'cast':
|
|
485
|
+
return getGPUVectorWGSLLayout(node.format).components;
|
|
486
|
+
case 'conditional':
|
|
487
|
+
return 1;
|
|
488
|
+
case 'literal':
|
|
489
|
+
case 'parameter':
|
|
490
|
+
return node.value === null ? undefined : 1;
|
|
491
|
+
case 'unary':
|
|
492
|
+
return node.operator === 'negate' ? getKnownExpressionWidth(node.operand) : 1;
|
|
493
|
+
case 'binary': {
|
|
494
|
+
if (isBooleanExpressionNode(node)) {
|
|
495
|
+
return 1;
|
|
496
|
+
}
|
|
497
|
+
const leftWidth = getKnownExpressionWidth(node.left);
|
|
498
|
+
const rightWidth = getKnownExpressionWidth(node.right);
|
|
499
|
+
if (leftWidth !== undefined && rightWidth !== undefined && leftWidth !== rightWidth) {
|
|
500
|
+
throw new Error('Numeric arithmetic requires matching widths');
|
|
501
|
+
}
|
|
502
|
+
return leftWidth ?? rightWidth;
|
|
503
|
+
}
|
|
504
|
+
case 'column':
|
|
505
|
+
return undefined;
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
/** Selects a scalar value when the condition is true. A null condition selects the fallback. */
|
|
510
|
+
export function caseWhen<
|
|
511
|
+
ConditionColumns extends string,
|
|
512
|
+
TrueColumns extends string,
|
|
513
|
+
OtherwiseColumns extends string
|
|
514
|
+
>(
|
|
515
|
+
condition: GPUExpression<boolean | null, ConditionColumns>,
|
|
516
|
+
whenTrue: GPUExpression<number | null, TrueColumns>,
|
|
517
|
+
otherwise: GPUExpression<number | null, OtherwiseColumns>
|
|
518
|
+
): GPUExpression<number | null, ConditionColumns | TrueColumns | OtherwiseColumns> {
|
|
519
|
+
return new GPUExpression({
|
|
520
|
+
kind: 'conditional',
|
|
521
|
+
condition: condition.node,
|
|
522
|
+
whenTrue: whenTrue.node,
|
|
523
|
+
otherwise: otherwise.node
|
|
524
|
+
});
|
|
525
|
+
}
|
|
526
|
+
|
|
527
|
+
/** Returns the first valid scalar value, falling back when the first input is null. */
|
|
528
|
+
export function coalesce<LeftColumns extends string, RightColumns extends string>(
|
|
529
|
+
value: GPUExpression<number | null, LeftColumns>,
|
|
530
|
+
fallback: GPUExpression<number | null, RightColumns>
|
|
531
|
+
): GPUExpression<number | null, LeftColumns | RightColumns> {
|
|
532
|
+
return makeBinaryExpression('coalesce', value, fallback);
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
/** Returns null when two valid scalar values compare equal. */
|
|
536
|
+
export function nullIf<LeftColumns extends string, RightColumns extends string>(
|
|
537
|
+
value: GPUExpression<number | null, LeftColumns>,
|
|
538
|
+
sentinel: GPUExpression<number | null, RightColumns>
|
|
539
|
+
): GPUExpression<number | null, LeftColumns | RightColumns> {
|
|
540
|
+
return makeBinaryExpression('nullif', value, sentinel);
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
/** Checks whether the expression produces a boolean result. */
|
|
544
|
+
export function isBooleanExpressionNode(node: GPUExpressionNode): boolean {
|
|
545
|
+
switch (node.kind) {
|
|
546
|
+
case 'column':
|
|
547
|
+
return false;
|
|
548
|
+
case 'literal':
|
|
549
|
+
case 'parameter':
|
|
550
|
+
return typeof node.value === 'boolean';
|
|
551
|
+
case 'unary':
|
|
552
|
+
return node.operator === 'not' || node.operator === 'is-valid' || node.operator === 'is-null';
|
|
553
|
+
case 'binary':
|
|
554
|
+
return (
|
|
555
|
+
node.operator === 'equal' ||
|
|
556
|
+
node.operator === 'not-equal' ||
|
|
557
|
+
node.operator === 'greater-than' ||
|
|
558
|
+
node.operator === 'greater-than-or-equal' ||
|
|
559
|
+
node.operator === 'less-than' ||
|
|
560
|
+
node.operator === 'less-than-or-equal' ||
|
|
561
|
+
node.operator === 'and' ||
|
|
562
|
+
node.operator === 'or'
|
|
563
|
+
);
|
|
564
|
+
default:
|
|
565
|
+
return false;
|
|
566
|
+
}
|
|
567
|
+
}
|