From da4e624f4130e05006d3ba4f7191797a84be6761 Mon Sep 17 00:00:00 2001 From: Jim Martens Date: Tue, 2 Jul 2019 11:29:54 +0200 Subject: [PATCH] Close figure after usage Signed-off-by: Jim Martens --- src/twomartens/masterthesis/cli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/twomartens/masterthesis/cli.py b/src/twomartens/masterthesis/cli.py index 4031484..78558f0 100644 --- a/src/twomartens/masterthesis/cli.py +++ b/src/twomartens/masterthesis/cli.py @@ -396,6 +396,6 @@ def visualise(args: argparse.Namespace) -> None: current_axis.text(xmin, ymin, label, size='x-large', color='white', bbox={'facecolor': color, 'alpha': 1.0}) pyplot.savefig(f"{output_path}/{str(i).zfill(nr_digits)}") - figure.clear() + pyplot.close(figure) i += 1