-
Notifications
You must be signed in to change notification settings - Fork 3
/
run-train.sh
50 lines (44 loc) · 1.33 KB
/
run-train.sh
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
#!/bin/bash
# tmux session name
name=bgail
# Kill tmux session with $name, if it exists.
tmux kill-session -t $name
# Make new tmux sessions with $name.
tmux new-session -s $name -n w0 -d bash
# Make new windows
tmux new-window -t $name -n main -d bash # main
tmux new-window -t $name -n tb -d bash # tensorboard
tmux new-window -t $name -n chrome -d bash # chrome
# Empty window for killing tmux
tmux send-keys -t $name:w0\
"tmux kill-session" # No Enter here
# Main window for condor jobs
tmux send-keys -t $name:main\
"ssh [email protected]"\
Enter
tmux send-keys -t $name:main\
"cd $PWD"\
Enter
tmux send-keys -t $name:main\
"condor_submit TMPPWD=$PWD submit"\
Enter
## ssh tunneling port for tensorboard
#PORT=5500 # ssh tunneling port
#tmux send-keys -t $name:tb\
# "ssh -L $PORT:127.0.0.1:$PORT [email protected]"\
# Enter
#tmux send-keys -t $name:tb\
# "ssh -L $PORT:127.0.0.1:$PORT wsjeon@c15"\
# Enter
#tmux send-keys -t $name:tb\
# "tensorboard --logdir=/home/wsjeon/code/agent-log/main-gail-tf-mpi --port $PORT"\
# Enter
#
## waiting for tensorboard initialization
#pause 15
#
## chrome to see tensorboard in local
#tmux send-keys -t $name:chrome\
# "google-chrome 127.0.0.1:$PORT"\
# Enter
tmux a