From: SANDEEP KUMAR JAISAWAL Date: Tue, 18 Oct 2022 06:23:09 +0000 (+0530) Subject: Adding constant files for training manager X-Git-Tag: 1.0.0~30 X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F97%2F9297%2F1;p=aiml-fw%2Fawmf%2Ftm.git Adding constant files for training manager Issue-Id: AIMLFW-2 Signed-off-by: SANDEEP KUMAR JAISAWAL Change-Id: I32bc63c09d83dbc47ec44753d0ceec0a62d27659 --- diff --git a/trainingmgr/constants/__init__.py b/trainingmgr/constants/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/trainingmgr/constants/states.py b/trainingmgr/constants/states.py new file mode 100644 index 0000000..963c808 --- /dev/null +++ b/trainingmgr/constants/states.py @@ -0,0 +1,30 @@ +# ================================================================================== +# +# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ================================================================================== + +""" +This module contains States class for different training manager's states. +""" +from enum import Enum +class States(Enum): + """ + This class contains different usecase's states. + """ + NOT_STARTED = 1 + IN_PROGRESS = 2 + FAILED = 3 + FINISHED = 4 diff --git a/trainingmgr/constants/steps.py b/trainingmgr/constants/steps.py new file mode 100644 index 0000000..c223b3d --- /dev/null +++ b/trainingmgr/constants/steps.py @@ -0,0 +1,31 @@ +# ================================================================================== +# +# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ================================================================================== + +""" +This module contains Steps class for different training manager's steps. +""" +from enum import Enum +class Steps(Enum): + """ + This class contains different usecase's steps. + """ + DATA_EXTRACTION = 1 + DATA_EXTRACTION_AND_TRAINING = 2 + TRAINING = 3 + TRAINING_AND_TRAINED_MODEL = 4 + TRAINED_MODEL = 5