Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix cholesky part 2 #1256

Merged
merged 2 commits into from
Jan 28, 2024
Merged

Fix cholesky part 2 #1256

merged 2 commits into from
Jan 28, 2024

Conversation

wsmoses
Copy link
Member

@wsmoses wsmoses commented Jan 28, 2024

Fixes #1254

@codecov-commenter
Copy link

codecov-commenter commented Jan 28, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (4dfe204) 74.53% compared to head (687fc07) 74.69%.

Files Patch % Lines
src/internal_rules.jl 57.14% 3 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1256      +/-   ##
==========================================
+ Coverage   74.53%   74.69%   +0.16%     
==========================================
  Files          35       35              
  Lines       10311    10314       +3     
==========================================
+ Hits         7685     7704      +19     
+ Misses       2626     2610      -16     

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

src/internal_rules.jl Show resolved Hide resolved
@@ -696,11 +697,11 @@ function EnzymeRules.augmented_primal(config, func::Const{typeof(cholesky)}, RT:
nothing
else
if EnzymeRules.width(config) == 1
Cholesky(Matrix(fact), 'L', 0)
Enzyme.make_zero(fact)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAICT this will also create a Cholesky object with the same uplo char as fact? One issue I had noticed (but unfortunately had no time to open an issue) is that on main always L is used.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct this is what it would do

src/internal_rules.jl Show resolved Hide resolved
src/internal_rules.jl Show resolved Hide resolved
@wsmoses wsmoses merged commit 3095a4f into main Jan 28, 2024
43 of 45 checks passed
@wsmoses wsmoses deleted the chol branch January 28, 2024 20:51
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.

Wrong gradient for cholesky
3 participants