Merged
Conversation
… smith formulation
Transurgeon
reviewed
Sep 17, 2025
Member
Transurgeon
left a comment
There was a problem hiding this comment.
really nice job @dance858 ! I left many comments, some are easy fixes, others we can discuss more. I will do another review of the tests at some point.
| x = self.args[0] | ||
| y = self.args[1] | ||
| assert(x.size == y.size) | ||
|
|
Member
There was a problem hiding this comment.
what if we have constant * constant? Maybe we should have a global hess_vec implementation in expression that checks for:
- If the expression is constant, return empty dict for hess
- If the expression is affine, same thing.
What do you think?
Collaborator
Author
There was a problem hiding this comment.
I totally agree! I added it to the atom class. Please take a look. I also added some error handling there. I like this abstraction.
Should we move it to expression? What do you think?
Member
There was a problem hiding this comment.
I think leaving it in atoms is the right place since that's where we had the hess implementation from before.
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
Please include a short summary of the change.
Issue link (if applicable):
Type of change
Contribution checklist