Basis extension method issue

Hello,
I’m trying to use “basis_extend.jl” from Basis extension method by emstoudenmire · Pull Request #24 · ITensor/ITensorTDVP.jl · GitHub to efficiently perform TDVP calculation. However, I encountered error regarding line 79 of the code: D1, D2 = ITensors.directsum_itensors(bψ, bϕ, dag(bx)) The message is that: “UndefVarError: directsum_itensors not defined”. It seems that directsum_itensors is not recognized as a function. What is the reason of this? Thank you in advance!

ITensors.directsum_itensors was part of the internal implementation of the ITensor directsum function, but was removed in [ITensors] Optimize `directsum` by mtfishman · Pull Request #1185 · ITensor/ITensors.jl · GitHub as part of a rewrite to improve performance. Not sure why Basis extension method by emstoudenmire · Pull Request #24 · ITensor/ITensorTDVP.jl · GitHub was relying on that internal function but it should be easy to update it.

@miles

If you want to use the basis_extend function right now, you should downgrade your version of ITensors to v0.3.41.

Thank you very much! I switched back to version 0.3.41 and it works now.