multigeom.encoders.validate_encoder#
- multigeom.encoders.validate_encoder(encoder, *, device=None, image_shape=(1, 64, 64), sigma=0.22, purpose='all', n_images=8, seed=0, atol=1e-05)[source]#
Check encoder against the contract. purpose is “training” (rules for training the diffusion model), “inference” or “all” (both). Raises EncoderContractError on a violation; warnings are in the report. The check puts the encoder in eval mode and leaves it there.