Btw, the fact that partial results are hidden inside training_step() seems a common problem for inheritance. Because of this, we need to evaluate the encoder twice in each step here. In the future, we might think of a way to make this easier, like having the CVs implementing a evaluate_loss() method that takes a bunch of variables that currently have scope only within training_step() (e.g., the result of the encoder).
Originally posted by @andrrizzi in #62 (comment)