Skip to content

Restore Trapani argument check and use only static args#363

Open
matt-graham wants to merge 1 commit intomainfrom
mmg/restore-trapani-arg-check
Open

Restore Trapani argument check and use only static args#363
matt-graham wants to merge 1 commit intomainfrom
mmg/restore-trapani-arg-check

Conversation

@matt-graham
Copy link
Collaborator

Fixes #65 and #273

I am not entirely sure why the check functions body was originally commented out but I suspect it was related to the checks not working within traced JAX functions as el argument would be an abstract tracer rather than a concrete value at tracing. This PR restores most of the checks beyond the assertion that 0 < el < L on the assumption that some checks are better than none and the assertions in terms of L and shape of dl should work with JAX tracing as these will both be known statically at trace time. Also replaced the previous use of now removed logging module to flag warning around large L with using the warn function from the built in warnings module.

@codecov
Copy link

codecov bot commented Feb 20, 2026

Codecov Report

❌ Patch coverage is 89.47368% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 96.12%. Comparing base (cd8db48) to head (0781485).

Files with missing lines Patch % Lines
s2fft/recursions/trapani.py 89.47% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #363      +/-   ##
==========================================
- Coverage   96.14%   96.12%   -0.03%     
==========================================
  Files          32       32              
  Lines        3452     3456       +4     
==========================================
+ Hits         3319     3322       +3     
- Misses        133      134       +1     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix Trapani Jax checks (all checks currently disabled)

2 participants