summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/pci/optimizers/solver/ml_model.py3
-rw-r--r--test/apps/pci_optimization/test_ml_model.py2
2 files changed, 3 insertions, 2 deletions
diff --git a/apps/pci/optimizers/solver/ml_model.py b/apps/pci/optimizers/solver/ml_model.py
index 67402d9..c239be8 100644
--- a/apps/pci/optimizers/solver/ml_model.py
+++ b/apps/pci/optimizers/solver/ml_model.py
@@ -18,6 +18,7 @@
import json
+from apps.pci.optimizers.solver.pci_utils import get_id
from osdf.adapters.dcae import des
from osdf.adapters.dcae.des import DESException
from osdf.config.base import osdf_config
@@ -45,7 +46,7 @@ class MlModel(object):
cell_id = cell['cell_id']
average_ho, latest_ho = self.get_ho_details(cell['cell_id'])
if average_ho > average_ho_threshold or latest_ho > latest_ho_threshold:
- fixed_cells.add(cell_id)
+ fixed_cells.add(get_id(network_cell_info, cell_id))
fixed_cells.update(dzn_data.get('PCI_UNCHANGEABLE_CELLS', []))
dzn_data['PCI_UNCHANGEABLE_CELLS'] = fixed_cells
diff --git a/test/apps/pci_optimization/test_ml_model.py b/test/apps/pci_optimization/test_ml_model.py
index 3a7f76c..cf0dee5 100644
--- a/test/apps/pci_optimization/test_ml_model.py
+++ b/test/apps/pci_optimization/test_ml_model.py
@@ -70,7 +70,7 @@ class TestMlModel(unittest.TestCase):
self.Mock_req = self.patcher_req.start()
mlmodel = MlModel()
mlmodel.get_additional_inputs(dzn_data, network_cell_info)
- self.assertEqual({'Chn0001'}, dzn_data['PCI_UNCHANGEABLE_CELLS'])
+ self.assertEqual({1}, dzn_data['PCI_UNCHANGEABLE_CELLS'])
self.patcher_req.stop()
dzn_data['PCI_UNCHANGEABLE_CELLS'] = []