-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_torch_experiment.bat
44 lines (38 loc) · 1.07 KB
/
run_torch_experiment.bat
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
@ECHO OFF
TITLE Calling run_experiment.py to run experiment via ClearML...
REM Hyperparameters variables. Tweak this to change the configuration
SET NO_CUDA=False
SET SEED=1
SET BATCH_SIZE=32
SET TEST_BATCH_SIZE=32
SET MOMENTUM=0.5
SET EPOCHS=3
SET LEARN_RATE=0.2
SET LOG_INTERVAL=100
SET SAVE_NAME=mnist.pt
SET USE_PRETRAINED=False
SET PRETRAINED_MODEL_NAME=mnist.pt
REM Setup PYTHONPATH to include main src folder
SET PYTHONPATH=%PYTHONPATH%;%~dp0%/src
REM Setup command string
SET CMD_STRING=python %~dp0%/src/pytorch/run_experiment.py^
--no-cuda ^
--seed %SEED% ^
--batch-size %BATCH_SIZE% ^
--test-batch-size %TEST_BATCH_SIZE% ^
--momentum %MOMENTUM% ^
--epochs %EPOCHS% ^
--learn-rate %LEARN_RATE% ^
--log-interval %LOG_INTERVAL% ^
--save-name %SAVE_NAME%
IF %NO_CUDA%==True (
SET CMD_STRING=%CMD_STRING%^
--no-cuda
)
IF %USE_PRETRAINED%==True (
SET CMD_STRING=%CMD_STRING%^
--use-pretrained^
--pretrained-model-name %PRETRAINED_MODEL_NAME%
)
REM Execute run_experiment.py to run ClearML experiment
%CMD_STRING%