File size: 425 Bytes
aea73e2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# -*- coding: utf-8 -*-
# Validators
#
# @ Fabian Hörst, fabian.hoerst@uk-essen.de
# Institute for Artifical Intelligence in Medicine,
# University Medicine Essen

from schema import Schema, Or

sweep_schema = Schema(
    {
        "method": Or("grid", "random", "bayes"),
        "name": str,
        "metric": {"name": str, "goal": Or("maximize", "minimize")},
        "run_cap": int,
    },
    ignore_extra_keys=True,
)