Skip to content

Commit

Permalink
fix reshape in diagonal contract
Browse files Browse the repository at this point in the history
  • Loading branch information
lpawela committed Apr 3, 2024
1 parent ee95376 commit 089163c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/contractions/diagonal.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ function contract_matrix_tensor3(C::DiagonalTensor{R}, B::Tensor{R,3}) where {R<
B = contract_matrix_tensor3(C.e2, B)
# @cast B[l, r, (q1, q2)] := B[l, (r, q1), q2] (q1 ∈ 1:size(C.e1, 1))
q1 = size(C.e1, 1)
B = reshape(B, size(B, 1), size(B, 2) ÷ q2, size(B, 3) * q1)
B = reshape(B, size(B, 1), size(B, 2) ÷ q1, size(B, 3) * q1)
end

0 comments on commit 089163c

Please sign in to comment.