More Python Machines
Created by: gcarleo
This PR ports the all-things pure-state RBMs to python
-
RbmSpin -
RbmSpinSymm -
RbmSpinReal -
RbmSpinPhase -
RbmMultiVal -
Jastrow -
JastrowSymm
Important change is that most things are implemented in a single class, instead of doing multiple classes as in the old c++ code. For example, RbmSpinReal
is just a short-cut for
RbmSpin(...,dtype=float)
In turn this means that we have some functionalities that weren't available before, for example we can have real-valued RbmMultiVal
just changing dtype in its constructor.
Symmetries in the RBM yet are implemented with a simple logic, i.e. RbmSpinSymm
, is just a short-cut for
RbmSpin(...,symmetry=True)
Notice that now we can pass an arbitrary automorphism vector to symmetry (instead of just passing True, so that a graph is not explicitly required in the incoming hilbert space).
This immediately allows new machines that weren't available before. Most notably, we now have a nice RbmMultiVal
with symmetries, that is pretty handy/very accurate for the translation-invariant Bose Hubbard model.
I have update the example in BoseHubbard1d/bosehubbard1d.py
accordingly.
@VolodyaCO this might be of interest for you if you are still working on the Bose Hubbard (also see #328 (closed).