Spaces:
Runtime error
Runtime error
File size: 329 Bytes
5c783e4 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
#-*- coding: utf-8 -*-
import os
from yaml import load, dump
try:
from yaml import CLoader as Loader, CDumper as Dumper
except ImportError:
from yaml import Loader, Dumper
from box import Box as edict
def load_config(cfg):
with open(cfg) as f:
config = load(f, Loader=Loader)
return edict(config)
|