Closed jofrevalles closed 1 year ago
Merging #58 (8ce73a6) into master (6b1ed8c) will increase coverage by
0.65%
. The diff coverage is94.28%
.
@@ Coverage Diff @@
## master #58 +/- ##
==========================================
+ Coverage 82.11% 82.76% +0.65%
==========================================
Files 12 12
Lines 615 650 +35
==========================================
+ Hits 505 538 +33
- Misses 110 112 +2
Impacted Files | Coverage Δ | |
---|---|---|
src/Transformations.jl | 96.55% <94.28%> (-3.45%) |
:arrow_down: |
Summary
This PR addresses the issue #14 (resolves #14) by introducing the
DiagonalReduction
transformation in thetransform!
function forTensorNetwork
s. This transformation applies diagonal reduction (as defined here) to simplify the tensor network while preserving its mathematical properties. The key idea is to minimize the number of indices by identifying tensors with a certain diagonal structure and collapsing these indices, potentially leading to computational efficiency.In addition to the implementation of the transformation, this PR includes tests to ensure correctness and robustness of the new method.
Example
This example demonstrates how
DiagonalReduction
effectively reduces the dimension of the first tensor and updates the rest of the network accordingly.