Spaces:
Runtime error
Runtime error
from typing import List | |
import os | |
from src.utils.multirun_op import multirun_artifact_producer | |
import hydra | |
from omegaconf import DictConfig | |
from loguru import logger | |
from dotenv import load_dotenv, find_dotenv | |
import rootutils | |
# Load environment variables | |
load_dotenv(find_dotenv(".env")) | |
# Setup root directory | |
root = rootutils.setup_root(__file__, indicator=".project-root") | |
def create_artifacts(cfg: DictConfig): | |
base_path = os.path.join(cfg.paths.log_dir, "train", "runs") | |
logger.info( | |
f"Base path: {base_path} and artifact directory: {cfg.paths.artifact_dir}" | |
) | |
multirun_artifact_producer(base_path, cfg.paths.artifact_dir) | |
if __name__ == "__main__": | |
create_artifacts() | |