Skip to content

WIP - #1311

Draft
RBendias wants to merge 2 commits into
mainfrom
feat/tabletensor-masked-fill
Draft

WIP#1311
RBendias wants to merge 2 commits into
mainfrom
feat/tabletensor-masked-fill

Conversation

@RBendias

Copy link
Copy Markdown
Collaborator

Summary

Support x.masked_fill(mask, value) and torch.masked_fill(x, mask, value) for structured tensor containers, including ordinary scalar and zero-dimensional tensor fills.

Description of the change

Boolean masks broadcast over rows and batch dimensions. Mask columns follow the fixed numerical, categorical, datetime, text, and identifier block order, independently of schema dictionary insertion order. Existing column names and category vectors are preserved, and filling does not mutate the input.

Numerical fills follow PyTorch's dtype semantics. Categorical fills refer to existing category values rather than codes; unknown values are rejected for affected columns. NaN maps to each container's missing-value representation, including nullable identifiers, timestamps, and text. Non-missing numeric values cannot replace text or variable-length cells.

Validation

n/a

@copy-pr-bot

copy-pr-bot Bot commented Oct 30, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@codecov

codecov Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.73554% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.56%. Comparing base (60bafe8) to head (d97c92f).
⚠️ Report is 1 commits behind head on main.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
sdm/tensor/columnar.py 78.26% 5 Missing ⚠️
sdm/tensor/categorical.py 92.59% 2 Missing ⚠️
sdm/tensor/var_len.py 90.47% 2 Missing ⚠️
sdm/tensor/nullable.py 94.11% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1311      +/-   ##
==========================================
+ Coverage   82.41%   82.56%   +0.15%     
==========================================
  Files         186      186              
  Lines       11803    11934     +131     
==========================================
+ Hits         9727     9853     +126     
- Misses       2076     2081       +5     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

This branch has not been deployed

No deployments
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.

1 participant