april-tools / cirkit

a python framework to build, learn and reason about probabilistic circuits and tensor networks
https://cirkit-docs.readthedocs.io/en/latest/
GNU General Public License v3.0
71 stars 1 forks source link

Modify and doc tensor shapes, and misc fix #149

Closed lkct closed 11 months ago

lkct commented 11 months ago

Closes #132

  1. Added support for multiple batch dims in input. In exchange, channel dim is now compulsory (even for 1 channel).
  2. Documented tensor shapes across the whole forward process. It's now clear what's produced at each step.
  3. Changed the shape of fold_mask back to (F,H) due to input shapes. TODO: we need to find a better impl for it.
  4. Enforced an input to TensorizedPC, even when it's not needed -- this unified the interface.
  5. Included various minor fixes to adjust impl and docstrings/comments.