From 706caf445a3d19bd431654a4b6bf07d1da7725f0 Mon Sep 17 00:00:00 2001 From: Jim Martens Date: Wed, 1 May 2019 17:03:14 +0200 Subject: [PATCH] Re-introduced debug prints Signed-off-by: Jim Martens --- src/twomartens/masterthesis/ssd.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/twomartens/masterthesis/ssd.py b/src/twomartens/masterthesis/ssd.py index 5a25014..42ad968 100644 --- a/src/twomartens/masterthesis/ssd.py +++ b/src/twomartens/masterthesis/ssd.py @@ -181,8 +181,13 @@ def _predict_one_epoch(dataset: tf.data.Dataset, # go through the data set counter = 0 import gc + from pympler import tracker + from tensorflow.python.eager import context + trs = tracker.SummaryTracker() + trs.print_diff() + for inputs in dataset: decoded_predictions_batch = [] if use_dropout: @@ -191,7 +196,9 @@ def _predict_one_epoch(dataset: tf.data.Dataset, decoded_predictions_batch.append(result) del result else: + trs.print_diff() result = np.array(ssd(inputs)) + trs.print_diff() decoded_predictions_batch.append(result) del result