import yaml


def read_yaml(filename):
    """Reads data from a yaml file."""

    with open(filename, 'r', encoding='utf-8') as file:
        data = yaml.load(file, Loader=yaml.FullLoader)

    return data