Skip to content

Reject trivial outputs that pass allclose inside atol - #180

Open
tuannx wants to merge 1 commit into
ScalingIntelligence:mainfrom
tuannx:cursor/reject-trivial-near-zero-outputs-5eb4
Open

tuannx wants to merge 1 commit into
ScalingIntelligence:mainfrom
tuannx:cursor/reject-trivial-near-zero-outputs-5eb4

Conversation

@tuannx

@tuannx tuannx commented Oct 27, 2026 •

Copy link
Copy Markdown

allclose scales rtol by the candidate, so an all-zero tensor passes whenever every reference element is within atol. Softmax, Frobenius norm, L2 norm, and min-reduction on the shipped level-1 shapes land in that band. Require tensor-level relative error there, and reject a collapsed spread when a constant mean would itself pass allclose.

Fixes #165

allclose scales rtol by the candidate, so an all-zero tensor passes
whenever every reference element is within atol. Softmax, Frobenius
norm, L2 norm, and min-reduction on the shipped level-1 shapes land in
that band. Require tensor-level relative error there, and reject a
collapsed spread when a constant mean would itself pass allclose.

Co-authored-by: Tony Nguyen <tuannx87@gmail.com>
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.

Correctness check can be passed by returning zeros on 4 of 60 level-1 problems

2 participants