Repository navigation
Add Enzyme vs DependencyTracking system Jacobian test and benchmark over all PhasorDynamics cases - #621
Merged
Conversation
nkoukpaizan
marked this pull request as ready for review
October 14, 2026 15:51
superwhiskers
approved these changes
Oct 14, 2026
superwhiskers
left a comment
Collaborator
There was a problem hiding this comment.
looks good to me. i ran it on my machine and achieved similar numbers to those you got
Collaborator
|
How come ratio is getting smaller for larger systems? It looks as if there is a scaling issue with Enzyme. |
Collaborator
I believe most of that can be resolved by makin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This adds an integration test for full-system Enzyme vs DependencyTracking Jacobians. The test loops over all files in
cases/PhasorDynamics/to compute and compare Jacobians via Enzyme and DependencyTracking. A benchmarking phase times the setup, residual evaluation and Jacobian assembly costs.On my macOS,
ctest --verbose -R PhasorDynamicsIntegrationSystemJacobiangenerates:The largest cost differences occur in
evaluateResiduals, where DependencyTracking has the overhead of tracking. Thestd::mapmanipulations for Jacobian assembly are not as bad as I thought.Checklist
-Wall -Wpedantic -Wconversion -Wextra.Further comments
The change to
cases/PhasorDynamics/Toy/ThreeBusConstantSource.case.jsonis a bug fix we missed in previous PRs, and needed to make the case work here.I'll update the CHANGELOG and rebase as this gets closer to ready-to-merge.