From 760c87e31abad957c2e51ab4abc0d9fe0fa16742 Mon Sep 17 00:00:00 2001 From: Jean-Philippe ARGAUD Date: Mon, 13 Apr 2020 18:33:45 +0200 Subject: [PATCH] Improvements for classification of algorithms extended to all --- src/daComposant/daAlgorithms/3DVAR.py | 5 +++++ src/daComposant/daAlgorithms/4DVAR.py | 6 ++++++ src/daComposant/daAlgorithms/DerivativeFreeOptimization.py | 5 +++++ src/daComposant/daAlgorithms/DifferentialEvolution.py | 6 ++++++ src/daComposant/daAlgorithms/EnsembleBlue.py | 6 ++++++ src/daComposant/daAlgorithms/EnsembleKalmanFilter.py | 7 +++++++ src/daComposant/daAlgorithms/ExtendedBlue.py | 5 +++++ src/daComposant/daAlgorithms/ExtendedKalmanFilter.py | 6 ++++++ src/daComposant/daAlgorithms/FunctionTest.py | 3 +++ src/daComposant/daAlgorithms/GradientTest.py | 3 +++ src/daComposant/daAlgorithms/InputValuesTest.py | 3 +++ src/daComposant/daAlgorithms/KalmanFilter.py | 6 ++++++ src/daComposant/daAlgorithms/LinearityTest.py | 3 +++ src/daComposant/daAlgorithms/LocalSensitivityTest.py | 3 +++ src/daComposant/daAlgorithms/ObserverTest.py | 3 +++ src/daComposant/daAlgorithms/ParallelFunctionTest.py | 3 +++ src/daComposant/daAlgorithms/ParticleSwarmOptimization.py | 5 +++++ src/daComposant/daAlgorithms/QuantileRegression.py | 5 +++++ src/daComposant/daAlgorithms/SamplingTest.py | 3 +++ src/daComposant/daAlgorithms/TabuSearch.py | 5 +++++ src/daComposant/daAlgorithms/TangentTest.py | 3 +++ src/daComposant/daAlgorithms/UnscentedKalmanFilter.py | 7 +++++++ 22 files changed, 101 insertions(+) diff --git a/src/daComposant/daAlgorithms/3DVAR.py b/src/daComposant/daAlgorithms/3DVAR.py index 01ead91..9517df6 100644 --- a/src/daComposant/daAlgorithms/3DVAR.py +++ b/src/daComposant/daAlgorithms/3DVAR.py @@ -140,6 +140,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B" ), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Variational", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/4DVAR.py b/src/daComposant/daAlgorithms/4DVAR.py index 8dadd5f..d39a5f1 100644 --- a/src/daComposant/daAlgorithms/4DVAR.py +++ b/src/daComposant/daAlgorithms/4DVAR.py @@ -110,6 +110,12 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): mandatory= ("Xb", "Y", "HO", "EM", "R", "B" ), optional = ("U", "CM"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Variational", + "Dynamic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/DerivativeFreeOptimization.py b/src/daComposant/daAlgorithms/DerivativeFreeOptimization.py index e3012ac..d6b4cb2 100644 --- a/src/daComposant/daAlgorithms/DerivativeFreeOptimization.py +++ b/src/daComposant/daAlgorithms/DerivativeFreeOptimization.py @@ -112,6 +112,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B" ), ) + self.setAttributes(tags=( + "Optimization", + "NonLinear", + "MetaHeuristic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/DifferentialEvolution.py b/src/daComposant/daAlgorithms/DifferentialEvolution.py index 8c2b09a..b36407a 100644 --- a/src/daComposant/daAlgorithms/DifferentialEvolution.py +++ b/src/daComposant/daAlgorithms/DifferentialEvolution.py @@ -141,6 +141,12 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B" ), ) + self.setAttributes(tags=( + "Optimization", + "NonLinear", + "MetaHeuristic", + "Population", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/EnsembleBlue.py b/src/daComposant/daAlgorithms/EnsembleBlue.py index fe2bd3b..75be71e 100644 --- a/src/daComposant/daAlgorithms/EnsembleBlue.py +++ b/src/daComposant/daAlgorithms/EnsembleBlue.py @@ -56,6 +56,12 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Filter", + "Ensemble", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/EnsembleKalmanFilter.py b/src/daComposant/daAlgorithms/EnsembleKalmanFilter.py index 201cf4b..5e68396 100644 --- a/src/daComposant/daAlgorithms/EnsembleKalmanFilter.py +++ b/src/daComposant/daAlgorithms/EnsembleKalmanFilter.py @@ -87,6 +87,13 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): mandatory= ("Xb", "Y", "HO", "R", "B"), optional = ("U", "EM", "CM", "Q"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Filter", + "Ensemble", + "Dynamic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/ExtendedBlue.py b/src/daComposant/daAlgorithms/ExtendedBlue.py index f98df95..6a9ebd5 100644 --- a/src/daComposant/daAlgorithms/ExtendedBlue.py +++ b/src/daComposant/daAlgorithms/ExtendedBlue.py @@ -97,6 +97,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Filter", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/ExtendedKalmanFilter.py b/src/daComposant/daAlgorithms/ExtendedKalmanFilter.py index a400b2e..1cd932a 100644 --- a/src/daComposant/daAlgorithms/ExtendedKalmanFilter.py +++ b/src/daComposant/daAlgorithms/ExtendedKalmanFilter.py @@ -85,6 +85,12 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): mandatory= ("Xb", "Y", "HO", "R", "B"), optional = ("U", "EM", "CM", "Q"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Filter", + "Dynamic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/FunctionTest.py b/src/daComposant/daAlgorithms/FunctionTest.py index 4457d83..2914c43 100644 --- a/src/daComposant/daAlgorithms/FunctionTest.py +++ b/src/daComposant/daAlgorithms/FunctionTest.py @@ -71,6 +71,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/GradientTest.py b/src/daComposant/daAlgorithms/GradientTest.py index ac6ace8..acde000 100644 --- a/src/daComposant/daAlgorithms/GradientTest.py +++ b/src/daComposant/daAlgorithms/GradientTest.py @@ -109,6 +109,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/InputValuesTest.py b/src/daComposant/daAlgorithms/InputValuesTest.py index 6f2c60f..a49957a 100644 --- a/src/daComposant/daAlgorithms/InputValuesTest.py +++ b/src/daComposant/daAlgorithms/InputValuesTest.py @@ -66,6 +66,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= (), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/KalmanFilter.py b/src/daComposant/daAlgorithms/KalmanFilter.py index 9cbea1a..4bc9686 100644 --- a/src/daComposant/daAlgorithms/KalmanFilter.py +++ b/src/daComposant/daAlgorithms/KalmanFilter.py @@ -74,6 +74,12 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): mandatory= ("Xb", "Y", "HO", "R", "B"), optional = ("U", "EM", "CM", "Q"), ) + self.setAttributes(tags=( + "DataAssimilation", + "Linear", + "Filter", + "Dynamic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/LinearityTest.py b/src/daComposant/daAlgorithms/LinearityTest.py index fee4d85..02a0963 100644 --- a/src/daComposant/daAlgorithms/LinearityTest.py +++ b/src/daComposant/daAlgorithms/LinearityTest.py @@ -91,6 +91,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/LocalSensitivityTest.py b/src/daComposant/daAlgorithms/LocalSensitivityTest.py index d29f6b4..f8ed934 100644 --- a/src/daComposant/daAlgorithms/LocalSensitivityTest.py +++ b/src/daComposant/daAlgorithms/LocalSensitivityTest.py @@ -48,6 +48,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/ObserverTest.py b/src/daComposant/daAlgorithms/ObserverTest.py index 1b2e144..c13f0aa 100644 --- a/src/daComposant/daAlgorithms/ObserverTest.py +++ b/src/daComposant/daAlgorithms/ObserverTest.py @@ -28,6 +28,9 @@ import numpy class ElementaryAlgorithm(BasicObjects.Algorithm): def __init__(self): BasicObjects.Algorithm.__init__(self, "OBSERVERTEST") + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/ParallelFunctionTest.py b/src/daComposant/daAlgorithms/ParallelFunctionTest.py index 6ec96c0..8fc2465 100644 --- a/src/daComposant/daAlgorithms/ParallelFunctionTest.py +++ b/src/daComposant/daAlgorithms/ParallelFunctionTest.py @@ -71,6 +71,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/ParticleSwarmOptimization.py b/src/daComposant/daAlgorithms/ParticleSwarmOptimization.py index 122968a..0b62667 100644 --- a/src/daComposant/daAlgorithms/ParticleSwarmOptimization.py +++ b/src/daComposant/daAlgorithms/ParticleSwarmOptimization.py @@ -113,6 +113,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B"), ) + self.setAttributes(tags=( + "Optimization", + "NonLinear", + "Population", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/QuantileRegression.py b/src/daComposant/daAlgorithms/QuantileRegression.py index 3893d5c..d50c3a4 100644 --- a/src/daComposant/daAlgorithms/QuantileRegression.py +++ b/src/daComposant/daAlgorithms/QuantileRegression.py @@ -89,6 +89,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO" ), ) + self.setAttributes(tags=( + "Optimization", + "Risk", + "Variational", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/SamplingTest.py b/src/daComposant/daAlgorithms/SamplingTest.py index 4e10480..d6fc163 100644 --- a/src/daComposant/daAlgorithms/SamplingTest.py +++ b/src/daComposant/daAlgorithms/SamplingTest.py @@ -91,6 +91,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/TabuSearch.py b/src/daComposant/daAlgorithms/TabuSearch.py index 11fb806..0b7da4e 100644 --- a/src/daComposant/daAlgorithms/TabuSearch.py +++ b/src/daComposant/daAlgorithms/TabuSearch.py @@ -125,6 +125,11 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "Y", "HO", "R", "B"), ) + self.setAttributes(tags=( + "Optimization", + "NonLinear", + "MetaHeuristic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/TangentTest.py b/src/daComposant/daAlgorithms/TangentTest.py index 7c04be6..6b507b4 100644 --- a/src/daComposant/daAlgorithms/TangentTest.py +++ b/src/daComposant/daAlgorithms/TangentTest.py @@ -91,6 +91,9 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): self.requireInputArguments( mandatory= ("Xb", "HO"), ) + self.setAttributes(tags=( + "Checking", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) diff --git a/src/daComposant/daAlgorithms/UnscentedKalmanFilter.py b/src/daComposant/daAlgorithms/UnscentedKalmanFilter.py index ba61f96..23d160e 100644 --- a/src/daComposant/daAlgorithms/UnscentedKalmanFilter.py +++ b/src/daComposant/daAlgorithms/UnscentedKalmanFilter.py @@ -104,6 +104,13 @@ class ElementaryAlgorithm(BasicObjects.Algorithm): mandatory= ("Xb", "Y", "HO", "R", "B" ), optional = ("U", "EM", "CM", "Q"), ) + self.setAttributes(tags=( + "DataAssimilation", + "NonLinear", + "Filter", + "Ensemble", + "Dynamic", + )) def run(self, Xb=None, Y=None, U=None, HO=None, EM=None, CM=None, R=None, B=None, Q=None, Parameters=None): self._pre_run(Parameters, Xb, Y, R, B, Q) -- 2.39.2