Skip to content

feat(aggregation): support DataFilter on WebGPU HeatmapLayer - #11207

Merged
ibgreen merged 4 commits into
masterfrom
codex/heatmap-weight-extensions
Nov 18, 2026
Merged

ibgreen merged 4 commits into
masterfrom
codex/heatmap-weight-extensions

Conversation

@ibgreen

@ibgreen ibgreen commented Nov 18, 2026 •

Copy link
Copy Markdown
Collaborator

Background

WebGPU HeatmapLayer did not run DataFilter before accumulating point weights. The weight-pass work is separate from the MaskExtension integration tracked in #7397.

Change List

  • Apply DataFilter shader props during weight accumulation
  • Keep point extensions out of weight reduction
  • Remove DataFilter from the display quad
  • Render test excludes a high-weight point
  • Documentation removes the WebGPU filtering limitation

Verified: lint, 207 node tests, and filtered heatmap render checks on both backends.


Note

Medium Risk
Modifies WebGPU shader pipeline execution and adds a new extension hook for offscreen aggregation passes, though changes are scoped to HeatmapLayer and covered by render and unit tests.

Overview
Adds support for DataFilterExtension filtering and item counting in HeatmapLayer on WebGPU by filtering point weights during the weight accumulation pass.

A new getAggregationShaderProps hook on LayerExtension enables extensions to pass shader uniforms into offscreen aggregation models. HeatmapLayer consumes these shader props during its weight map generation, adds the DECKGL_FILTER_COLOR shader hook to WGSL weight fragment shaders, excludes point filter extensions from the max-weight reduction and display sublayers, and handles deferred count updates for composite layers. Documentation and tests have also been updated to reflect WebGPU data filter support.

Reviewed by Cursor Bugbot for commit 520d8a8. Bugbot is set up for automated code reviews on this repo. Configure here.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-18T20:24:49.989794Z 2cd5fa6 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2cd5fa69c0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@greptile-apps

greptile-apps Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; no new blocking issues were found.

Summary

Adds DataFilterExtension support to WebGPU heatmaps by filtering source points before their weights are added.

  • WebGPU heatmaps filter points before adding their weights.

The earlier category-loading, count-callback, and release-note findings are addressed. No new actionable issues were found.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  A[Source points] --> B[Weight pass with DataFilter settings]
  B --> C[Weight texture]
  C --> D[Maximum reduction]
  C --> E[Display quad without DataFilter]
  D --> E
  A --> F[Separate filtered-item count]
Loading

Reviews (4) · Last reviewed commit: "Merge remote-tracking branch 'origin/mas..." · Reviewed by Greptile

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 71cbbbd. Configure here.

@coveralls

coveralls commented Nov 18, 2026 •

Copy link
Copy Markdown

Coverage Status

coverage: 82.489% (-0.03%) from 82.522% — codex/heatmap-weight-extensions into master

…t-extensions

# Conflicts:
#	docs/whats-new.md
@ibgreen
ibgreen merged commit aa440e4 into master Nov 18, 2026
9 checks passed
@ibgreen
ibgreen deleted the codex/heatmap-weight-extensions branch November 18, 2026 22:00
@ibgreen ibgreen mentioned this pull request Nov 19, 2026
42 of 61 tasks

@chrisgervang chrisgervang left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 520d8a8 after merge; follow-ups below.

One P1: the DataFilterExtension Limitations list is wrong.

Labels: P1 settle before this is merged, P2 can follow, Non-blocking optional.


Generated by Claude Code

Comment on lines 306 to 307
### Always supported:
* `GPUGridLayer`

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: After this removal, the Limitations list does not mention HeatmapLayer. It names GPUGridLayer and CPUGridLayer, which @deck.gl/aggregation-layers no longer exports. It also lists HexagonLayer as "Not supported", while hexagon-layer.md:198 says its GPU path runs extensions. Most of the list is older than this PR.

Could we rewrite the list from the current exports and add HeatmapLayer to the supported layers?


Generated by Claude Code

Comment on lines +42 to +48
/** Supplies shader props for a layer's offscreen aggregation pass. */
getAggregationShaderProps(
this: Layer,
extension: this
): Record<string, Record<string, unknown>> | undefined {
return undefined;
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: getAggregationShaderProps is a new public LayerExtension method. docs/developer-guide/custom-layers/layer-extensions.md lists the other extension methods but not this one. Other extensions on HeatmapLayer get their plugins compiled into the weight pass with default uniforms.

Could we document the hook on that page, or mark it internal?


Generated by Claude Code

(1.77245385 * 0.166666);
return varyings.weights * gaussian;
var weights = varyings.weights * gaussian;
DECKGL_FILTER_COLOR(&weights, fragmentGeometry);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Non-blocking: With filterSoftRange, a faded point keeps its full SUM weight and inflates the MEAN, because this hook only scales alpha. Should the weight pass scale all channels?

Details
  • MEAN divides weights.r by weights.a, so a point at half fade doubles its local mean.
  • WebGL's weights-fs uses the same hook, so both backends match.

Generated by Claude Code

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your trial has ended. Reactivate Greptile to resume code reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants