[WIP] Add flux-canceling randn(sector, inds) constructors#230
Draft
mtfishman wants to merge 1 commit into
Draft
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #230 +/- ##
==========================================
- Coverage 77.88% 75.19% -2.70%
==========================================
Files 29 29
Lines 1709 1701 -8
==========================================
- Hits 1331 1279 -52
- Misses 378 422 +44
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds flux-canceling constructors
randn/rand/zeros(c, codomain[, domain]) at theIndexlevel, so anITensorover graded (block-sparse) indices can be built carrying a nonzero total chargec. They mint a fresh auxiliaryIndexcarryingcand forward to the map-shaped split constructor, appending the aux to the domain dangling last so the physical indices fuse toc. The sector may be a bareTensorKitSectors.Sectoror aSectorRange. These live in a newITensorBaseGradedArraysExt, since ITensorBase does not depend on the sector types.Builds on ITensor/GradedArrays.jl#220 and ITensor/TensorAlgebra.jl#216.
TODO
[sources]pins (GradedArrays intest/, TensorAlgebra in the root) once [WIP] Add flux-cancelingrandn(sector, axes)constructors GradedArrays.jl#220 and Addones_mapandfill_mapsplit constructors TensorAlgebra.jl#216 register.ones/fillat theIndexlevel, which would first need ITensorBase splitones/fillforms (deliberately absent today).