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 sum and subtraction for Tensor with same inds but different permutation #137

Merged
merged 9 commits into from
Mar 21, 2024

Conversation

jofrevalles
Copy link
Member

This PR resolves #136. Additionally, we add some small tests to cover for the changes.

Copy link

codecov bot commented Mar 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.54%. Comparing base (fcafa0b) to head (f3c58ac).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #137      +/-   ##
==========================================
+ Coverage   84.35%   84.54%   +0.19%     
==========================================
  Files          11       11              
  Lines         639      647       +8     
==========================================
+ Hits          539      547       +8     
  Misses        100      100              

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

Comment on lines 10 to 14
@test issetequal(size(C), (2, 3, 2))

D = A - B
@test issetequal(inds(D), (:i, :j, :k))
@test issetequal(size(D), (2, 3, 2))
Copy link
Member

Choose a reason for hiding this comment

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

You should also test the result.

@jofrevalles jofrevalles requested a review from mofeing March 20, 2024 12:25
Co-authored-by: Sergio Sánchez Ramírez <[email protected]>
@jofrevalles jofrevalles requested a review from mofeing March 20, 2024 14:20
@jofrevalles
Copy link
Member Author

Can we merge this, @mofeing ?

@mofeing
Copy link
Member

mofeing commented Mar 21, 2024

Yep, I approved it

@mofeing mofeing merged commit 58a1035 into master Mar 21, 2024
7 checks passed
@mofeing mofeing deleted the fix/tensor_sum branch March 21, 2024 09:23
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.

Basic arithmetic operation fails on Tensors with matching inds but different permutation
2 participants