from typing import Union
from pathlib import Path
import yaml


def load_yaml(ffp: Union[Path, str]):
    """Loads data from a yaml file"""
    with open(ffp, "r") as f:
        return yaml.safe_load(f)