From 835f97522875adb94b51aa6229aa1661e5373b87 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Thu, 11 Apr 2019 12:21:33 +0200 Subject: [PATCH] updates --- utils/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/utils/utils.py b/utils/utils.py index dbe53a1d..23a9cff6 100755 --- a/utils/utils.py +++ b/utils/utils.py @@ -519,7 +519,8 @@ def plot_results(start=0, stop=0): # from utils.utils import *; plot_results() 'Test Loss'] for f in sorted(glob.glob('results*.txt')): results = np.loadtxt(f, usecols=[2, 3, 4, 5, 6, 9, 10, 11, 12, 13]).T - x = range(start, stop if stop else results.shape[1]) + n = results.shape[1] # number of rows + x = range(start, min(stop, n) if stop else n) for i in range(10): plt.subplot(2, 5, i + 1) plt.plot(x, results[i, x].clip(max=500), marker='.', label=f)