Closed jofrevalles closed 1 year ago
Merging #63 (ada6a56) into master (67b417f) will increase coverage by
0.68%
. The diff coverage is95.55%
.
@@ Coverage Diff @@
## master #63 +/- ##
==========================================
+ Coverage 84.21% 84.89% +0.68%
==========================================
Files 12 12
Lines 703 748 +45
==========================================
+ Hits 592 635 +43
- Misses 111 113 +2
Impacted Files | Coverage Δ | |
---|---|---|
src/Transformations.jl | 98.07% <95.55%> (-1.03%) |
:arrow_down: |
Summary
This PR addresses the issue #17 (resolves #17) by introducing the
ColumnReduction
transformation in thetransform!
function forTensorNetwork
s. This transformation applies the column reduction (as defined here) to simplify the tensor network. The key idea is to reduce the rank of the tensors that have a dimension where all but a "column" is filled with zeros.Furthermore, we have extended the scope of this method to handle cases where more than one column contains non-zeros but specific columns are entirely zero-filled. This allows the reduction of the index dimensionality where columns are filled with zeros.
In addition to implementing the transformation, this PR includes tests to ensure the correctness and robustness of the new method.
Example
The primary function of
ColumnReduction
is to decrease tensor rank where a dimension features only one non-zero 'column'. The following example illustrates this operation:In this example, the column reduction transformation results in a network where the tensors are unconnected.
We now show how we enhanced the transformation to operate in scenarios where more than one non-zero column exists. The example below highlights such an instance:
In this example we show that when we have only one zero column in an index, we can apply a transformation to reduce the dimension of that index.