Conversation
Codecov Report❌ Patch coverage is
🚀 New features to boost your workflow:
|
Benchmark Results
Benchmark PlotsA plot of the benchmark results have been uploaded as an artifact to the workflow run for this PR. |
Replace runtime if-statements with Julia multiple dispatch for the normal parameter in PHS derivative functions. Split each function into two methods: one for Nothing (standard derivative) and one for AbstractVector (Hermite/directional derivative). Also adds AVOID_INF consistently to prevent division by zero. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update operator implementations and tests for jacobian/gradient functionality. Includes documentation updates and test refinements. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Jacobian operator and autodiff support
Davide-Miotti
left a comment
There was a problem hiding this comment.
The refactored part looks very good, I'm missing the ext/ part, because I need a bit more context. I only suggested a further simplification of the operators interface, we might leave it as is for now, but in the future all this code repetition might hinder further development.
There was a problem hiding this comment.
It seems to me like we are having a lot of code repetition between different operators, most of the code remains the same with very subtle changes. You already cleaned it up a lot and it is very clear but I feel like we can simplify it further and make it really great. Using Claude I tried to find a way to get rid of these repetitions and after some trial and error it came up with what is written inside OPERATOR_REFACTORING_IDEAS.md (it is actually a single idea). I pushed it to this branch so that it remains saved even if you ask claude to refine it before implementing.
There was a problem hiding this comment.
Great job here, the script is long but it really is well refactored now
closes #48 and includes other refactors so we dispatch at a lower level than
_build_collocation_matrix!, etc. allowing us to simplify, remove some duplicated code in stencil_math.jl