-
Hello all, I am currently implementing an optimization procedure for an MPS, where the loss function is written as `def loss(psi):
works works for an individual calculation of the loss, but when running the optimizer
I could not find the problematic function but it's related to the application of .gate_split, since the rest of the loss function does not raise errors. Any way I can solve this issue? Thanks, Rafael |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hi @rafaeleb, you might be able to fix this by using a fixed |
Beta Was this translation helpful? Give feedback.
-
Hi Johnnie, Thanks for the reply. The addition of the compression options did not fix the problem, but it looks like it can be avoided in my particular case by not using gate_split at all (the gates can be decomposed from the start). But it would be nice to know if the gate_split function can be modified is some way to agree with the jax optimizer backend. BR |
Beta Was this translation helpful? Give feedback.
Hi @rafaeleb, you might be able to fix this by using a fixed
max_bond
andcutoff=0.0
in the gate_split function. The problem currently is that the shape of the traced computational graph depends on the cutoff. Also, you should be able to usetorch
which doesn't require a fixed computational graph.