container

Dynamic sequential implementation (variable depth based on torch.nn.modules.container).

Classes

DynamicModuleList

An nn.ModuleList container with dynamic hyperparams and variable depth.

class DynamicModuleList

Bases: DynamicModule, ModuleList

An nn.ModuleList container with dynamic hyperparams and variable depth.

Unlike _DynamicSequential, this module supports sorting/reordering of modules based on importance in addition to variable depth.