-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathrunexp.py
More file actions
30 lines (24 loc) · 812 Bytes
/
runexp.py
File metadata and controls
30 lines (24 loc) · 812 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
"""Script for running a single experiment."""
import argparse
from ext import processing
from arct import configuration
import arct
import configs
arct.DBI.histories.delete_all_records()
parser = argparse.ArgumentParser()
parser.add_argument('name',
type=str,
help='The name of the training run / experiment')
parser.add_argument('seed',
type=int,
help='The random seed to use')
args = parser.parse_args()
name = getattr(args, 'name')
seed = getattr(args, 'seed')
config = configuration.Config(configs.get_config(name))
config['n_runs'] = 20
config['seed'] = seed
config['name'] = name + '_seed_%s' % seed
config['n_runs'] = 1
processor = processing.Processor(arct.TRAIN_FACTORY, False)
experiment = processor.run_exp(config)