Salome HOME
OK MEDCouplingFieldFloat is usable
[tools/medcoupling.git] / src / MEDLoader / Swig / MEDLoaderCouplingTrainingSession.py
index 418515e71210aebaed0be25a1ea550b08dad92b5..e301dd71a08183de82a047829c3b69cd3656ce95 100644 (file)
@@ -1,5 +1,5 @@
 #  -*- coding: iso-8859-1 -*-
-# Copyright (C) 2007-2015  CEA/DEN, EDF R&D
+# Copyright (C) 2007-2016  CEA/DEN, EDF R&D
 #
 # This library is free software; you can redistribute it and/or
 # modify it under the terms of the GNU Lesser General Public
@@ -481,12 +481,13 @@ from numpy import *
 from math import acos
 
 med_root_dir=os.getenv("MEDCOUPLING_ROOT_DIR")
+agitateur_file = ""
 if med_root_dir:
   agitateur_file = os.path.join(os.getenv("MEDCOUPLING_ROOT_DIR"),"share","resources","med","agitateur.med")
-  if not os.path.exists(agitateur_file):
-    current_dir = os.path.dirname(os.path.realpath(__file__))
-    agitateur_file=os.path.join(current_dir, "..", "..", "..", "resources","agitateur.med")
-  pass
+if not os.path.exists(agitateur_file):
+  current_dir = os.path.dirname(os.path.realpath(__file__))
+  agitateur_file=os.path.join(current_dir, "..", "..", "..", "resources","agitateur.med")
+pass
 data=MEDFileData(agitateur_file)
 ts=data.getFields()[0].getTimeSteps()
 print ts