Skip to content

Commit

Permalink
Some small changes to scripts to clean up flags.
Browse files Browse the repository at this point in the history
  • Loading branch information
Todd Irving Warszawski committed Jan 25, 2019
1 parent e15fbaf commit f84d103
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 16 deletions.
11 changes: 11 additions & 0 deletions code/export_graphs.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env bash

./cnn_cuda --export squeezenet_raw --dnn squeezenet --noopt > squeezenet_raw_output
./cnn_cuda --export inception_raw --dnn inception --noopt > inception_raw_output
./cnn_cuda --export resnet34_raw --dnn resnet34 --noopt > resnet34_raw_output
./cnn_cuda --export rnntc_raw --dnn rnntc --noopt > rnntc_raw_output

./cnn_cuda --export squeezenet_opt --dnn squeezenet > squeezenet_opt_output
./cnn_cuda --export inception_opt --dnn inception > inception_opt_output
./cnn_cuda --export resnet34_opt --dnn resnet34 > resnet34_opt_output
./cnn_cuda --export rnntc_opt --dnn rnntc > rnntc_opt_output
13 changes: 0 additions & 13 deletions code/get_exports.sh

This file was deleted.

6 changes: 3 additions & 3 deletions tensorflow_py/tf_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,16 +215,16 @@ def parse_operator(line1, line2, line3, line4, operator_map, graph_outputs):

parser = argparse.ArgumentParser()
parser.add_argument("--xla", help="Whether to run with TensorFlowXLA optimizations", action="store_true")
parser.add_argument("--model_file", help="The file from which to load the model")
parser.add_argument("--graph_file", help="The file from which to load the graph")
parser.add_argument("--print_tensorboard", help="Name of folder to output the tensorboard information")
parser.add_argument("--iterations", help="How many iterations to average for timing (default 5000)", type=int, default=5000)
parser.add_argument("--discard_iter", help="How many iterations to not time during warm up (default 1000)", type=int, default=1000)
parser.add_argument("--discard_iter", help="How many iterations to discard timing information during warm up (default 1000)", type=int, default=1000)
args = parser.parse_args()

input_shape = []
graph_outputs = set()

with open(args.model_file, 'r') as graph_file:
with open(args.graph_file, 'r') as graph_file:
# The graph nodes are repesented by 4 lines
operator_map = {}
need_input = True
Expand Down

0 comments on commit f84d103

Please sign in to comment.