Skip to content

Consolidate color map across plots in LLMAttributionResult#1751

Closed
aobo-y wants to merge 3 commits into
meta-pytorch:masterfrom
aobo-y:export-D89952528
Closed

Consolidate color map across plots in LLMAttributionResult#1751
aobo-y wants to merge 3 commits into
meta-pytorch:masterfrom
aobo-y:export-D89952528

Conversation

@aobo-y
Copy link
Copy Markdown
Contributor

@aobo-y aobo-y commented Dec 31, 2025

Summary: as title

Differential Revision: D89952528

Summary:

Add a new `mask_list` argument to `ImageMaskInput` that allows defining overlapping features on the same pixel. Unlike `mask` where each pixel belongs to exactly one feature, `mask_list` accepts a list of binary masks where each mask indicates one feature. This enables more flexible image segmentation for attribution analysis
- Added `mask_list` parameter that takes precedence over `mask` when provided
- Updated `to_model_input` to handle both `mask_list` and `mask` modes
- Updated `format_pixel_attr` to sum attributions from overlapping features when using `mask_list`

(sum attr is not the best choice to represent overlapped pixels, up to change later)

Differential Revision: D89949211
Summary:

as title

Differential Revision: D89952326
Summary: as title

Differential Revision: D89952528
@meta-cla meta-cla Bot added the cla signed label Dec 31, 2025
@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented Dec 31, 2025

@aobo-y has exported this pull request. If you are a Meta employee, you can view the originating Diff in D89952528.

aobo-y added a commit to aobo-y/captum that referenced this pull request Dec 31, 2025
aobo-y added a commit to aobo-y/captum that referenced this pull request Dec 31, 2025
aobo-y added a commit to aobo-y/captum that referenced this pull request Dec 31, 2025
aobo-y added a commit to aobo-y/captum that referenced this pull request Dec 31, 2025
@meta-codesync meta-codesync Bot closed this in 4fade3a Jan 2, 2026
@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented Jan 2, 2026

This pull request has been merged in 4fade3a.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants