diff --git a/losoto/operations/structure.py b/losoto/operations/structure.py index 3ce6060..f7bf4ed 100644 --- a/losoto/operations/structure.py +++ b/losoto/operations/structure.py @@ -130,6 +130,7 @@ def run( soltab, doUnwrap=False, refAnt='', plotName='', ndiv=1 ): if plotName != '': if plotName.split('.')[-1] != 'png': plotName += '.png' # add png + import sys if not 'matplotlib' in sys.modules: import matplotlib as mpl mpl.use("Agg")