cerebras.modelzoo.common.run_gpt_inference#
GPT Inference script built using the cstorch API
Functions
Return the path to all available checkpoints |
|
Get the path to the checkpoint with the highest global step |
|
Get the path to the model checkpoint, if any. |
|
Loads state dict from checkpoint path and checks for version compatibilty. |
|
Set attention-related parameters. |
|
Update any missing parameters in the params dictionary with default values |
|
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. |
|
Setup a logging hook that runs whenever an exception is raised that catches and logs the exception to ensure that the full traceback is printed in the log file. |