Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding script to run one-shot NT3 benchmark with Tensorflow 2.0 #71

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions workflows/one-shot/job-tf2.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash -l
set -eu

# JOB SH

echo $( basename $0 )
hostname

source /opt/modules/default/init/bash
module load modules
PATH=/opt/cray/elogin/eproxy/2.0.14-4.3/bin:$PATH # For aprun
module load alps

set -x
aprun -n 1 -N 1 $THIS/run-nt3-tf2.sh
24 changes: 24 additions & 0 deletions workflows/one-shot/run-nt3-tf2.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/bin/bash -l
# Need -l to reset modules ...
set -eu

# RUN NT3

echo $( basename $0 )
hostname

# Modules start
module unload cray-python/3.6.5.3
module load datascience/tensorflow-2.0
# Modules end

which python

# Report original source directory
echo THIS=$THIS

BENCHMARKS=$( readlink --canonicalize $THIS/../../../Benchmarks )
NT3=$BENCHMARKS/Pilot1/NT3/nt3_baseline_keras2.py

set -x
python $NT3 --epochs 1
28 changes: 28 additions & 0 deletions workflows/one-shot/submit-tf2.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#!/bin/bash -l
set -eu

# SUBMIT SH

THIS=$( readlink --canonicalize $( dirname $0 ) )

DIRECTORY=$THIS
OUTPUT=$THIS/output.txt

source $THIS/settings.sh

if [[ -f $OUTPUT ]]
then
mv --backup=numbered $OUTPUT $OUTPUT.bak
fi

set -x
qsub -n $WORKERS \
-t $WALLTIME \
-A $PROJECT \
-q $QUEUE \
-o $OUTPUT \
-e $OUTPUT \
--env THIS=$THIS \
--cwd $DIRECTORY \
--jobname $JOBNAME \
$THIS/job-tf2.sh