Salome HOME
Removing obsolete case files
authorJean-Philippe ARGAUD <jean-philippe.argaud@edf.fr>
Thu, 3 Oct 2013 07:07:14 +0000 (09:07 +0200)
committerJean-Philippe ARGAUD <jean-philippe.argaud@edf.fr>
Thu, 3 Oct 2013 07:07:14 +0000 (09:07 +0200)
20 files changed:
src/tests/daSalome/Makefile.am [deleted file]
src/tests/daSalome/test000_Blue.py [deleted file]
src/tests/daSalome/test000_Blue_AnalysisCode.py [deleted file]
src/tests/daSalome/test000_Blue_AnalysisFile.py.in [deleted file]
src/tests/daSalome/test017.comm.in [deleted file]
src/tests/daSalome/test017_3DVAR_function_script.py [deleted file]
src/tests/daSalome/test017_3DVAR_init_data.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_LBFGSB.comm.in [deleted file]
src/tests/daSalome/test_aster_zzzz159a_aster_functions.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_background.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_background_error.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_functions.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_init_algorithm.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_init_algorithm_LBFGSB.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_init_parameters.py.in [deleted file]
src/tests/daSalome/test_aster_zzzz159a_observation.py [deleted file]
src/tests/daSalome/test_aster_zzzz159a_observation_error.py [deleted file]
src/tests/daSalome/zzzz159a.3 [deleted file]
src/tests/daSalome/zzzz159a.export.esclave.in [deleted file]
src/tests/daSalome/zzzz159a.mail [deleted file]

