API reference#

Reference for pimm’s public Python API. For narrative guides, start with Start.

Calling nn.Module objects#

Call a model or loss as a normal Python callable:

output = model(input_dict)

Do not call model.forward(input_dict) directly. For every torch.nn.Module, PyTorch’s call machinery invokes forward() and runs registered hooks. Calling forward yourself bypasses that machinery, which can break instrumentation, profiling, and other hook-based behavior.

The generated class pages show forward(...) when pimm defines it on that class because the signature and input/output documentation are still useful. Inherited PyTorch boilerplate is omitted; the calling rule above applies to every module.

Registries#

pimm builds everything from config dictionaries with a type key, resolved through small registries (see Experiment anatomy). Each page below is generated from the live registry, grouped by role, and lists every registered type with a link to its autodoc page.

Core API#

Some important functions and classes that are not built from a registry.