Skip to content
Snippets Groups Projects
Commit f9f81c2d authored by tomrink's avatar tomrink
Browse files

snapshot...

parent d1670735
No related branches found
No related tags found
No related merge requests found
......@@ -76,7 +76,7 @@ def preprocess_image(hr_image):
return tf.expand_dims(hr_image, 0)
def run(in_file):
def run(in_file, out_file):
# model = hub.load(SAVED_MODEL_PATH)
t0 = time.time()
hr_image = get_image(in_file)
......@@ -90,4 +90,7 @@ def run(in_file):
print('inference time: ', (t1-t0))
fake_image = tf.squeeze(fake_image)
return fake_image
\ No newline at end of file
if out_file is not None:
np.save(out_file, fake_image)
else:
return fake_image
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment