Wildfire-FM / training /train_utils.py
yx21e's picture
Add FireWx-FM training and data loader pipeline
7170e0e verified
Raw
History Blame Contribute Delete
306 Bytes
from __future__ import annotations
import random
import numpy as np
import torch
def set_seed(seed: int) -> None:
"""Set the RNG state used by the original FireWx-FM training script."""
random.seed(seed)
np.random.seed(seed)
torch.manual_seed(seed)
torch.cuda.manual_seed_all(seed)