From 334fab848685e5fcf521fcb1519d4d471704cd69 Mon Sep 17 00:00:00 2001 From: Eric Fayolle Date: Fri, 24 Jun 2022 15:11:48 +0200 Subject: [PATCH] Correction generateur UQ pour Taylor & core_elements_vs_dklib optionel --- ReacteurNumerique/cata_RN_EDG.py | 2 +- generator/generator_UQ.py | 23 ++++++++++++----------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/ReacteurNumerique/cata_RN_EDG.py b/ReacteurNumerique/cata_RN_EDG.py index 3e5ddc3a..a151ae30 100644 --- a/ReacteurNumerique/cata_RN_EDG.py +++ b/ReacteurNumerique/cata_RN_EDG.py @@ -607,7 +607,7 @@ Model_data = OPER( "sous la forme (assemblage combustible, DKLib)"), ang=("Association between the core elements and the neutronic libraries " "in the form (fuel assembly, DKLib)"), - statut="o", + statut="f", typ=Tuple(2), # TODO: Check if the attribute assembly_type of the # Assembly object is 'REF' then the type of the diff --git a/generator/generator_UQ.py b/generator/generator_UQ.py index 5e1f7476..d030c460 100644 --- a/generator/generator_UQ.py +++ b/generator/generator_UQ.py @@ -157,17 +157,18 @@ class UQGenerator(PythonGenerator): sectionPropagation = etapeIncertitude.getChildOrChildInBloc('Propagation')[0] self.Methode = sectionPropagation.getChildOrChildInBloc('Methode').valeur self.Result = sectionPropagation.getChildOrChildInBloc('Result')[0] - self.critereArret = sectionPropagation.getChildOrChildInBloc('CritereArret')[0] - # self.SimulationsNumber = self.critereArret.getChildOrChildInBloc('SimulationsNumber')[0] - # self.MaximumElapsedTime = self.critereArret.getChildOrChildInBloc('MaximumElapsedTime')[0] - # self.Accuracy = self.critereArret.getChildOrChildInBloc('Accuracy')[0] - sectionEvaluationParameter = sectionPropagation.getChildOrChildInBloc('EvaluationParameter')[0] - self.Blocksize = sectionEvaluationParameter.getChildOrChildInBloc('BlockSize').valeur - self.advancedParameter = sectionPropagation.getChildOrChildInBloc('AdvancedParameter') - if self.advancedParameter != None: - self.advancedParameter = self.advancedParameter[0] - # self.ComputeConfidenceIntervalAt = self.advancedParameter.getChildOrChildInBloc('ComputeConfidenceIntervalAt')[0] - # self.Seed = self.advancedParameter.getChildOrChildInBloc('Seed')[0] + if (self.Methode == 'MonteCarlo'): + self.critereArret = sectionPropagation.getChildOrChildInBloc('CritereArret')[0] + # self.SimulationsNumber = self.critereArret.getChildOrChildInBloc('SimulationsNumber')[0] + # self.MaximumElapsedTime = self.critereArret.getChildOrChildInBloc('MaximumElapsedTime')[0] + # self.Accuracy = self.critereArret.getChildOrChildInBloc('Accuracy')[0] + sectionEvaluationParameter = sectionPropagation.getChildOrChildInBloc('EvaluationParameter')[0] + self.Blocksize = sectionEvaluationParameter.getChildOrChildInBloc('BlockSize').valeur + self.advancedParameter = sectionPropagation.getChildOrChildInBloc('AdvancedParameter') + if self.advancedParameter != None: + self.advancedParameter = self.advancedParameter[0] + # self.ComputeConfidenceIntervalAt = self.advancedParameter.getChildOrChildInBloc('ComputeConfidenceIntervalAt')[0] + # self.Seed = self.advancedParameter.getChildOrChildInBloc('Seed')[0] self.lesVariablesOutput = sectionOutput.getChildOrChildInBloc('VariableDeSortie') self.variablesOutput = {} -- 2.39.2