cerebras.modelzoo.common.pytorch_utils#
General purpose Pytorch Utilities
Functions
Checks that the checkpoint is compatible with the current version of modelzoo. |
|
Gather checkpoints in a model directory |
|
Check if the run is configured with muP hyperparameter settings |
|
Loads state dict from checkpoint path and checks for version compatibilty. |
|
Create a unique subdirectory for this run by generating a time stamp so that parallel runs using the same model_dir don't overwrite common files. |
|
Configure default logging format |
|
Move tensor from device to cpu |
|
If the provided value is a Python int or float, it converts them into PyTorch Tensors of type int32 and float32 respectively. |
|
Recursively traverse nested structure and return the items accepted by the selector. |
Classes
Dataset shuffled from the original dataset. |
|
This sampler can be used with a multi-worker distributed dataloader. |
|
Validate Run Configs |
|
Iterator which returns multiple samples of a given input data. |