bitorch.layers.register.convert_layers_to

bitorch.layers.register.convert_layers_to(new_mode: RuntimeMode, only: Optional[Iterable[Any]] = None, device: Optional[device] = None, verbose: bool = False) None[source]

Convert all wrapped layers (or a given subset of them) to a new mode. :param new_mode: the new RuntimeMode :param only: optional white”list” (Iterable) of layers or wrapped layers which should be converted :param device: the new device for the layers :param verbose: whether to print which layers are being converted