diffusion_models.inference ========================== .. py:module:: diffusion_models.inference .. autoapi-nested-parse:: Config-driven inference, run through the ``diffusion-models infer`` CLI. Rebuilds a model from a hydra config, loads the weights of a training checkpoint and generates images. The config is composed like for training (``diffusion_models/conf/baseline.yaml``, extended by ``conf/infer.yaml``), so use the same overrides as the run that produced the checkpoint. Install the extra dependencies with ``pip install diffusion-model-framework[inference]``, then run:: diffusion-models infer checkpoint=runs///checkpoints/latest.pt \ +config=small_attention_ema diffusion-models infer checkpoint= +config=small_attention_ema \ number_of_images=16 save_gif=true steps=50 device=cpu The images (and the optional GIF) are written to ``outputs/infer/``. To extend this further, you might want to look into compiling your model to ONNX, TensorRT, OpenVino or other formats.