From 965a7e47886839722823cb2ebc009080d289ad74 Mon Sep 17 00:00:00 2001
From: "Egli Adrian (IT-SCI-API-PFI)" <adrian.egli@sbb.ch>
Date: Wed, 29 May 2019 14:05:36 +0200
Subject: [PATCH] clean up

---
 flatland/utils/graphics_pil.py | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/flatland/utils/graphics_pil.py b/flatland/utils/graphics_pil.py
index 6fb83844..496433c6 100644
--- a/flatland/utils/graphics_pil.py
+++ b/flatland/utils/graphics_pil.py
@@ -19,16 +19,15 @@ def enable_windows_cairo_support():
         os.environ['PATH'] = os.environ['PATH'] + ';' + default_os_path
         if ctypes.util.find_library('cairo') is not None:
             print("cairo installed: OK")
-
 enable_windows_cairo_support()
 from cairosvg import svg2png
+from screeninfo import get_monitors
 
-from IPython.display import SVG
-
-from flatland.core.transitions import RailEnvTransitions
 # from copy import copy
+from flatland.core.transitions import RailEnvTransitions
+
+
 
-from screeninfo import get_monitors
 
 class PILGL(GraphicsLayer):
     def __init__(self, width, height, nPixCell=60):
@@ -252,9 +251,6 @@ class PILSVG(PILGL):
     def pilFromSvgFile(self, sfPath):
         with open(sfPath, "r") as fIn:
             bytesPNG = svg2png(file_obj=fIn, output_height=self.nPixCell, output_width=self.nPixCell)
-
-            image = SVG(url=sfPath)
-        
         with io.BytesIO(bytesPNG) as fIn:
             pil_img = Image.open(fIn)
             pil_img.load()
-- 
GitLab