ITensors.jl
ITensors.jl copied to clipboard
Make certain delta contractions return views of the original ITensor storage
Right now, delta contractions like randomITensor(i, j) * delta() and randomITensor(i, j) * delta(dag(j), j') make copies of the ITensor. However, we've decided that they should avoid copying the ITensor storage, so should return views to the tensor storage (like doing replaceinds). This would technically be breaking so we'll do it for the v0.2 release.
Also see discussion in PR #569.
Also see issue #618 for a proposal on how to do this in a way that is not too confusing in terms of floating point operations and the view behavior. So in that proposal, the current behavior of delta would remain, and a A * delta(One()) could be a non-copying contraction of A.