diff --git a/src/tests/daSalome/Makefile.am b/src/tests/daSalome/Makefile.am
deleted file mode 100644 (file)
index fbf014d..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-include $(top_srcdir)/adm_local/make_common_starter.am
-
-DATA_INST = \
-           test000_Blue_AnalysisCode.py test000_Blue_AnalysisFile.py test000_Blue.py \
-           test017_3DVAR_function_script.py test017_3DVAR_init_data.py \
-           test017.comm \
-           test_aster_zzzz159a_background_error.py \
-           test_aster_zzzz159a_background.py \
-           test_aster_zzzz159a_observation_error.py \
-           test_aster_zzzz159a_observation.py \
-           test_aster_zzzz159a_functions.py \
-           test_aster_zzzz159a_aster_functions.py \
-           test_aster_zzzz159a_init_algorithm.py \
-           test_aster_zzzz159a_init_parameters.py \
-           test_aster_zzzz159a_init_algorithm_LBFGSB.py \
-           zzzz159a.3  zzzz159a.export.esclave  zzzz159a.mail \
-           test_aster_zzzz159a_LBFGSB.comm
-
-testsdasalome_DATA = ${DATA_INST}
-
-EXTRA_DIST = test000_Blue_AnalysisCode.py test000_Blue_AnalysisFile.py.in test000_Blue.py \
-            test017_3DVAR_function_script.py test017_3DVAR_init_data.py \
-            test017.comm.in \
-            test_aster_zzzz159a_background_error.py \
-            test_aster_zzzz159a_background.py \
-            test_aster_zzzz159a_observation_error.py \
-            test_aster_zzzz159a_observation.py \
-            test_aster_zzzz159a_functions.py \
-            test_aster_zzzz159a_aster_functions.py \
-            test_aster_zzzz159a_init_algorithm.py \
-            test_aster_zzzz159a_init_parameters.py.in \
-            test_aster_zzzz159a.py.in \
-            test_aster_zzzz159a_init_algorithm_LBFGSB.py \
-            zzzz159a.3  zzzz159a.export.esclave.in  zzzz159a.mail \
-            test_aster_zzzz159a_LBFGSB.comm.in
diff --git a/src/tests/daSalome/test000_Blue.py b/src/tests/daSalome/test000_Blue.py
deleted file mode 100644 (file)
index 5eb2ecb..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-study_config = {}
-study_config["Name"] = "test000_Blue"
-study_config["Algorithm"] = "Blue"
-
-Background_config = {}
-Background_config["Data"] = "0,1,2"
-Background_config["Type"] = "Vector"
-Background_config["From"] = "String"
-study_config["Background"] = Background_config
-
-BackgroundError_config = {}
-BackgroundError_config["Data"] = "1 0 0;0 1 0;0 0 1"
-BackgroundError_config["Type"] = "Matrix"
-BackgroundError_config["From"] = "String"
-study_config["BackgroundError"] = BackgroundError_config
-
-Observation_config = {}
-Observation_config["Data"] = "0.5,1.5,2.5"
-Observation_config["Type"] = "Vector"
-Observation_config["From"] = "String"
-study_config["Observation"] = Observation_config
-
-ObservationError_config = {}
-ObservationError_config["Data"] = "1 0 0;0 1 0;0 0 1"
-ObservationError_config["Type"] = "Matrix"
-ObservationError_config["From"] = "String"
-study_config["ObservationError"] = ObservationError_config
-
-ObservationOperator_config = {}
-ObservationOperator_config["Data"] = "1 0 0;0 1 0;0 0 1"
-ObservationOperator_config["Type"] = "Matrix"
-ObservationOperator_config["From"] = "String"
-study_config["ObservationOperator"] = ObservationOperator_config
-
-Analysis_config = {}
-Analysis_config["Data"] = """
-import numpy
-precision = 1.e-13
-
-Xa = ADD.get("Analysis")
-print
-print "    Nombre d'analyses  :",Xa.stepnumber()
-print "    Analyse résultante :",Xa[0]
-#
-# Vérification du résultat
-# ------------------------
-if max(numpy.array(Xa[0])-numpy.array([0.25, 1.25, 2.25])) > precision:
-  raise ValueError("Résultat du test erroné")
-else:
-  print "    Test correct, erreur maximale inférieure à %s"%precision
-  print
-"""
-Analysis_config["From"] = "String"
-study_config["Analysis"] = Analysis_config
diff --git a/src/tests/daSalome/test000_Blue_AnalysisCode.py b/src/tests/daSalome/test000_Blue_AnalysisCode.py
deleted file mode 100644 (file)
index 6d07a3b..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: Jean-Philippe Argaud, jean-philippe.argaud@edf.fr, EDF R&D
-
-import numpy
-precision = 1.e-13
-
-Xa = ADD.get("Analysis")
-print
-print "    Nombre d'analyses  :",Xa.stepnumber()
-print "    Analyse résultante :",Xa[0]
-#
-# Vérification du résultat
-# ------------------------
-if max(numpy.array(Xa[0])-numpy.array([0.25, 1.25, 2.25])) > precision:
-  raise ValueError("Résultat du test erroné")
-else:
-  print "    Test correct, erreur maximale inférieure à %s"%precision
-  print
-
diff --git a/src/tests/daSalome/test000_Blue_AnalysisFile.py.in b/src/tests/daSalome/test000_Blue_AnalysisFile.py.in
deleted file mode 100644 (file)
index 463f29d..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-study_config = {}
-study_config["Name"] = "test000_Blue"
-study_config["Algorithm"] = "Blue"
-
-Background_config = {}
-Background_config["Data"] = "0,1,2"
-Background_config["Type"] = "Vector"
-Background_config["From"] = "String"
-study_config["Background"] = Background_config
-
-BackgroundError_config = {}
-BackgroundError_config["Data"] = "1 0 0;0 1 0;0 0 1"
-BackgroundError_config["Type"] = "Matrix"
-BackgroundError_config["From"] = "String"
-study_config["BackgroundError"] = BackgroundError_config
-
-Observation_config = {}
-Observation_config["Data"] = "0.5,1.5,2.5"
-Observation_config["Type"] = "Vector"
-Observation_config["From"] = "String"
-study_config["Observation"] = Observation_config
-
-ObservationError_config = {}
-ObservationError_config["Data"] = "1 0 0;0 1 0;0 0 1"
-ObservationError_config["Type"] = "Matrix"
-ObservationError_config["From"] = "String"
-study_config["ObservationError"] = ObservationError_config
-
-ObservationOperator_config = {}
-ObservationOperator_config["Data"] = "1 0 0;0 1 0;0 0 1"
-ObservationOperator_config["Type"] = "Matrix"
-ObservationOperator_config["From"] = "String"
-study_config["ObservationOperator"] = ObservationOperator_config
-
-Analysis_config = {}
-Analysis_config["Data"] = "@prefix@/tests/daSalome/test000_Blue_AnalysisCode.py"
-Analysis_config["From"] = "Script"
-study_config["Analysis"] = Analysis_config
-
diff --git a/src/tests/daSalome/test017.comm.in b/src/tests/daSalome/test017.comm.in
deleted file mode 100644 (file)
index 4d6c934..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-
-ASSIMILATION_STUDY(Study_name='test017',
-                   Study_repertory='@prefix@/tests/daSalome',
-                   Debug=0,
-                   Algorithm='3DVAR',
-                   Background=_F(INPUT_TYPE='Vector',
-                                 data=_F(FROM='Script',
-                                         SCRIPT_FILE=
-                           'test017_3DVAR_init_data.py',),),
-                   BackgroundError=_F(INPUT_TYPE='Matrix',
-                                      data=_F(FROM='Script',
-                                              SCRIPT_FILE=
-                           'test017_3DVAR_init_data.py',),),
-                   Observation=_F(INPUT_TYPE='Vector',
-                                  data=_F(FROM='Script',
-                                          SCRIPT_FILE=
-                           'test017_3DVAR_init_data.py',),),
-                   ObservationError=_F(INPUT_TYPE='Matrix',
-                                       data=_F(FROM='Script',
-                                               SCRIPT_FILE=
-                           'test017_3DVAR_init_data.py',),),
-                   ObservationOperator=_F(INPUT_TYPE='Function',
-                                          data=_F(FROM='FunctionDict',
-                                                  FUNCTIONDICT_FILE=
-                     'test017_3DVAR_function_script.py',),),
-                   UserPostAnalysis=_F(FROM='String',
-                                       STRING=
-"""import numpy
-dimension = 300
-precision = 1.e-10
-xt = numpy.matrix(numpy.arange(dimension)).T
-xb = Study.getBackground()
-xa = numpy.array(ADD.get("Analysis")[0])
-d  = numpy.array(ADD.get("Innovation")[0])
-#
-# Verification du resultat
-# ------------------------
-if max(abs(xa - (xb+xt.A1)/2)) > precision:
-    raise ValueError("Resultat du test errone (1)")
-else:
-    print "    Test correct, erreur maximale inferieure à %s"%precision
-""",),);
diff --git a/src/tests/daSalome/test017_3DVAR_function_script.py b/src/tests/daSalome/test017_3DVAR_function_script.py
deleted file mode 100644 (file)
index a951798..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-
-print computation
-method = ""
-for param in computation["specificParameters"]:
-  if param["name"] == "method":
-    method = param["value"]
-print "Method found is", method
-
-dimension = 300
-H  = numpy.matrix(numpy.core.identity(dimension))
-
-def FunctionH( X ):
-    return H * X
-
-def AdjointH( (X, Y) ):
-    return H.T * Y
-
-print computation["inputValues"][0][0][0]
-print computation["inputValues"][0][0][0][0]
-
-if method == "Direct":
-  data = FunctionH(numpy.matrix(computation["inputValues"][0][0][0]).T)
-
-if method == "Tangent":
-  data = FunctionH(numpy.matrix(computation["inputValues"][0][0][0]).T)
-
-if method == "Adjoint":
-  data = AdjointH((numpy.matrix(computation["inputValues"][0][0][0]).T, numpy.matrix(computation["inputValues"][0][0][1]).T))
-
-
-outputValues = [[[[]]]]
-it = data.flat
-for val in it:
-  outputValues[0][0][0].append(val)
-
-print outputValues
-
-result = {}
-result["outputValues"] = outputValues
-result["specificOutputInfos"] = []
-result["returnCode"] = 0
-result["errorMessage"] = ""
-
-print result
-print "Computation end"
diff --git a/src/tests/daSalome/test017_3DVAR_init_data.py b/src/tests/daSalome/test017_3DVAR_init_data.py
deleted file mode 100644 (file)
index f5b7177..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-
-numpy.random.seed(1000)
-dimension = 300
-
-xt = numpy.matrix(numpy.arange(dimension)).T
-Eo = numpy.matrix(numpy.zeros((dimension,))).T
-Eb = numpy.matrix(numpy.random.normal(0.,1.,size=(dimension,))).T
-H  = numpy.matrix(numpy.core.identity(dimension))
-B = numpy.matrix(numpy.core.identity(dimension)).T
-R = numpy.matrix(numpy.core.identity(dimension)).T
-
-def FunctionH( X ):
-    return H * X
-
-xb = xt + Eb
-xb = xb.A1
-yo = FunctionH( xt ) + Eo
-yo = yo.A1
-
-Background = xb
-BackgroundError = B
-Observation = yo
-ObservationError = R
diff --git a/src/tests/daSalome/test_aster_zzzz159a_LBFGSB.comm.in b/src/tests/daSalome/test_aster_zzzz159a_LBFGSB.comm.in
deleted file mode 100644 (file)
index e5dcd70..0000000
+++ /dev/null
@@ -1,98 +0,0 @@
-
-ASSIMILATION_STUDY(Study_name='aster_zzzz159a_LBFGSB',
-                   Study_repertory='@prefix@/tests/daSalome',
-                   Debug=0,
-                   Algorithm='3DVAR',
-                   Background=_F(INPUT_TYPE='Vector',
-                                 data=_F(FROM='Script',
-                                         SCRIPT_FILE=
-                            'test_aster_zzzz159a_background.py',),),
-                   BackgroundError=_F(INPUT_TYPE='Matrix',
-                                      data=_F(FROM='Script',
-                                              SCRIPT_FILE=
-                      'test_aster_zzzz159a_background_error.py',),),
-                   Observation=_F(INPUT_TYPE='Vector',
-                                  data=_F(FROM='Script',
-                                          SCRIPT_FILE=
-                           'test_aster_zzzz159a_observation.py',),),
-                   ObservationError=_F(INPUT_TYPE='Matrix',
-                                       data=_F(FROM='Script',
-                                               SCRIPT_FILE=
-                     'test_aster_zzzz159a_observation_error.py',),),
-                   ObservationOperator=_F(INPUT_TYPE='Function',
-                                          data=_F(FROM='FunctionDict',
-                                                  FUNCTIONDICT_FILE=
-                             'test_aster_zzzz159a_functions.py',),),
-                   AlgorithmParameters=_F(INPUT_TYPE='Dict',
-                                          data=_F(FROM='Script',
-                                                  SCRIPT_FILE=
-                 'test_aster_zzzz159a_init_algorithm_LBFGSB.py',),),
-                   UserDataInit=_F(INIT_FILE=
-                       'test_aster_zzzz159a_init_parameters.py',
-                                   TARGET_LIST=
-                                   ('BackgroundError','Observation',
-                                                 'ObservationError','ObservationOperator','AlgorithmParameters',
-                                                 'UserPostAnalysis','Background',),),
-                   UserPostAnalysis=_F(FROM='String',
-                                       STRING=
-"""import numpy
-import os
-xa = ADD.get("Analysis")[0]
-Innovation = ADD.get("Innovation")[0]
-A = []
-J = ADD.get("CostFunctionJ")[:]
-ADD.setDiagnostic("PlotVectors", "J")
-MonPlot = ADD.get("J")
-if os.path.isfile("recherche_xx_Fonctionnelles.ps"):
-  os.remove("recherche_xx_Fonctionnelles.ps")
-MonPlot.calculate([J,ADD.get("CostFunctionJb")[:],ADD.get("CostFunctionJo")[:]],
-    title = "Fonctionnelles J, Jb et Jo",
-    ltitle = ["J","Jb","Jo"],
-    xlabel = "Pas", ylabel = "Valeur",
-    filename = "recherche_xx_Fonctionnelles.ps",
-    pause = False )
-nbmesures = 11 # De 0 vers 1 par pas de 0.1
-instants = numpy.array([0.1*i for i in range(nbmesures)])
-yo = []
-for reponse in init_data['experience']:
-    for t,v in list(reponse):
-        if min(abs(t - instants)) < 1.e-8:
-            yo.append(v)
-xb = []
-Bornes = []
-for parametre in init_data['parametres']:
-    xb.append( parametre[1] )
-    Bornes.append( parametre[2:4] )
-B  = numpy.matrix(numpy.core.identity(len(xb)))
-alpha  = 1.e14
-B[0,0] = alpha * 100
-B[1,1] = alpha * 10
-B[2,2] = alpha * 1
-# Calcul de la RMS
-# ----------------
-import test_aster_zzzz159a_aster_functions as Code_Aster
-Hxa = Code_Aster.Calcul_Aster_Ponctuel( xa )
-V1 = numpy.array(Hxa)
-V2 = numpy.array(yo)
-import math
-rms = math.sqrt( ((V2 - V1)**2).sum() / float(V1.size) )
-print
-print "========="
-print "Ebauche = ",xb
-print "Analyse = ",xa
-print "RMS     = ",rms
-print
-print "NbSteps = ",len(J)
-print "J       = ",J
-print
-print "B[0,0]  = ",B[0,0]
-print "B[1,1]  = ",B[1,1]
-print "B[2,2]  = ",B[2,2]
-print "Bornes  = ",Bornes
-print "========="
-print
-""",),
-                   InputVariables=_F(NAMES=('YOUN__','DSDE__','SIGY__',),
-                                     SIZES=(1,1,1,),),
-                   OutputVariables=_F(NAMES=('REPONSE1','REPONSE2',),
-                                      SIZES=(11,11,),),);
diff --git a/src/tests/daSalome/test_aster_zzzz159a_aster_functions.py b/src/tests/daSalome/test_aster_zzzz159a_aster_functions.py
deleted file mode 100644 (file)
index 4af899c..0000000
+++ /dev/null
@@ -1,560 +0,0 @@
-# -*- coding: iso-8859-1 -*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import os, sys, shutil, tempfile, glob
-from math import log10
-
-# Variables globales
-debug=False
-ASTER_ROOT   = ''
-SOURCES_ROOT = ''
-export = None
-calcul = None
-parametres = None
-python_version = ''
-
-#===============================================================================
-def UTMESS(code='I', txt=''):
-   print txt
-   if code=='F': sys.exit()
-
-#===============================================================================
-def get_tables(tables_calc,tmp_repe_table,prof):
-   """ Recupere les resultats Aster (Table Aster -> Numeric Python)
-   """
-   global debug
-   import Numeric
-   assert (tables_calc is not None)
-   assert (tmp_repe_table is not None)
-
-   # Import du module lire_table
-   if os.environ.has_key('ASTER_ROOT'):
-      version = prof['version'][0]
-      bibpyt = os.path.join(os.environ['ASTER_ROOT'], version, 'bibpyt')
-      sys.path.append(bibpyt)
-      for mdl in glob.glob(os.path.join(bibpyt, '*')):
-        sys.path.append(os.path.join(os.environ['ASTER_ROOT'], version, 'bibpyt', mdl))
-   try:
-      from lire_table_ops import lecture_table
-   except:
-      UTMESS('F', "Impossible d'importer le module lire_table!")
-
-   reponses = tables_calc
-   Lrep=[]
-   _TB = [None]*len(reponses)
-   for i in range(len(reponses)):
-      _fic_table = tmp_repe_table + os.sep + "fort."+str(int(100+i))
-
-      try:
-        file=open(_fic_table,'r')
-        texte=file.read()
-        file.close()
-      except Exception, err:
-        ier=1
-        message = "Erreur 1!\n" + str(err)
-        UTMESS('F', message)
-
-      try:
-        table_lue = lecture_table(texte, 1, ' ')
-        list_para = table_lue.para
-        tab_lue   = table_lue.values()
-      except Exception, err:
-        ier=1
-        message = "Erreur 2!\n" + str(err)
-      else:
-        ier=0
-
-      if ier!=0 : UTMESS('F', message)
-
-      try:
-         nb_val = len(tab_lue[ list_para[0] ])
-         F = Numeric.zeros((nb_val,2), Numeric.Float)
-         for k in range(nb_val):
-           F[k][0] = tab_lue[ str(reponses[i][1]) ][k]
-           F[k][1] = tab_lue[ str(reponses[i][2]) ][k]
-         Lrep.append(F)
-      except Exception, err:
-         message = "Erreur 3!\n" + str(err)
-         UTMESS('F', message)
-   resu_calc = Lrep
-   if debug: print 'resu_calc:', resu_calc
-
-   return resu_calc
-#===============================================================================
-
-
-#===============================================================================
-def Calcul_Aster_Ponctuel( X0 = None ):
-    #
-    global ASTER_ROOT
-    global debug
-    global SOURCES_ROOT
-    global export
-    global calcul
-    global parametres
-    global python_version
-
-    import numpy
-    if type(X0) is type(numpy.matrix([])):
-        X0 = X0.A1.tolist()
-    else:
-        X0 = list(X0)
-    # ----------------------------------------------------------------------------
-    # Parametres
-    #isFromYacs = globals().get('ASTER_ROOT', None)  # execution via YACS ou en externe
-    #isFromYacs = ASTER_ROOT
-    #print "isFromYacs:", isFromYacs
-    #if not isFromYacs:
-    #    from N_Parameters import ASTER_ROOT, debug, SOURCES_ROOT, DISPLAY
-    #    from N_Study_Parameters import export
-    #    from N_MR_Parameters import calcul, parametres
-    os.environ['ASTER_ROOT'] = ASTER_ROOT
-
-    # ----------------------------------------------------------------------------
-    # Repertoire contenant les resultats des calculs Aster (None = un rep temp est cree)
-    resudir = globals().get('resudir', None)
-
-    # ----------------------------------------------------------------------------
-    # Parametres remis en forme
-    list_params = [x[0] for x in parametres]
-    list_calc = calcul
-
-    # ----------------------------------------------------------------------------
-    # Procedure de calculs distribues
-    #
-    # Import des modules python d'ASTK
-    astk_serv_root = os.path.join(ASTER_ROOT, 'ASTK', 'ASTK_SERV')
-    sys.path.append(os.path.join(astk_serv_root, 'lib'))
-    sys.path.append(os.path.join(ASTER_ROOT, 'lib', python_version, 'site-packages'))
-    if debug:
-        print sys.path
-    try:
-      from asrun.run          import AsRunFactory
-      from asrun.profil       import ASTER_PROFIL
-      from asrun.common_func  import get_hostrc
-      from asrun.utils        import get_timeout
-      from asrun.parametric   import is_list_of_dict
-      from asrun.thread       import Dispatcher
-      from asrun.distrib      import DistribParametricTask
-    except Exception, e:
-      print e
-      UTMESS('F', "Impossible de determiner l'emplacement d'Aster ! Fixer le chemin avec la variable d'environnement ASTER_ROOT.")
-
-    # Import des modules supplementaires
-    sys.path.insert(0, SOURCES_ROOT)
-    sys.path.insert(0, os.path.join(SOURCES_ROOT, 'sources'))
-
-
-    # result directories
-    if resudir:
-       if not os.path.isdir(resudir):
-          try:    os.mkdir(resudir)
-          except: 
-             UTMESS('A', "Impossible de creer le repertoire : %s. On utilise un repertoire temporaire" % resudir)
-             resudir = None
-    if not resudir: resudir = tempfile.mkdtemp(prefix='tmp_macr_recal_')
-    flashdir = os.path.join(resudir,'flash')
-    UTMESS('I', "\n       ASTER Exécution simple\n       Répertoire temporaire de résultats : %s" % resudir)
-
-    sys.argv = ['']
-
-    run = AsRunFactory()
-
-    prof = ASTER_PROFIL(filename=export)
-    #prof = init_profil_from(run, prof, keep_surch=True)
-    prof.Set('R', {
-       'type' : 'repe', 'isrep' : True, 'ul' : 0, 'compr' : False,
-       'path' : '/tmp/test_param' })
-
-    if debug: print prof
-    prof.WriteExportTo( os.path.join(resudir, 'master.export') )
-
-    # get hostrc object
-    hostrc = get_hostrc(run, prof)
-
-    # timeout before rejected a job
-    timeout = get_timeout(prof)
-
-
-    # list of parameters
-    list_val = []
-
-    # Dictionnaire des parametres du point courant
-    dic = dict( zip( list_params, X0 ) )
-    list_val.append( dic )
-
-    assert is_list_of_dict(list_val)
-    nbval = len(list_val)
-
-
-    # Ajout des impressions de tables a la fin du .comm
-    t = []
-    reponses = list_calc
-    for i in range(len(reponses)):
-        _ul = str(int(100+i))
-        num_ul = '99'
-
-        try:    os.remove( tmp_macr_recal+os.sep+"REPE_TABLE"+os.sep+"fort."+_ul )
-        except: pass
-
-        t.append("\n# Recuperation de la table : " + str(reponses[i][0]) + "\n")
-        t.append("DEFI_FICHIER(UNITE=" + num_ul + ", FICHIER='" + os.path.join('.', 'REPE_OUT', 'fort.'+_ul) + "',);\n" )
-        t.append("IMPR_TABLE(TABLE="+str(reponses[i][0])+", FORMAT='ASTER', UNITE="+num_ul+", INFO=1, FORMAT_R='E30.20',);\n")
-        t.append("DEFI_FICHIER(ACTION='LIBERER', UNITE="+num_ul+",);\n")
-
-
-    # number of threads to follow execution
-    numthread = 1
-
-    # ----- Execute calcutions in parallel using a Dispatcher object
-    # elementary task...
-    task = DistribParametricTask(run=run, prof=prof, # IN
-                      hostrc=hostrc,
-                      nbmaxitem=0, timeout=timeout,
-                      resudir=resudir, flashdir=flashdir,
-                      keywords={'POST_CALCUL': '\n'.join(t)},
-                      info=1,
-                      nbnook=0, exec_result=[])            # OUT
-    # ... and dispatch task on 'list_tests'
-    etiq = 'calc_%%0%dd' % (int(log10(nbval)) + 1)
-    labels = [etiq % (i+1) for i in range(nbval)]
-    couples = zip(labels, list_val)
-    execution = Dispatcher(couples, task, numthread=numthread)
-
-    iret = 0
-    if task.nbnook > 0:
-        iret = 4
-    #run.Sortie(iret)
-
-    # Recuperation des tables calculees
-    seq_FX   = []
-    seq_FY   = []
-    seq_DIMS = []
-    lst_DIAG = []
-    lst_iter = []
-    i=0
-    for c in labels:
-        tbl = get_tables(tables_calc=list_calc, tmp_repe_table=os.path.join(resudir, c, 'REPE_OUT'), prof=prof)
-        FX = []
-        FY = []
-        ldims = []
-        for array in tbl:
-#           print 'AA1:', array
-#           print array[0]
-            FX.extend([ x[0] for x in array ])
-            FY.extend([ x[1] for x in array ])
-            ldims.append(len(array))
-
-        # Agregation des resultats
-        seq_FX.append(FX)
-        seq_FY.append(FY)
-        seq_DIMS.append(ldims)
-        lst_iter.append(i)
-        i+=1
-
-    # Liste des diagnostics
-    d_diag = {}
-    for result in task.exec_result:
-        label = result[0]
-        diag  = result[2]
-        d_diag[label] = diag
-    lst_DIAG = [ d_diag[label] for label in labels]
-
-    if debug:
-        print
-        print "list_calc =",list_calc
-        print "seq_FX    =",seq_FX
-        print "seq_FY    =",seq_FY
-        print "seq_DIMS  =",seq_DIMS
-        print "lst_DIAG  =",lst_DIAG
-        print "lst_iter  =",lst_iter
-        print
-
-    # ----------------------------------------------------------------------------
-    # Procedure d'assemblage du gradient
-
-    # Calcul maitre (point X0)
-    idx0 = lst_iter.index(0)   # index (les calculs arrivent-ils dans le desordre?)
-    FY_X0 = seq_FY[idx0]
-    H_de_X = FY_X0
-
-    # Arret si tous les jobs ne se sont pas deroules correctement
-    for diag in lst_DIAG:
-        if not diag[0:2] in ['OK', '<A']:
-            raise ValueError("Au moins un calcul ne s'est pas deroule normalement")
-
-    if debug:
-        print "\nH_de_X (calcul ponstuel) au point X0: \n%s" % str(H_de_X)
-
-    return H_de_X
-
-#===============================================================================
-def Calcul_Aster_Jacobienne( X0 = None ):
-    global ASTER_ROOT
-    global debug
-    global SOURCES_ROOT
-    global export
-    global calcul
-    global parametres
-    global python_version
-    #
-    import numpy
-    if type(X0) is type(numpy.matrix([])):
-        X0 = X0.A1.tolist()
-    else:
-        X0 = list(X0)
-    # ----------------------------------------------------------------------------
-    FacteurdX = 1.e-4
-    dX = globals().get('dX', [ x*FacteurdX for x in X0 ])  # execution via YACS ou en externe
-    # dX = globals().get('dX', [ 0.1, 0.1, 0.001])  # execution via YACS ou en externe
-    # ----------------------------------------------------------------------------
-    # Parametres
-    #isFromYacs = globals().get('ASTER_ROOT', None)  # execution via YACS ou en externe
-    #if not isFromYacs:
-    #    from N_Parameters import ASTER_ROOT, debug, SOURCES_ROOT, DISPLAY
-    #    from N_Study_Parameters import export
-    #    from N_MR_Parameters import calcul, parametres
-    os.environ['ASTER_ROOT'] = ASTER_ROOT
-
-    # ----------------------------------------------------------------------------
-    # Repertoire contenant les resultats des calculs Aster (None = un rep temp est cree)
-    resudir = globals().get('resudir', None)
-
-    # ----------------------------------------------------------------------------
-    # Parametres remis en forme
-    list_params = [x[0] for x in parametres]
-    list_calc = calcul
-
-    # ----------------------------------------------------------------------------
-    # Procedure de calculs distribues
-    #
-    # Import des modules python d'ASTK
-    astk_serv_root = os.path.join(ASTER_ROOT, 'ASTK', 'ASTK_SERV')
-    sys.path.append(os.path.join(astk_serv_root, 'lib'))
-    sys.path.append(os.path.join(ASTER_ROOT, 'lib', python_version, 'site-packages'))
-    if debug:
-        print sys.path
-    try:
-      from asrun.run          import AsRunFactory
-      from asrun.profil       import ASTER_PROFIL
-      from asrun.common_func  import get_hostrc
-      from asrun.utils        import get_timeout
-      from asrun.parametric   import is_list_of_dict
-      from asrun.thread       import Dispatcher
-      from asrun.distrib      import DistribParametricTask
-    except Exception, e:
-      print e
-      UTMESS('F', "Impossible de determiner l'emplacement d'Aster ! Fixer le chemin avec la variable d'environnement ASTER_ROOT.")
-
-    # Import des modules supplementaires
-    sys.path.insert(0, SOURCES_ROOT)
-    sys.path.insert(0, os.path.join(SOURCES_ROOT, 'sources'))
-
-
-    # result directories
-    if resudir:
-       if not os.path.isdir(resudir):
-          try:    os.mkdir(resudir)
-          except: 
-             UTMESS('A', "Impossible de creer le repertoire : %s. On utilise un repertoire temporaire" % resudir)
-             resudir = None
-    if not resudir: resudir = tempfile.mkdtemp(prefix='tmp_macr_recal_')
-    flashdir = os.path.join(resudir,'flash')
-    UTMESS('I', "\n       ASTER Exécutions multiples\n       Répertoire temporaire de résultats : %s" % resudir)
-
-    sys.argv = ['']
-
-    run = AsRunFactory()
-
-    prof = ASTER_PROFIL(filename=export)
-    #prof = init_profil_from(run, prof, keep_surch=True)
-    prof.Set('R', {
-       'type' : 'repe', 'isrep' : True, 'ul' : 0, 'compr' : False,
-       'path' : '/tmp/test_param' })
-
-    if debug: print prof
-    prof.WriteExportTo( os.path.join(resudir, 'master.export') )
-
-    # get hostrc object
-    hostrc = get_hostrc(run, prof)
-
-    # timeout before rejected a job
-    timeout = get_timeout(prof)
-
-
-    # list of parameters
-    list_val = []
-
-    # Dictionnaire des parametres du point courant
-    dic = dict( zip( list_params, X0 ) )
-    list_val.append( dic )
-
-    # Dictionnaires des parametres des calculs esclaves (perturbations des differences finies)
-    for n in range(1,len(dX)+1):
-        l = [0] * len(dX)
-        l[n-1] = dX[n-1]
-        X = [ X0[i] + l[i] for i in range(len(dX)) ]
-        dic = dict( zip( list_params, X ) )
-        list_val.append( dic )
-
-    assert is_list_of_dict(list_val)
-    nbval = len(list_val)
-
-
-    # Ajout des impressions de tables a la fin du .comm
-    t = []
-    reponses = list_calc
-    for i in range(len(reponses)):
-        _ul = str(int(100+i))
-        num_ul = '99'
-
-        try:    os.remove( tmp_macr_recal+os.sep+"REPE_TABLE"+os.sep+"fort."+_ul )
-        except: pass
-
-        t.append("\n# Recuperation de la table : " + str(reponses[i][0]) + "\n")
-        t.append("DEFI_FICHIER(UNITE=" + num_ul + ", FICHIER='" + os.path.join('.', 'REPE_OUT', 'fort.'+_ul) + "',);\n" )
-        t.append("IMPR_TABLE(TABLE="+str(reponses[i][0])+", FORMAT='ASTER', UNITE="+num_ul+", INFO=1, FORMAT_R='E30.20',);\n")
-        t.append("DEFI_FICHIER(ACTION='LIBERER', UNITE="+num_ul+",);\n")
-
-
-    # number of threads to follow execution
-    numthread = 1
-
-    # ----- Execute calcutions in parallel using a Dispatcher object
-    # elementary task...
-    task = DistribParametricTask(run=run, prof=prof, # IN
-                      hostrc=hostrc,
-                      nbmaxitem=0, timeout=timeout,
-                      resudir=resudir, flashdir=flashdir,
-                      keywords={'POST_CALCUL': '\n'.join(t)},
-                      info=1,
-                      nbnook=0, exec_result=[])            # OUT
-    # ... and dispatch task on 'list_tests'
-    etiq = 'calc_%%0%dd' % (int(log10(nbval)) + 1)
-    labels = [etiq % (i+1) for i in range(nbval)]
-    couples = zip(labels, list_val)
-    execution = Dispatcher(couples, task, numthread=numthread)
-
-    iret = 0
-    if task.nbnook > 0:
-        iret = 4
-    #run.Sortie(iret)
-
-    # Recuperation des tables calculees
-    seq_FX   = []
-    seq_FY   = []
-    seq_DIMS = []
-    lst_DIAG = []
-    lst_iter = []
-    i=0
-    for c in labels:
-        tbl = get_tables(tables_calc=list_calc, tmp_repe_table=os.path.join(resudir, c, 'REPE_OUT'), prof=prof)
-        FX = []
-        FY = []
-        ldims = []
-        for array in tbl:
-#           print 'AA1:', array
-#           print array[0]
-            FX.extend([ x[0] for x in array ])
-            FY.extend([ x[1] for x in array ])
-            ldims.append(len(array))
-
-        # Agregation des resultats
-        seq_FX.append(FX)
-        seq_FY.append(FY)
-        seq_DIMS.append(ldims)
-        lst_iter.append(i)
-        i+=1
-
-    # Liste des diagnostics
-    d_diag = {}
-    for result in task.exec_result:
-        label = result[0]
-        diag  = result[2]
-        d_diag[label] = diag
-    lst_DIAG = [ d_diag[label] for label in labels]
-
-    if debug:
-        print
-        print "list_calc =",list_calc
-        print "seq_FX    =",seq_FX
-        print "seq_FY    =",seq_FY
-        print "seq_DIMS  =",seq_DIMS
-        print "lst_DIAG  =",lst_DIAG
-        print "lst_iter  =",lst_iter
-        print "dX        =",dX
-        print
-
-    # ----------------------------------------------------------------------------
-    # Procedure d'assemblage du gradient
-
-    # Calcul maitre (point X0)
-    idx0 = lst_iter.index(0)   # index (les calculs arrivent-ils dans le desordre?)
-    FY_X0 = seq_FY[idx0]
-    H_de_X = FY_X0
-
-    # Arret si tous les jobs ne se sont pas deroules correctement
-    for diag in lst_DIAG:
-        if not diag[0:2] in ['OK', '<A']:
-            raise ValueError("Au moins un calcul ne s'est pas deroule normalement")
-
-    # Calcul du gradient (une liste de liste)
-    Gradient_de_H_en_X = []
-
-    for n in range(len(lst_iter))[1:]:
-        idx = lst_iter.index(n)
-        FY   = seq_FY[idx]
-        col = [ -(y-x)/dX[idx-1] for x, y in zip(FY, FY_X0) ]
-        Gradient_de_H_en_X.append(col)
-        if debug: print 'Calcul numero: %s - Diagnostic: %s' % (n, lst_DIAG[idx])
-
-    if debug:
-        print "\nCalcul H au point X0: \n%s" % str(H_de_X)
-        import pprint
-        print "\nGradient au point X0:"
-        pprint.pprint(Gradient_de_H_en_X)
-
-    return Gradient_de_H_en_X
-
-#===============================================================================
-def Calcul_Aster_Adjoint( (X0, dY) ):
-    #
-    if 0:
-        print
-        print "CALCUL ADJOINT"
-        print "X0 =",X0
-        print "dY =",dY
-    #
-    import numpy
-    #
-    Y0 = numpy.asmatrix(dY).flatten().T
-    #
-    Delta_HX = Calcul_Aster_Jacobienne( X0 )
-    Delta_HX = numpy.matrix( Delta_HX )
-    #
-    HtY = numpy.dot(Delta_HX, Y0)
-    #
-    if 0:
-        print "dHX =",Delta_HX
-        print "HtY =",HtY
-        print
-    #
-    return HtY.A1
diff --git a/src/tests/daSalome/test_aster_zzzz159a_background.py b/src/tests/daSalome/test_aster_zzzz159a_background.py
deleted file mode 100644 (file)
index 7411c67..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-debug = init_data["debug"]
-parametres = init_data["parametres"]
-
-xb = []
-Bornes = []
-for parametre in parametres:
-    xb.append( parametre[1] )
-if debug:
-    print
-    print "Ebauche = ",xb
-    print
-
-Background = xb
diff --git a/src/tests/daSalome/test_aster_zzzz159a_background_error.py b/src/tests/daSalome/test_aster_zzzz159a_background_error.py
deleted file mode 100644 (file)
index 6d95a05..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-parametres = init_data["parametres"]
-
-xb = []
-for parametre in parametres:
-    xb.append( parametre[1] )
-
-B  = numpy.matrix(numpy.core.identity(len(xb)))
-alpha  = 1.e14
-B[0,0] = alpha * 100
-B[1,1] = alpha * 10
-B[2,2] = alpha * 1
-dimensionXb = len( xb )
-B = numpy.matrix( B, numpy.float ).reshape((dimensionXb,dimensionXb))
-
-BackgroundError = B
diff --git a/src/tests/daSalome/test_aster_zzzz159a_functions.py b/src/tests/daSalome/test_aster_zzzz159a_functions.py
deleted file mode 100644 (file)
index b6ed93f..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-import sys
-
-sys.path.insert(0, init_data['SOURCES_ROOT'])
-import test_aster_zzzz159a_aster_functions as Code_Aster
-
-# Configuration du module
-Code_Aster.debug = init_data["debug"]
-Code_Aster.ASTER_ROOT = init_data["ASTER_ROOT"]
-Code_Aster.SOURCES_ROOT = init_data['SOURCES_ROOT']
-Code_Aster.export = init_data["export"]
-Code_Aster.calcul = init_data["calcul"]
-Code_Aster.parametres = init_data["parametres"]
-Code_Aster.python_version = init_data["python_version"]
-
-print computation
-method = ""
-for param in computation["specificParameters"]:
-  if param["name"] == "method":
-    method = param["value"]
-
-# Extraction des données et remise en forme (normalement à faire
-# dans le code
-# On sait qu'on a trois variables
-input_data = []
-for i in range(3):
-  input_data.append(computation["inputValues"][0][0][i][0])
-
-if method == "Adjoint":
-  input_data = (input_data, [])
-  for i in range(22):
-    if i < 11:
-      input_data[1].append(computation["inputValues"][0][0][3][i])
-    else:
-      input_data[1].append(computation["inputValues"][0][0][4][i-11])
-
-result = {}
-result["specificOutputInfos"] = []
-result["returnCode"] = 0
-result["errorMessage"] = ""
-
-outputValues = [[[[]]]]
-if method == "Direct":
-  output_data = Code_Aster.Calcul_Aster_Ponctuel(input_data)
-  outputValues[0][0] = [[],[]]
-  for i in range(22):
-    if i < 11:
-      outputValues[0][0][0].append(output_data[i])
-    else:
-      outputValues[0][0][1].append(output_data[i])
-
-if method == "Tangent":
-  output_data = Code_Aster.Calcul_Aster_Ponctuel(input_data)
-  outputValues[0][0] = [[],[]]
-  for i in range(22):
-    if i < 11:
-      outputValues[0][0][0].append(output_data[i])
-    else:
-      outputValues[0][0][1].append(output_data[i])
-
-if method == "Adjoint":
-  output_data = Code_Aster.Calcul_Aster_Adjoint(input_data)
-  outputValues[0][0] = [[],[],[]]
-  outputValues[0][0][0].append(output_data[0])
-  outputValues[0][0][1].append(output_data[1])
-  outputValues[0][0][2].append(output_data[2])
-
-result["outputValues"] = outputValues
-
-print "Computation end"
diff --git a/src/tests/daSalome/test_aster_zzzz159a_init_algorithm.py b/src/tests/daSalome/test_aster_zzzz159a_init_algorithm.py
deleted file mode 100644 (file)
index d0f8927..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-debug = init_data["debug"]
-parametres = init_data["parametres"]
-
-Bornes = []
-for parametre in parametres:
-    Bornes.append(parametre[2:4])
-
-if debug:
-    print
-    print "Bornes  = ",Bornes
-    print
-
-AlgorithmParameters = { "Minimizer"           : "TNC",
-    "Bounds"              : Bornes,
-    }
diff --git a/src/tests/daSalome/test_aster_zzzz159a_init_algorithm_LBFGSB.py b/src/tests/daSalome/test_aster_zzzz159a_init_algorithm_LBFGSB.py
deleted file mode 100644 (file)
index 2190fdb..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-debug = init_data["debug"]
-parametres = init_data["parametres"]
-
-Bornes = []
-for parametre in parametres:
-    Bornes.append(parametre[2:4])
-
-if debug:
-    print
-    print "Bornes  = ",Bornes
-    print
-
-AlgorithmParameters = { "Minimizer"           : "LBFSGB",
-    "Bounds"              : Bornes,
-    }
diff --git a/src/tests/daSalome/test_aster_zzzz159a_init_parameters.py.in b/src/tests/daSalome/test_aster_zzzz159a_init_parameters.py.in
deleted file mode 100644 (file)
index d609476..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-# -*- coding: iso-8859-1 -*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import os
-
-# Ce script contient les information nécessaires à l'exécution
-# de l'étude
-
-init_data = {}
-
-# Variables de base
-init_data['ASTER_ROOT'] = os.environ['ASTER_ROOT']
-init_data['debug'] = False
-init_data['python_version'] = "python@PYTHON_VERSION@"
-init_data['SOURCES_ROOT'] = "@prefix@" + '/tests/daSalome'
-
-# Partie contenant les parametres de l'étude
-init_data['export'] = "@prefix@" + '/tests/daSalome/zzzz159a.export.esclave'
-
-import Numeric
-parametres =[['YOUN__',100000.,50000.,500000.],['DSDE__',1000.,500.,10000.],['SIGY__',30.,5.,500.]]
-calcul = [['REPONSE1','INST','SIYY'],['REPONSE2','INST','V1']]
-experience=[     Numeric.array([[0.00000E+00  , 0.00000E+00 ],
-                              [5.00000E-02  , 5.00000E+01 ],
-                              [1.00000E-01  , 1.00000E+02 ],
-                              [1.50000E-01  , 1.50000E+02 ],
-                              [2.00000E-01  , 2.00000E+02 ],
-                              [2.50000E-01  , 2.00500E+02 ],
-                              [3.00000E-01  , 2.01000E+02 ],
-                              [3.50000E-01  , 2.01500E+02 ],
-                              [4.00000E-01  , 2.02000E+02 ],
-                              [4.50000E-01  , 2.02500E+02 ],
-                              [5.00000E-01  , 2.03000E+02 ],
-                              [5.50000E-01  , 2.03500E+02 ],
-                              [6.00000E-01  , 2.04000E+02 ],
-                              [6.50000E-01  , 2.04500E+02 ],
-                              [7.00000E-01  , 2.05000E+02 ],
-                              [7.50000E-01  , 2.05500E+02 ],
-                              [8.00000E-01  , 2.06000E+02 ],
-                              [8.50000E-01  , 2.06500E+02 ],
-                              [9.00000E-01  , 2.07000E+02 ],
-                              [9.50000E-01  , 2.07500E+02 ],
-                              [1.00000E+00  , 2.08000E+02 ]]),
-                 Numeric.array([[0.00000E+00  , 0.00000E+00 ],
-                              [5.00000E-02  , 0.00000E+00 ],
-                              [1.00000E-01  , 0.00000E+00 ],
-                              [1.50000E-01  , 0.00000E+00 ],
-                              [2.00000E-01  , 0.00000E+00 ],
-                              [2.50000E-01  , 2.47500E-04 ],
-                              [3.00000E-01  , 4.95000E-04 ],
-                              [3.50000E-01  , 7.42500E-04 ],
-                              [4.00000E-01  , 9.90000E-04 ],
-                              [4.50000E-01  , 1.23750E-03 ],
-                              [5.00000E-01  , 1.48500E-03 ],
-                              [5.50000E-01  , 1.73250E-03 ],
-                              [6.00000E-01  , 1.98000E-03 ],
-                              [6.50000E-01  , 2.22750E-03 ],
-                              [7.00000E-01  , 2.47500E-03 ],
-                              [7.50000E-01  , 2.72250E-03 ],
-                              [8.00000E-01  , 2.97000E-03 ],
-                              [8.50000E-01  , 3.21750E-03 ],
-                              [9.00000E-01  , 3.46500E-03 ],
-                              [9.50000E-01  , 3.71250E-03 ],
-                              [1.00000E+00  , 3.96000E-03 ]]) ]
-
-init_data['parametres'] = parametres
-init_data['calcul'] = calcul
-init_data['experience'] = experience
-
diff --git a/src/tests/daSalome/test_aster_zzzz159a_observation.py b/src/tests/daSalome/test_aster_zzzz159a_observation.py
deleted file mode 100644 (file)
index 675c0ce..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-debug = init_data["debug"]
-experience = init_data["experience"]
-
-nbmesures = 11 # De 0 à 1 par pas de 0.1
-instants = numpy.array([0.1*i for i in range(nbmesures)])
-yo = []
-for reponse in experience:
-    for t,v in list(reponse):
-        if min(abs(t - instants)) < 1.e-8:
-            yo.append(v)
-            # print t,'===>',v
-if debug:
-    print "Observations = ",yo
-    print
-
-Observation = yo
diff --git a/src/tests/daSalome/test_aster_zzzz159a_observation_error.py b/src/tests/daSalome/test_aster_zzzz159a_observation_error.py
deleted file mode 100644 (file)
index 3b8954c..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-#-*-coding:iso-8859-1-*-
-# Copyright (C) 2010-2013 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
-# License as published by the Free Software Foundation; either
-# version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public
-# License along with this library; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
-#
-# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-#
-# Author: André Ribes, andre.ribes@edf.fr, EDF R&D
-
-import numpy
-experience = init_data["experience"]
-nbmesures = 11 # De 0 à 1 par pas de 0.1
-instants = numpy.array([0.1*i for i in range(nbmesures)])
-yo = []
-for reponse in experience:
-    for t,v in list(reponse):
-        if min(abs(t - instants)) < 1.e-8:
-            yo.append(v)
-
-R  = numpy.matrix(numpy.core.identity(len(yo)))
-dimensionYo = len( yo )
-R = numpy.matrix( R, numpy.float ).reshape((dimensionYo,dimensionYo))
-
-ObservationError = R
diff --git a/src/tests/daSalome/zzzz159a.3 b/src/tests/daSalome/zzzz159a.3
deleted file mode 100644 (file)
index d591cf1..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-DEBUT();
-
-DSDE__ = 200.;
-
-YOUN__ = 8.E4;
-
-SIGY__ = 1.;
-
-MA=LIRE_MAILLAGE();
-
-MA=DEFI_GROUP(reuse =MA,
-              MAILLAGE=MA,
-              CREA_GROUP_NO=_F(TOUT_GROUP_MA='OUI',),);
-
-
-ACIER=DEFI_MATERIAU(ECRO_LINE=_F(D_SIGM_EPSI=DSDE__,
-                                 SY=SIGY__,),
-                    ELAS=_F(NU=0.3,
-                            E=YOUN__,),);
-
-CHMAT=AFFE_MATERIAU(AFFE=_F(MATER=ACIER,
-                            TOUT='OUI',),
-                    MAILLAGE=MA,);
-
-MO=AFFE_MODELE(AFFE=_F(TOUT='OUI',
-                       PHENOMENE='MECANIQUE',
-                       MODELISATION='AXIS',),
-               MAILLAGE=MA,);
-
-TRACTION=AFFE_CHAR_MECA(DDL_IMPO=(_F(DY=5.E-3,
-                                     GROUP_NO='CD',),
-                                  _F(DY=0.0,
-                                     GROUP_NO='AB',),),
-                        MODELE=MO,);
-
-
-RAMPE=DEFI_FONCTION(NOM_PARA='INST',
-                    VALE=(0.0,0.0,1.0,1.0),);
-
-INSTANTS=DEFI_LIST_REEL(INTERVALLE=_F(JUSQU_A=1.0,
-                                      NOMBRE=10,),
-                        DEBUT=0.0,);
-
-EVOL=STAT_NON_LINE(CHAM_MATER=CHMAT,
-                   MODELE=MO,
-                   ARCHIVAGE=_F(LIST_INST=INSTANTS,
-                                ARCH_ETAT_INIT='OUI',),
-                   CONVERGENCE=_F(ITER_GLOB_MAXI=10,
-                                  RESI_GLOB_RELA=1.E-05,),
-                   COMP_INCR=_F(RELATION='VMIS_ISOT_LINE',),
-                   INCREMENT=_F(LIST_INST=INSTANTS,
-#                                SUBD_METHODE='UNIFORME',
-#                                SUBD_PAS=4,
-#                                SUBD_COEF_PAS_1=1.0,
-#                                SUBD_PAS_MINI=1.E-05,
-                                ),
-                   NEWTON=_F(REAC_ITER=1,
-                             REAC_INCR=1,),
-                   EXCIT=_F(CHARGE=TRACTION,
-                            FONC_MULT=RAMPE,),);
-
-EVOL=CALC_ELEM(reuse =EVOL,
-               RESULTAT=EVOL,
-               CHAM_MATER=CHMAT,
-               MODELE=MO,
-               OPTION=('SIEF_ELNO_ELGA','VARI_ELNO_ELGA'),);
-               
-REPONSE1=POST_RELEVE_T(ACTION=_F(OPERATION='EXTRACTION',
-                        INTITULE='SIGYY',
-                        RESULTAT =EVOL,
-                        NOM_CHAM ='SIEF_ELNO_ELGA',
-                        NOM_CMP  = 'SIYY',
-                        GROUP_NO = 'A',),);
-                        
-REPONSE2=POST_RELEVE_T(ACTION=_F(OPERATION='EXTRACTION',
-                        INTITULE='V1',
-                        RESULTAT =EVOL,
-                        NOM_CHAM ='VARI_ELNO_ELGA',
-                        NOM_CMP  = 'V1',
-                        GROUP_NO = 'A',),);
-                        
-
-FIN();
diff --git a/src/tests/daSalome/zzzz159a.export.esclave.in b/src/tests/daSalome/zzzz159a.export.esclave.in
deleted file mode 100644 (file)
index 5db5b97..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-P version STA10.1
-P debug nodebug
-P mode interactif
-P nomjob zzzz159a
-P origine ASTK 1.8.0
-A memjeveux 16.0
-A tpmax 300
-P tpsjob 5
-P xterm /usr/bin/xterm -sb -si -geometry 90x32 -display localhost:0
-F comm @prefix@/tests/daSalome/zzzz159a.3 D 1
-F mail @prefix@/tests/daSalome/zzzz159a.mail D 20
-F mess @prefix@/tests/daSalome/zzzz159a_esclave.mess R 6
-F resu @prefix@/tests/daSalome/zzzz159a_esclave.resu R 8
-P actions make_etude
diff --git a/src/tests/daSalome/zzzz159a.mail b/src/tests/daSalome/zzzz159a.mail
deleted file mode 100644 (file)
index 83696f9..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-TITRE
- %  GIBI FECIT
- FINSF
- %
- COOR_2D
- N1        0.00000000000000E+00  0.00000000000000E+00
- N2        1.00000000000000E+00  0.00000000000000E+00
- N3        1.00000000000000E+00  1.00000000000000E+00
- N4        0.00000000000000E+00  1.00000000000000E+00
- FINSF
- %
- QUAD4   
-  M1      N1       N2       N3       N4      
- FINSF
- %
- SEG2    
-  M2      N4       N1      
-  M3      N1       N2      
-  M4      N2       N3      
-  M5      N3       N4      
- FINSF
- %
- GROUP_NO
- D        N4      
- FINSF
- %
- GROUP_NO
- C        N3      
- FINSF
- %
- GROUP_NO
- A        N1      
- FINSF
- %
- GROUP_NO
- B        N2      
- FINSF
- %
- GROUP_MA
-   AB      
- M3      
- FINSF
- %
- GROUP_MA
-   BC      
- M4      
- FINSF
- %
- GROUP_MA
-   CD      
- M5      
- FINSF
- %
- GROUP_MA
-   DA      
- M2      
- FINSF
- %
- GROUP_MA
-   MA      
- M1      
- M2       M3       M4       M5      
- FINSF
- %
- FIN