@classmethod
    def from_yaml(cls, yaml_path, validator_map=None, resource_roots=None):
        validator_map = validator_map or {}
        resource_roots = resource_roots or []
        file_text = files.get_file_text(yaml_path)
        spec = yaml.safe_load(file_text)
        validator_map = cls.get_validator_map(validator_map)
        return cls.from_spec(spec, validator_map, resource_roots)
Constructs and returns a validator from the provided yaml file.
dataset/ETHPy150Open openstack/sahara/sahara/plugins/images.py/SaharaImageValidatorBase.from_yaml