-
Notifications
You must be signed in to change notification settings - Fork 2
/
config.py
122 lines (98 loc) · 2.29 KB
/
config.py
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
"""
Config
"""
DEFAULT_MODE = 'train'
"""
The default mode the program should run in
"""
MODE_OPTIONS = ['train', 'test']
"""
The supported modes
"""
DEFAULT_ENV_NAME = 'CartPole-v0'
"""
The OpenAI environment name to be used
"""
DEFAULT_NUM_ITERATIONS = 50000
"""
The default number of iteration to train the model
"""
DEFAULT_BATCH_SIZE = 128
"""
The default batch size the model should be trained on
"""
DEFAULT_MAX_REPLAY_HISTORY = 1000000
"""
The default max length of the replay buffer
"""
DEFAULT_GAMMA = 0.95
"""
The default discount rate for the Q learning
"""
DEFAULT_EPSILON = 0.05
"""
The default value for epsilon
"""
DEFAULT_EVAL_EPS = 10
"""
The default number of episode the model should be evaluated with
"""
DEFAULT_LEARNING_RATE = 0.001
"""
The default learning rate
"""
DEFAULT_CHECKPOINT_LOCATION = './checkpoints'
"""
The default location to store the training checkpoints
"""
DEFAULT_MODEL_LOCATION = './model'
"""
The default location to store the best performing models
"""
DEFAULT_TARGET_NETWORK_UPDATE_FREQUENCY = 120
"""
How often the target Q network should get parameter update
from the training Q network.
"""
DEFAULT_RENDER_OPTION = 'none'
"""
The default value for rendering option
"""
RENDER_OPTIONS = ['none', 'collect']
"""
The available render options:
* none: don't render anything
* collect: render the game play while collecting data
"""
DEFAULT_VERBOSITY_OPTION = 'progress'
"""
The default verbosity option
"""
VERBOSITY_OPTIONS = ['progress', 'loss', 'policy', 'init']
"""
The available verbosity options:
* progress: show the training progress
* loss: show the logging information from loss calculation
* policy: show the logging information from policy generation
* init: show the logging information from initialization
"""
DEFAULT_VISUALIZER_TYPE = 'none'
"""
The default visualizer type
"""
VISUALIZER_TYPES = ['none', 'streamlit']
DEFAULT_PERSIST_PROGRESS_OPTION = 'all'
PERSIST_PROGRESS_OPTIONS = ['none', 'all']
DEFAULT_PAUSE_TIME = 0
"""
The default value for pausing before execution starts
to make time for screen recording. It's only available
in testing mode since it's pointless to do so while
training.
"""
DEFAULT_MIN_STEPS = 10
"""
The minimum number of steps the evaluation should run
per episode so that the tester can better visualize how
the agent is doing.
"""