From 2735c1c5a9244881a60ab0cd24805779d50b763a Mon Sep 17 00:00:00 2001 From: Jim Martens Date: Mon, 29 Apr 2019 11:47:04 +0200 Subject: [PATCH] Fixed formatting Signed-off-by: Jim Martens --- src/twomartens/masterthesis/ssd.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/twomartens/masterthesis/ssd.py b/src/twomartens/masterthesis/ssd.py index e2804ec..804d9e5 100644 --- a/src/twomartens/masterthesis/ssd.py +++ b/src/twomartens/masterthesis/ssd.py @@ -191,7 +191,8 @@ def _predict_one_epoch(dataset: tf.data.Dataset, # save predictions batch-wise to prevent memory problems if nr_digits is not None: - filename = f"{output_file}-{counter:{nr_digits}d}.npy" + counter = str(counter).zfill(nr_digits) + filename = f"{output_file}-{counter}.npy" else: filename = f"{output_file}-{counter:d}.npy"