]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
Separate diskprediction local plugin from the diskprediction plugin
authorhsiang41 <rick.chen@prophetstor.com>
Mon, 5 Nov 2018 06:04:55 +0000 (14:04 +0800)
committerhsiang41 <rick.chen@prophetstor.com>
Mon, 5 Nov 2018 06:09:10 +0000 (14:09 +0800)
Separate diskprediction local plugin from the diskprediction plugin.
Devicehealth invoke device prediction function related on the global
 configuration "device_failure_prediction_mode".

Signed-off-by: Rick Chen <rick.chen@prophetstor.com>
83 files changed:
COPYING
doc/mgr/diskprediction.rst
src/common/options.cc
src/pybind/mgr/devicehealth/module.py
src/pybind/mgr/diskprediction_local/__init__.py [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/config.json [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_1.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_10.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_104.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_105.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_109.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_112.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_114.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_115.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_118.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_119.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_12.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_120.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_123.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_124.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_125.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_128.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_131.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_134.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_138.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_14.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_141.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_145.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_151.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_16.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_161.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_168.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_169.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_174.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_18.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_182.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_185.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_186.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_195.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_201.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_204.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_206.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_208.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_210.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_212.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_213.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_219.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_221.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_222.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_223.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_225.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_227.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_229.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_230.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_234.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_235.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_236.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_239.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_243.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_27.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_3.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_33.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_36.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_44.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_50.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_57.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_59.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_6.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_61.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_62.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_67.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_69.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_71.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_72.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_78.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_79.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_82.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_85.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_88.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_93.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/models/svm_97.pkl [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/module.py [new file with mode: 0644]
src/pybind/mgr/diskprediction_local/predictor.py [new file with mode: 0644]

diff --git a/COPYING b/COPYING
index 22acddf0e0d1a2ed1f0d3d91e9798e47ae2cc648..8d663702b639b4a652ab246b2aa96d06da1ebf83 100644 (file)
--- a/COPYING
+++ b/COPYING
@@ -146,7 +146,7 @@ Files: src/include/timegm.h
   Copyright (C) Copyright 2010-2011 Vicente J. Botet Escriba
   License: Boost Software License, Version 1.0
 
-Files: src/pybind/mgr/diskprediction/predictor/models/*
+Files: src/pybind/mgr/diskprediction_local/models/*
 Copyright: None
 License: Public domain
 
index f0778e193cb0e50ce490f3185a4d58562e2d27e3..bbc163f5c2eefb734d2773d125aa03b1f78b3de1 100644 (file)
@@ -17,15 +17,15 @@ environment::
 
 Select the prediction mode::
 
-    ceph config set global device_health_prediction_mode local
+    ceph config set global device_failure_prediction_mode local
 
 or::
   
-    ceph config set global device_health_prediction_mode cloud
+    ceph config set global device_failure_prediction_mode cloud
 
 To disable prediction,::
 
-  ceph config set global device_health_prediction_mode none
+  ceph config set global device_failure_prediction_mode none
 
 
 Connection settings
index 49cb29a08f6ddca2660e18ce31fd3f5ba84b0f93..30499fe3534a173fd615e33f4a70643f4ed6928a 100644 (file)
@@ -4991,6 +4991,7 @@ std::vector<Option> get_global_options() {
 
     Option("device_failure_prediction_mode", Option::TYPE_STR, Option::LEVEL_BASIC)
     .set_default("none")
+    .set_flag(Option::FLAG_RUNTIME)
     .set_enum_allowed({"none", "local", "cloud"})
     .set_description("Method used to predict device failures")
     .set_long_description("To disable prediction, use 'none',  'local' uses a prediction model that runs inside the mgr daemon.  'cloud' will share metrics with a cloud service and query the service for devicelife expectancy."),
index 5d34739eb9d1ad66d4bfc762c1a668a3ca2faec1..c73cf82f3f46d1db6ec708524ee95d7b66c6ca89 100644 (file)
@@ -101,6 +101,12 @@ class Module(MgrModule):
             "desc": "Disable device health monitoring",
             "perm": "rw",
         },
+        {
+            'cmd': 'device predict-life-expectancy '
+                   'name=devid,type=CephString,req=true',
+            'desc': 'Predict life expectancy with local predictor',
+            'perm': 'r'
+        },
     ]
 
     def __init__(self, *args, **kwargs):
@@ -159,6 +165,8 @@ class Module(MgrModule):
             self.set_config('enable_monitoring', 'false')
             self.set_health_checks({})  # avoid stuck health alerts
             return 0, '', ''
+        elif cmd['prefix'] == 'device predict-life-expectancy':
+            return self.predict_lift_expectancy(cmd['devid'])
         else:
             # mgr should respect our self.COMMANDS and not call us for
             # any prefix we don't advertise
@@ -225,6 +233,7 @@ class Module(MgrModule):
                                    next_scrape.strftime(TIME_FORMAT))
                 if now >= next_scrape:
                     self.scrape_all()
+                    self.predict_all_devices()
                     last_scrape = now
                     self.set_store('last_scrape', last_scrape.strftime(TIME_FORMAT))
 
@@ -564,3 +573,25 @@ class Module(MgrModule):
         # FIXME: extract and normalize raw smartctl --json output and
         # generate a dict of the fields we care about.
         return raw
+
+    def predict_lift_expectancy(self, devid):
+        plugin_name = ''
+        model = self.get_option('device_failure_prediction_mode')
+        if model and model.lower() == 'cloud':
+            plugin_name = 'diskprediction_cloud'
+        elif model and model.lower() == 'local':
+            plugin_name = 'diskprediction_local'
+        else:
+            return -1, '', 'unable to enable any disk prediction model[local/cloud]'
+        return self.remote(plugin_name, 'predict_life_expentancy', devid=devid)
+
+    def predict_all_devices(self):
+        plugin_name = ''
+        model = self.get_option('device_failure_prediction_mode')
+        if model and model.lower() == 'cloud':
+            plugin_name = 'diskprediction_cloud'
+        elif model and model.lower() == 'local':
+            plugin_name = 'diskprediction_local'
+        else:
+            return -1, '', 'unable to enable any disk prediction model[local/cloud]'
+        return self.remote(plugin_name, 'predict_all_devices')
diff --git a/src/pybind/mgr/diskprediction_local/__init__.py b/src/pybind/mgr/diskprediction_local/__init__.py
new file mode 100644 (file)
index 0000000..8f210ac
--- /dev/null
@@ -0,0 +1 @@
+from .module import Module
diff --git a/src/pybind/mgr/diskprediction_local/models/config.json b/src/pybind/mgr/diskprediction_local/models/config.json
new file mode 100644 (file)
index 0000000..9a1485c
--- /dev/null
@@ -0,0 +1,77 @@
+{
+"svm_123.pkl": ["smart_197_raw", "smart_183_raw", "smart_200_raw", "smart_194_raw", "smart_254_raw", "smart_252_raw", "smart_4_raw", "smart_222_raw", "smart_187_raw", "smart_184_raw"],
+"svm_105.pkl": ["smart_197_raw", "smart_4_raw", "smart_5_raw", "smart_252_raw", "smart_184_raw", "smart_223_raw", "smart_198_raw", "smart_10_raw", "smart_189_raw", "smart_222_raw"],
+"svm_82.pkl":["smart_184_raw", "smart_2_raw", "smart_187_raw", "smart_225_raw", "smart_198_raw", "smart_197_raw", "smart_4_raw", "smart_13_raw", "smart_188_raw", "smart_251_raw"],
+"svm_186.pkl":["smart_3_raw", "smart_11_raw", "smart_198_raw", "smart_250_raw", "smart_13_raw", "smart_200_raw", "smart_224_raw", "smart_187_raw", "smart_22_raw", "smart_4_raw", "smart_220_raw"],
+"svm_14.pkl":["smart_12_raw", "smart_226_raw", "smart_187_raw", "smart_196_raw", "smart_5_raw", "smart_183_raw", "smart_255_raw", "smart_250_raw", "smart_201_raw", "smart_8_raw"],
+"svm_10.pkl":["smart_251_raw", "smart_4_raw", "smart_223_raw", "smart_13_raw", "smart_255_raw", "smart_188_raw", "smart_197_raw", "smart_201_raw", "smart_250_raw", "smart_15_raw"],
+"svm_235.pkl":["smart_15_raw", "smart_255_raw", "smart_252_raw", "smart_197_raw", "smart_250_raw", "smart_254_raw", "smart_13_raw", "smart_251_raw", "smart_198_raw", "smart_189_raw", "smart_191_raw"],
+"svm_234.pkl":["smart_187_raw", "smart_183_raw", "smart_3_raw", "smart_4_raw", "smart_222_raw", "smart_184_raw", "smart_5_raw", "smart_198_raw", "smart_200_raw", "smart_8_raw", "smart_10_raw"],
+"svm_119.pkl":["smart_254_raw", "smart_8_raw", "smart_183_raw", "smart_184_raw", "smart_195_raw", "smart_252_raw", "smart_191_raw", "smart_10_raw", "smart_200_raw", "smart_197_raw"],
+"svm_227.pkl":["smart_254_raw", "smart_189_raw", "smart_225_raw", "smart_224_raw", "smart_197_raw", "smart_223_raw", "smart_4_raw", "smart_183_raw", "smart_11_raw", "smart_184_raw", "smart_13_raw"],
+"svm_18.pkl":["smart_197_raw", "smart_3_raw", "smart_220_raw", "smart_193_raw", "smart_10_raw", "smart_187_raw", "smart_188_raw", "smart_225_raw", "smart_194_raw", "smart_13_raw"],
+"svm_78.pkl":["smart_10_raw", "smart_183_raw", "smart_191_raw", "smart_13_raw", "smart_198_raw", "smart_22_raw", "smart_195_raw", "smart_12_raw", "smart_224_raw", "smart_200_raw"],
+"svm_239.pkl":["smart_3_raw", "smart_254_raw", "smart_199_raw", "smart_225_raw", "smart_187_raw", "smart_195_raw", "smart_197_raw", "smart_2_raw", "smart_193_raw", "smart_220_raw", "smart_183_raw"],
+"svm_174.pkl":["smart_183_raw", "smart_196_raw", "smart_225_raw", "smart_189_raw", "smart_4_raw", "smart_3_raw", "smart_9_raw", "smart_198_raw", "smart_15_raw", "smart_5_raw", "smart_194_raw"],
+"svm_104.pkl":["smart_12_raw", "smart_198_raw", "smart_197_raw", "smart_4_raw", "smart_240_raw", "smart_187_raw", "smart_225_raw", "smart_8_raw", "smart_3_raw", "smart_2_raw"],
+"svm_12.pkl":["smart_222_raw", "smart_251_raw", "smart_194_raw", "smart_9_raw", "smart_184_raw", "smart_191_raw", "smart_187_raw", "smart_255_raw", "smart_4_raw", "smart_11_raw"],
+"svm_97.pkl":["smart_15_raw", "smart_197_raw", "smart_190_raw", "smart_199_raw", "smart_200_raw", "smart_12_raw", "smart_191_raw", "smart_254_raw", "smart_194_raw", "smart_201_raw"],
+"svm_118.pkl":["smart_11_raw", "smart_225_raw", "smart_196_raw", "smart_197_raw", "smart_198_raw", "smart_200_raw", "smart_3_raw", "smart_10_raw", "smart_191_raw", "smart_22_raw"],
+"svm_185.pkl":["smart_191_raw", "smart_254_raw", "smart_3_raw", "smart_190_raw", "smart_15_raw", "smart_22_raw", "smart_2_raw", "smart_198_raw", "smart_13_raw", "smart_226_raw", "smart_225_raw"],
+"svm_206.pkl":["smart_183_raw", "smart_192_raw", "smart_197_raw", "smart_255_raw", "smart_187_raw", "smart_254_raw", "smart_198_raw", "smart_13_raw", "smart_226_raw", "smart_240_raw", "smart_8_raw"],
+"svm_225.pkl":["smart_224_raw", "smart_11_raw", "smart_5_raw", "smart_4_raw", "smart_225_raw", "smart_197_raw", "smart_15_raw", "smart_183_raw", "smart_193_raw", "smart_190_raw", "smart_187_raw"],
+"svm_169.pkl":["smart_252_raw", "smart_183_raw", "smart_254_raw", "smart_11_raw", "smart_193_raw", "smart_22_raw", "smart_226_raw", "smart_189_raw", "smart_225_raw", "smart_198_raw", "smart_200_raw"],
+"svm_79.pkl":["smart_184_raw", "smart_196_raw", "smart_4_raw", "smart_226_raw", "smart_199_raw", "smart_187_raw", "smart_193_raw", "smart_188_raw", "smart_12_raw", "smart_250_raw"],
+"svm_69.pkl":["smart_187_raw", "smart_9_raw", "smart_200_raw", "smart_11_raw", "smart_252_raw", "smart_189_raw", "smart_4_raw", "smart_188_raw", "smart_255_raw", "smart_201_raw"],
+"svm_201.pkl":["smart_224_raw", "smart_8_raw", "smart_250_raw", "smart_2_raw", "smart_198_raw", "smart_15_raw", "smart_193_raw", "smart_223_raw", "smart_3_raw", "smart_11_raw", "smart_191_raw"],
+"svm_114.pkl":["smart_226_raw", "smart_188_raw", "smart_2_raw", "smart_11_raw", "smart_4_raw", "smart_193_raw", "smart_184_raw", "smart_194_raw", "smart_198_raw", "smart_13_raw"],
+"svm_219.pkl":["smart_12_raw", "smart_22_raw", "smart_8_raw", "smart_191_raw", "smart_197_raw", "smart_254_raw", "smart_15_raw", "smart_193_raw", "smart_199_raw", "smart_225_raw", "smart_192_raw"],
+"svm_168.pkl":["smart_255_raw", "smart_191_raw", "smart_193_raw", "smart_220_raw", "smart_5_raw", "smart_3_raw", "smart_222_raw", "smart_223_raw", "smart_197_raw", "smart_196_raw", "smart_22_raw"],
+"svm_243.pkl":["smart_11_raw", "smart_255_raw", "smart_10_raw", "smart_189_raw", "smart_225_raw", "smart_240_raw", "smart_222_raw", "smart_197_raw", "smart_183_raw", "smart_198_raw", "smart_12_raw"],
+"svm_195.pkl":["smart_183_raw", "smart_5_raw", "smart_11_raw", "smart_197_raw", "smart_15_raw", "smart_9_raw", "smart_4_raw", "smart_220_raw", "smart_12_raw", "smart_192_raw", "smart_240_raw"],
+"svm_222.pkl":["smart_10_raw", "smart_13_raw", "smart_188_raw", "smart_15_raw", "smart_192_raw", "smart_224_raw", "smart_225_raw", "smart_187_raw", "smart_222_raw", "smart_220_raw", "smart_252_raw"],
+"svm_62.pkl":["smart_196_raw", "smart_251_raw", "smart_187_raw", "smart_224_raw", "smart_11_raw", "smart_12_raw", "smart_8_raw", "smart_199_raw", "smart_220_raw", "smart_195_raw"],
+"svm_151.pkl":["smart_187_raw", "smart_223_raw", "smart_200_raw", "smart_189_raw", "smart_251_raw", "smart_255_raw", "smart_222_raw", "smart_192_raw", "smart_12_raw", "smart_183_raw", "smart_22_raw"],
+"svm_125.pkl":["smart_9_raw", "smart_252_raw", "smart_197_raw", "smart_251_raw", "smart_11_raw", "smart_12_raw", "smart_188_raw", "smart_240_raw", "smart_10_raw", "smart_223_raw"],
+"svm_124.pkl":["smart_193_raw", "smart_187_raw", "smart_183_raw", "smart_11_raw", "smart_10_raw", "smart_8_raw", "smart_194_raw", "smart_189_raw", "smart_222_raw", "smart_191_raw"],
+"svm_67.pkl":["smart_2_raw", "smart_8_raw", "smart_225_raw", "smart_240_raw", "smart_13_raw", "smart_5_raw", "smart_187_raw", "smart_198_raw", "smart_199_raw", "smart_3_raw"],
+"svm_115.pkl":["smart_222_raw", "smart_193_raw", "smart_223_raw", "smart_195_raw", "smart_252_raw", "smart_189_raw", "smart_199_raw", "smart_187_raw", "smart_15_raw", "smart_184_raw"],
+"svm_1.pkl":["smart_201_raw", "smart_8_raw", "smart_200_raw", "smart_252_raw", "smart_251_raw", "smart_187_raw", "smart_9_raw", "smart_188_raw", "smart_15_raw", "smart_184_raw"],
+"svm_112.pkl":["smart_220_raw", "smart_197_raw", "smart_10_raw", "smart_188_raw", "smart_12_raw", "smart_4_raw", "smart_196_raw", "smart_3_raw", "smart_240_raw", "smart_225_raw"],
+"svm_138.pkl":["smart_183_raw", "smart_10_raw", "smart_191_raw", "smart_195_raw", "smart_223_raw", "smart_189_raw", "smart_187_raw", "smart_255_raw", "smart_226_raw", "smart_8_raw"],
+"svm_229.pkl":["smart_224_raw", "smart_8_raw", "smart_192_raw", "smart_220_raw", "smart_195_raw", "smart_183_raw", "smart_250_raw", "smart_187_raw", "smart_225_raw", "smart_4_raw", "smart_252_raw"],
+"svm_145.pkl":["smart_190_raw", "smart_8_raw", "smart_226_raw", "smart_184_raw", "smart_225_raw", "smart_220_raw", "smart_193_raw", "smart_183_raw", "smart_201_raw", "smart_187_raw", "smart_2_raw"],
+"svm_59.pkl":["smart_188_raw", "smart_11_raw", "smart_184_raw", "smart_2_raw", "smart_220_raw", "smart_198_raw", "smart_225_raw", "smart_240_raw", "smart_197_raw", "smart_251_raw"],
+"svm_204.pkl":["smart_15_raw", "smart_240_raw", "smart_225_raw", "smart_223_raw", "smart_252_raw", "smart_22_raw", "smart_200_raw", "smart_13_raw", "smart_220_raw", "smart_198_raw", "smart_191_raw"],
+"svm_88.pkl":["smart_198_raw", "smart_3_raw", "smart_8_raw", "smart_225_raw", "smart_251_raw", "smart_222_raw", "smart_188_raw", "smart_10_raw", "smart_240_raw", "smart_189_raw"],
+"svm_182.pkl":["smart_10_raw", "smart_190_raw", "smart_250_raw", "smart_15_raw", "smart_193_raw", "smart_22_raw", "smart_200_raw", "smart_8_raw", "smart_4_raw", "smart_187_raw", "smart_9_raw"],
+"svm_61.pkl":["smart_5_raw", "smart_12_raw", "smart_9_raw", "smart_198_raw", "smart_195_raw", "smart_252_raw", "smart_15_raw", "smart_240_raw", "smart_255_raw", "smart_224_raw"],
+"svm_50.pkl":["smart_220_raw", "smart_5_raw", "smart_194_raw", "smart_250_raw", "smart_15_raw", "smart_240_raw", "smart_8_raw", "smart_198_raw", "smart_224_raw", "smart_191_raw"],
+"svm_210.pkl":["smart_8_raw", "smart_15_raw", "smart_195_raw", "smart_224_raw", "smart_5_raw", "smart_191_raw", "smart_198_raw", "smart_225_raw", "smart_200_raw", "smart_251_raw", "smart_240_raw"],
+"svm_16.pkl":["smart_222_raw", "smart_10_raw", "smart_250_raw", "smart_189_raw", "smart_191_raw", "smart_2_raw", "smart_5_raw", "smart_193_raw", "smart_9_raw", "smart_187_raw"],
+"svm_85.pkl":["smart_252_raw", "smart_184_raw", "smart_9_raw", "smart_5_raw", "smart_254_raw", "smart_3_raw", "smart_195_raw", "smart_10_raw", "smart_12_raw", "smart_222_raw"],
+"svm_36.pkl":["smart_201_raw", "smart_251_raw", "smart_184_raw", "smart_3_raw", "smart_5_raw", "smart_183_raw", "smart_194_raw", "smart_195_raw", "smart_224_raw", "smart_2_raw"],
+"svm_33.pkl":["smart_223_raw", "smart_254_raw", "smart_225_raw", "smart_9_raw", "smart_199_raw", "smart_5_raw", "smart_189_raw", "smart_194_raw", "smart_240_raw", "smart_4_raw"],
+"svm_3.pkl":["smart_225_raw", "smart_194_raw", "smart_3_raw", "smart_189_raw", "smart_9_raw", "smart_254_raw", "smart_240_raw", "smart_5_raw", "smart_255_raw", "smart_223_raw"],
+"svm_93.pkl":["smart_8_raw", "smart_188_raw", "smart_5_raw", "smart_10_raw", "smart_222_raw", "smart_2_raw", "smart_254_raw", "smart_12_raw", "smart_193_raw", "smart_224_raw"],
+"svm_120.pkl":["smart_189_raw", "smart_224_raw", "smart_222_raw", "smart_193_raw", "smart_5_raw", "smart_201_raw", "smart_8_raw", "smart_254_raw", "smart_194_raw", "smart_22_raw"],
+"svm_128.pkl":["smart_195_raw", "smart_184_raw", "smart_251_raw", "smart_8_raw", "smart_5_raw", "smart_196_raw", "smart_10_raw", "smart_4_raw", "smart_225_raw", "smart_191_raw"],
+"svm_212.pkl":["smart_225_raw", "smart_192_raw", "smart_10_raw", "smart_12_raw", "smart_222_raw", "smart_184_raw", "smart_13_raw", "smart_226_raw", "smart_5_raw", "smart_201_raw", "smart_22_raw"],
+"svm_221.pkl":["smart_255_raw", "smart_2_raw", "smart_224_raw", "smart_192_raw", "smart_252_raw", "smart_13_raw", "smart_183_raw", "smart_193_raw", "smart_15_raw", "smart_199_raw", "smart_200_raw"],
+"svm_223.pkl":["smart_4_raw", "smart_194_raw", "smart_9_raw", "smart_255_raw", "smart_188_raw", "smart_201_raw", "smart_3_raw", "smart_226_raw", "smart_192_raw", "smart_251_raw", "smart_191_raw"],
+"svm_44.pkl":["smart_255_raw", "smart_11_raw", "smart_200_raw", "smart_3_raw", "smart_195_raw", "smart_201_raw", "smart_4_raw", "smart_5_raw", "smart_10_raw", "smart_191_raw"],
+"svm_213.pkl":["smart_22_raw", "smart_191_raw", "smart_183_raw", "smart_4_raw", "smart_194_raw", "smart_255_raw", "smart_254_raw", "smart_193_raw", "smart_11_raw", "smart_10_raw", "smart_220_raw"],
+"svm_131.pkl":["smart_22_raw", "smart_194_raw", "smart_184_raw", "smart_250_raw", "smart_10_raw", "smart_189_raw", "smart_183_raw", "smart_240_raw", "smart_12_raw", "smart_252_raw"],
+"svm_6.pkl":["smart_194_raw", "smart_250_raw", "smart_223_raw", "smart_224_raw", "smart_184_raw", "smart_191_raw", "smart_201_raw", "smart_9_raw", "smart_252_raw", "smart_3_raw"],
+"svm_161.pkl":["smart_255_raw", "smart_222_raw", "smart_226_raw", "smart_254_raw", "smart_183_raw", "smart_22_raw", "smart_12_raw", "smart_190_raw", "smart_11_raw", "smart_192_raw", "smart_251_raw"],
+"svm_72.pkl":["smart_13_raw", "smart_184_raw", "smart_223_raw", "smart_240_raw", "smart_250_raw", "smart_251_raw", "smart_201_raw", "smart_196_raw", "smart_5_raw", "smart_4_raw"],
+"svm_27.pkl":["smart_189_raw", "smart_188_raw", "smart_255_raw", "smart_251_raw", "smart_240_raw", "smart_15_raw", "smart_9_raw", "smart_191_raw", "smart_226_raw", "smart_10_raw"],
+"svm_141.pkl":["smart_9_raw", "smart_191_raw", "smart_2_raw", "smart_226_raw", "smart_13_raw", "smart_22_raw", "smart_193_raw", "smart_222_raw", "smart_220_raw", "smart_225_raw", "smart_3_raw"],
+"svm_57.pkl":["smart_12_raw", "smart_252_raw", "smart_190_raw", "smart_226_raw", "smart_10_raw", "smart_189_raw", "smart_193_raw", "smart_2_raw", "smart_9_raw", "smart_223_raw"],
+"svm_236.pkl":["smart_200_raw", "smart_189_raw", "smart_226_raw", "smart_252_raw", "smart_250_raw", "smart_193_raw", "smart_13_raw", "smart_2_raw", "smart_254_raw", "smart_22_raw", "smart_9_raww"],
+"svm_208.pkl":["smart_223_raw", "smart_15_raw", "smart_251_raw", "smart_5_raw", "smart_198_raw", "smart_252_raw", "smart_4_raw", "smart_8_raw", "smart_220_raw", "smart_254_raw", "smart_193_raw"],
+"svm_230.pkl":["smart_184_raw", "smart_5_raw", "smart_191_raw", "smart_198_raw", "smart_11_raw", "smart_255_raw", "smart_189_raw", "smart_254_raw", "smart_196_raw", "smart_199_raw", "smart_223_raw"],
+"svm_134.pkl":["smart_8_raw", "smart_194_raw", "smart_4_raw", "smart_189_raw", "smart_223_raw", "smart_5_raw", "smart_187_raw", "smart_9_raw", "smart_192_raw", "smart_220_raw"],
+"svm_71.pkl":["smart_220_raw", "smart_13_raw", "smart_194_raw", "smart_197_raw", "smart_192_raw", "smart_22_raw", "smart_184_raw", "smart_199_raw", "smart_222_raw", "smart_183_raw"],
+"svm_109.pkl":["smart_224_raw", "smart_252_raw", "smart_2_raw", "smart_200_raw", "smart_5_raw", "smart_194_raw", "smart_222_raw", "smart_198_raw", "smart_4_raw", "smart_13_raw"]
+}
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_1.pkl b/src/pybind/mgr/diskprediction_local/models/svm_1.pkl
new file mode 100644 (file)
index 0000000..5eb30f3
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_1.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_10.pkl b/src/pybind/mgr/diskprediction_local/models/svm_10.pkl
new file mode 100644 (file)
index 0000000..9259c1e
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_10.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_104.pkl b/src/pybind/mgr/diskprediction_local/models/svm_104.pkl
new file mode 100644 (file)
index 0000000..d5d5cf5
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_104.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_105.pkl b/src/pybind/mgr/diskprediction_local/models/svm_105.pkl
new file mode 100644 (file)
index 0000000..4aadc3c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_105.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_109.pkl b/src/pybind/mgr/diskprediction_local/models/svm_109.pkl
new file mode 100644 (file)
index 0000000..c99c353
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_109.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_112.pkl b/src/pybind/mgr/diskprediction_local/models/svm_112.pkl
new file mode 100644 (file)
index 0000000..367a330
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_112.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_114.pkl b/src/pybind/mgr/diskprediction_local/models/svm_114.pkl
new file mode 100644 (file)
index 0000000..946d5ce
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_114.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_115.pkl b/src/pybind/mgr/diskprediction_local/models/svm_115.pkl
new file mode 100644 (file)
index 0000000..ff83492
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_115.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_118.pkl b/src/pybind/mgr/diskprediction_local/models/svm_118.pkl
new file mode 100644 (file)
index 0000000..eec8689
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_118.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_119.pkl b/src/pybind/mgr/diskprediction_local/models/svm_119.pkl
new file mode 100644 (file)
index 0000000..6a26c05
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_119.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_12.pkl b/src/pybind/mgr/diskprediction_local/models/svm_12.pkl
new file mode 100644 (file)
index 0000000..5cbe977
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_12.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_120.pkl b/src/pybind/mgr/diskprediction_local/models/svm_120.pkl
new file mode 100644 (file)
index 0000000..d2041c2
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_120.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_123.pkl b/src/pybind/mgr/diskprediction_local/models/svm_123.pkl
new file mode 100644 (file)
index 0000000..0ab6187
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_123.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_124.pkl b/src/pybind/mgr/diskprediction_local/models/svm_124.pkl
new file mode 100644 (file)
index 0000000..8f9ea4e
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_124.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_125.pkl b/src/pybind/mgr/diskprediction_local/models/svm_125.pkl
new file mode 100644 (file)
index 0000000..4d49900
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_125.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_128.pkl b/src/pybind/mgr/diskprediction_local/models/svm_128.pkl
new file mode 100644 (file)
index 0000000..6a18726
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_128.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_131.pkl b/src/pybind/mgr/diskprediction_local/models/svm_131.pkl
new file mode 100644 (file)
index 0000000..e6a55dc
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_131.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_134.pkl b/src/pybind/mgr/diskprediction_local/models/svm_134.pkl
new file mode 100644 (file)
index 0000000..51171e0
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_134.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_138.pkl b/src/pybind/mgr/diskprediction_local/models/svm_138.pkl
new file mode 100644 (file)
index 0000000..bc98e0c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_138.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_14.pkl b/src/pybind/mgr/diskprediction_local/models/svm_14.pkl
new file mode 100644 (file)
index 0000000..c4547dc
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_14.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_141.pkl b/src/pybind/mgr/diskprediction_local/models/svm_141.pkl
new file mode 100644 (file)
index 0000000..86d9f38
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_141.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_145.pkl b/src/pybind/mgr/diskprediction_local/models/svm_145.pkl
new file mode 100644 (file)
index 0000000..24ff962
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_145.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_151.pkl b/src/pybind/mgr/diskprediction_local/models/svm_151.pkl
new file mode 100644 (file)
index 0000000..92bfd3f
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_151.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_16.pkl b/src/pybind/mgr/diskprediction_local/models/svm_16.pkl
new file mode 100644 (file)
index 0000000..11664b3
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_16.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_161.pkl b/src/pybind/mgr/diskprediction_local/models/svm_161.pkl
new file mode 100644 (file)
index 0000000..2d42168
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_161.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_168.pkl b/src/pybind/mgr/diskprediction_local/models/svm_168.pkl
new file mode 100644 (file)
index 0000000..12a811c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_168.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_169.pkl b/src/pybind/mgr/diskprediction_local/models/svm_169.pkl
new file mode 100644 (file)
index 0000000..0c51446
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_169.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_174.pkl b/src/pybind/mgr/diskprediction_local/models/svm_174.pkl
new file mode 100644 (file)
index 0000000..d2945ce
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_174.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_18.pkl b/src/pybind/mgr/diskprediction_local/models/svm_18.pkl
new file mode 100644 (file)
index 0000000..d05520c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_18.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_182.pkl b/src/pybind/mgr/diskprediction_local/models/svm_182.pkl
new file mode 100644 (file)
index 0000000..7fcfb3c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_182.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_185.pkl b/src/pybind/mgr/diskprediction_local/models/svm_185.pkl
new file mode 100644 (file)
index 0000000..785301c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_185.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_186.pkl b/src/pybind/mgr/diskprediction_local/models/svm_186.pkl
new file mode 100644 (file)
index 0000000..4ea83da
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_186.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_195.pkl b/src/pybind/mgr/diskprediction_local/models/svm_195.pkl
new file mode 100644 (file)
index 0000000..12273f7
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_195.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_201.pkl b/src/pybind/mgr/diskprediction_local/models/svm_201.pkl
new file mode 100644 (file)
index 0000000..c866cf0
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_201.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_204.pkl b/src/pybind/mgr/diskprediction_local/models/svm_204.pkl
new file mode 100644 (file)
index 0000000..8cf1c3a
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_204.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_206.pkl b/src/pybind/mgr/diskprediction_local/models/svm_206.pkl
new file mode 100644 (file)
index 0000000..cba64e8
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_206.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_208.pkl b/src/pybind/mgr/diskprediction_local/models/svm_208.pkl
new file mode 100644 (file)
index 0000000..ba0df0a
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_208.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_210.pkl b/src/pybind/mgr/diskprediction_local/models/svm_210.pkl
new file mode 100644 (file)
index 0000000..6b5bee2
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_210.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_212.pkl b/src/pybind/mgr/diskprediction_local/models/svm_212.pkl
new file mode 100644 (file)
index 0000000..11eafc6
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_212.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_213.pkl b/src/pybind/mgr/diskprediction_local/models/svm_213.pkl
new file mode 100644 (file)
index 0000000..0b8475c
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_213.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_219.pkl b/src/pybind/mgr/diskprediction_local/models/svm_219.pkl
new file mode 100644 (file)
index 0000000..4a248c1
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_219.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_221.pkl b/src/pybind/mgr/diskprediction_local/models/svm_221.pkl
new file mode 100644 (file)
index 0000000..e37c6b4
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_221.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_222.pkl b/src/pybind/mgr/diskprediction_local/models/svm_222.pkl
new file mode 100644 (file)
index 0000000..e543038
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_222.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_223.pkl b/src/pybind/mgr/diskprediction_local/models/svm_223.pkl
new file mode 100644 (file)
index 0000000..8b208f4
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_223.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_225.pkl b/src/pybind/mgr/diskprediction_local/models/svm_225.pkl
new file mode 100644 (file)
index 0000000..3f2b629
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_225.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_227.pkl b/src/pybind/mgr/diskprediction_local/models/svm_227.pkl
new file mode 100644 (file)
index 0000000..5e4fb56
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_227.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_229.pkl b/src/pybind/mgr/diskprediction_local/models/svm_229.pkl
new file mode 100644 (file)
index 0000000..1e9c335
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_229.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_230.pkl b/src/pybind/mgr/diskprediction_local/models/svm_230.pkl
new file mode 100644 (file)
index 0000000..36f8205
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_230.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_234.pkl b/src/pybind/mgr/diskprediction_local/models/svm_234.pkl
new file mode 100644 (file)
index 0000000..199f9ba
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_234.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_235.pkl b/src/pybind/mgr/diskprediction_local/models/svm_235.pkl
new file mode 100644 (file)
index 0000000..d986526
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_235.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_236.pkl b/src/pybind/mgr/diskprediction_local/models/svm_236.pkl
new file mode 100644 (file)
index 0000000..160e22f
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_236.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_239.pkl b/src/pybind/mgr/diskprediction_local/models/svm_239.pkl
new file mode 100644 (file)
index 0000000..8d98572
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_239.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_243.pkl b/src/pybind/mgr/diskprediction_local/models/svm_243.pkl
new file mode 100644 (file)
index 0000000..4fca95e
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_243.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_27.pkl b/src/pybind/mgr/diskprediction_local/models/svm_27.pkl
new file mode 100644 (file)
index 0000000..011974e
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_27.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_3.pkl b/src/pybind/mgr/diskprediction_local/models/svm_3.pkl
new file mode 100644 (file)
index 0000000..e5e97a8
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_3.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_33.pkl b/src/pybind/mgr/diskprediction_local/models/svm_33.pkl
new file mode 100644 (file)
index 0000000..e709d7b
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_33.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_36.pkl b/src/pybind/mgr/diskprediction_local/models/svm_36.pkl
new file mode 100644 (file)
index 0000000..3d87b8b
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_36.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_44.pkl b/src/pybind/mgr/diskprediction_local/models/svm_44.pkl
new file mode 100644 (file)
index 0000000..9abcece
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_44.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_50.pkl b/src/pybind/mgr/diskprediction_local/models/svm_50.pkl
new file mode 100644 (file)
index 0000000..b7ce5ed
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_50.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_57.pkl b/src/pybind/mgr/diskprediction_local/models/svm_57.pkl
new file mode 100644 (file)
index 0000000..fe78328
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_57.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_59.pkl b/src/pybind/mgr/diskprediction_local/models/svm_59.pkl
new file mode 100644 (file)
index 0000000..7621777
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_59.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_6.pkl b/src/pybind/mgr/diskprediction_local/models/svm_6.pkl
new file mode 100644 (file)
index 0000000..4fb09d3
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_6.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_61.pkl b/src/pybind/mgr/diskprediction_local/models/svm_61.pkl
new file mode 100644 (file)
index 0000000..319fc5f
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_61.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_62.pkl b/src/pybind/mgr/diskprediction_local/models/svm_62.pkl
new file mode 100644 (file)
index 0000000..25b21ae
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_62.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_67.pkl b/src/pybind/mgr/diskprediction_local/models/svm_67.pkl
new file mode 100644 (file)
index 0000000..1e6e738
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_67.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_69.pkl b/src/pybind/mgr/diskprediction_local/models/svm_69.pkl
new file mode 100644 (file)
index 0000000..22d349a
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_69.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_71.pkl b/src/pybind/mgr/diskprediction_local/models/svm_71.pkl
new file mode 100644 (file)
index 0000000..e0760ad
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_71.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_72.pkl b/src/pybind/mgr/diskprediction_local/models/svm_72.pkl
new file mode 100644 (file)
index 0000000..5096aa8
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_72.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_78.pkl b/src/pybind/mgr/diskprediction_local/models/svm_78.pkl
new file mode 100644 (file)
index 0000000..7958f3b
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_78.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_79.pkl b/src/pybind/mgr/diskprediction_local/models/svm_79.pkl
new file mode 100644 (file)
index 0000000..2ed3a0f
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_79.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_82.pkl b/src/pybind/mgr/diskprediction_local/models/svm_82.pkl
new file mode 100644 (file)
index 0000000..2e18840
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_82.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_85.pkl b/src/pybind/mgr/diskprediction_local/models/svm_85.pkl
new file mode 100644 (file)
index 0000000..88161af
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_85.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_88.pkl b/src/pybind/mgr/diskprediction_local/models/svm_88.pkl
new file mode 100644 (file)
index 0000000..7156339
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_88.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_93.pkl b/src/pybind/mgr/diskprediction_local/models/svm_93.pkl
new file mode 100644 (file)
index 0000000..703429f
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_93.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/models/svm_97.pkl b/src/pybind/mgr/diskprediction_local/models/svm_97.pkl
new file mode 100644 (file)
index 0000000..9653d20
Binary files /dev/null and b/src/pybind/mgr/diskprediction_local/models/svm_97.pkl differ
diff --git a/src/pybind/mgr/diskprediction_local/module.py b/src/pybind/mgr/diskprediction_local/module.py
new file mode 100644 (file)
index 0000000..80286f4
--- /dev/null
@@ -0,0 +1,255 @@
+"""
+diskprediction with local predictor
+"""
+from datetime import datetime
+import json
+from threading import Event
+import time
+
+from mgr_module import MgrModule, CommandResult
+
+
+TIME_FORMAT = '%Y%m%d-%H%M%S'
+TIME_DAYS = 24*60*60
+TIME_WEEK = TIME_DAYS * 7
+
+
+class Module(MgrModule):
+    OPTIONS = [
+        {
+            'name': 'sleep_interval',
+            'default': str(600),
+        },
+        {
+            'name': 'predict_interval',
+            'default': str(86400),
+        },
+    ]
+
+    COMMANDS = []
+
+    def __init__(self, *args, **kwargs):
+        super(Module, self).__init__(*args, **kwargs)
+        # options
+        for opt in self.OPTIONS:
+            setattr(self, opt['name'], opt['default'])
+        # other
+        self.run = True
+        self.event = Event()
+
+    def refresh_config(self):
+        for opt in self.OPTIONS:
+            setattr(self,
+                    opt['name'],
+                    self.get_config(opt['name']) or opt['default'])
+            self.log.debug(' %s = %s', opt['name'], getattr(self, opt['name']))
+
+    def handle_command(self, _, cmd):
+        self.log.debug('handle_command cmd: %s', cmd)
+        raise NotImplementedError(cmd['prefix'])
+
+    def self_test(self):
+        ret, out, err = self.predict_all_devices()
+        assert ret == 0
+        return 0, 'self test succeed', ''
+
+    def serve(self):
+        self.log.info('Starting diskprediction local module')
+        last_predicted = None
+        ls = self.get_store('last_predicted')
+        if ls:
+            try:
+                last_predicted = datetime.strptime(ls, TIME_FORMAT)
+            except ValueError:
+                pass
+        self.log.debug('Last predicted %s', last_predicted)
+
+        while self.run:
+            self.refresh_config()
+            mode = self.get_option('device_failure_prediction_mode')
+            if mode == 'local':
+                now = datetime.utcnow()
+                if not last_predicted:
+                    next_predicted = now
+                else:
+                    predicted_frequency = int(self.predict_interval) or 86400
+                    seconds = (last_predicted - datetime.utcfromtimestamp(0)).total_seconds()
+                    seconds -= seconds % predicted_frequency
+                    seconds += predicted_frequency
+                    next_predicted = datetime.utcfromtimestamp(seconds)
+                    if last_predicted:
+                        self.log.debug('Last scrape %s, next scrape due %s',
+                                       last_predicted.strftime(TIME_FORMAT),
+                                       next_predicted.strftime(TIME_FORMAT))
+                    else:
+                        self.log.debug('Last scrape never, next scrape due %s',
+                                       next_predicted.strftime(TIME_FORMAT))
+                if now >= next_predicted:
+                    self.predict_all_device()
+                    last_predicted = now
+                    self.set_store('last_predicted', last_predicted.strftime(TIME_FORMAT))
+
+            sleep_interval = int(self.sleep_interval) or 60
+            self.log.debug('Sleeping for %d seconds', sleep_interval)
+            self.event.wait(sleep_interval)
+            self.event.clear()
+
+    def shutdown(self):
+        self.log.info('Stopping')
+        self.run = False
+        self.event.set()
+
+    @staticmethod
+    def _convert_timestamp(predicted_timestamp, life_expectancy_day):
+        """
+        :param predicted_timestamp: unit is nanoseconds
+        :param life_expectancy_day: unit is seconds
+        :return:
+            date format '%Y-%m-%d' ex. 2018-01-01
+        """
+        return datetime.fromtimestamp(
+            predicted_timestamp / (1000 ** 3) + life_expectancy_day).strftime('%Y-%m-%d')
+
+    def _predict_life_expentancy(self, devid):
+        predicted_result = ''
+        from .predictor import get_diskfailurepredictor_path, DiskFailurePredictor
+        health_data = {}
+        predict_datas = []
+        try:
+            r, outb, outs = self.remote('devicehealth', 'show_device_metrics', devid=devid, sample='')
+            if r != 0:
+                self.log.error('failed to get device %s health', devid)
+                health_data = {}
+            else:
+                health_data = json.loads(outb)
+        except Exception as e:
+            self.log.error('failed to get device %s health data due to %s', devid, str(e))
+
+        obj_predictor = DiskFailurePredictor()
+        obj_predictor.initialize("{}/models".format(get_diskfailurepredictor_path()))
+
+        if len(health_data) >= 6:
+            o_keys = sorted(health_data.keys(), reverse=True)
+            for o_key in o_keys:
+                dev_smart = {}
+                s_val = health_data[o_key]
+                ata_smart = s_val.get('ata_smart_attributes', {})
+                for attr in ata_smart.get('table', []):
+                    if attr.get('raw', {}).get('string'):
+                        if str(attr.get('raw', {}).get('string', '0')).isdigit():
+                            dev_smart['smart_%s_raw' % attr.get('id')] = \
+                                int(attr.get('raw', {}).get('string', '0'))
+                        else:
+                            if str(attr.get('raw', {}).get('string', '0')).split(' ')[0].isdigit():
+                                dev_smart['smart_%s_raw' % attr.get('id')] = \
+                                    int(attr.get('raw', {}).get('string',
+                                                                '0').split(' ')[0])
+                            else:
+                                dev_smart['smart_%s_raw' % attr.get('id')] = \
+                                    attr.get('raw', {}).get('value', 0)
+                if s_val.get('power_on_time', {}).get('hours') is not None:
+                    dev_smart['smart_9_raw'] = int(s_val['power_on_time']['hours'])
+                if dev_smart:
+                    predict_datas.append(dev_smart)
+                if len(predict_datas) >= 12:
+                    break
+        else:
+            self.log.error('unable to predict device due to health data records less than 6 days')
+
+        if predict_datas:
+            predicted_result = obj_predictor.predict(predict_datas)
+        return predicted_result
+
+    def predict_life_expentancy(self, devid):
+        result = self._predict_life_expentancy(devid)
+        if result.lower() == 'good':
+            return 0, '>6w', ''
+        elif result.lower() == 'warning':
+            return 0, '>=2w and <=6w', ''
+        elif result.lower() == 'bad':
+            return 0, '<2w', ''
+        else:
+            return 0, 'unknown', ''
+
+    def _reset_device_life_expectancy(self, device_id):
+        result = CommandResult('')
+        self.send_command(result, 'mon', '', json.dumps({
+            'prefix': 'device rm-life-expectancy',
+            'devid': device_id
+        }), '')
+        ret, _, outs = result.wait()
+        if ret != 0:
+            self.log.error(
+                'failed to reset device life expectancy, %s' % outs)
+        return ret
+
+    def _set_device_life_expectancy(self, device_id, from_date, to_date=None):
+        result = CommandResult('')
+
+        if to_date is None:
+            self.send_command(result, 'mon', '', json.dumps({
+                'prefix': 'device set-life-expectancy',
+                'devid': device_id,
+                'from': from_date
+            }), '')
+        else:
+            self.send_command(result, 'mon', '', json.dumps({
+                'prefix': 'device set-life-expectancy',
+                'devid': device_id,
+                'from': from_date,
+                'to': to_date
+            }), '')
+        ret, _, outs = result.wait()
+        if ret != 0:
+            self.log.error(
+                'failed to set device life expectancy, %s' % outs)
+        return ret
+
+    def predict_all_devices(self):
+        devices = self.get('devices').get('devices', [])
+        for devInfo in devices:
+            if not devInfo.get('daemons'):
+                continue
+            if not devInfo.get('devid'):
+                continue
+            result = self._predict_life_expentancy(devInfo['devid'])
+            if result == 'unknown':
+                self._reset_device_life_expectancy(devInfo['devid'])
+                continue
+            predicted = int(time.time() * (1000 ** 3))
+
+            if result.lower() == 'good':
+                life_expectancy_day_min = (TIME_WEEK * 6) + TIME_DAYS
+                life_expectancy_day_max = None
+            elif result.lower() == 'warning':
+                life_expectancy_day_min = (TIME_WEEK * 2)
+                life_expectancy_day_max = (TIME_WEEK * 6)
+            elif result.lower() == 'bad':
+                life_expectancy_day_min = 0
+                life_expectancy_day_max = (TIME_WEEK * 2) - TIME_DAYS
+            else:
+                predicted = None
+                life_expectancy_day_min = None
+                life_expectancy_day_max = None
+
+            if predicted and devInfo['devid'] and life_expectancy_day_min:
+                from_date = None
+                to_date = None
+                try:
+                    if life_expectancy_day_min:
+                        from_date = self._convert_timestamp(predicted, life_expectancy_day_min)
+
+                    if life_expectancy_day_max:
+                        to_date = self._convert_timestamp(predicted, life_expectancy_day_max)
+
+                    self._set_device_life_expectancy(devInfo['devid'], from_date, to_date)
+                    self._logger.info(
+                        'succeed to set device {} life expectancy from: {}, to: {}'.format(
+                            devInfo['devid'], from_date, to_date))
+                except Exception as e:
+                    self._logger.error(
+                        'failed to set device {} life expectancy from: {}, to: {}, {}'.format(
+                            devInfo['devid'], from_date, to_date, str(e)))
+            else:
+                self._reset_device_life_expectancy(devInfo['devid'])
+        return 0, 'succeed to predicted all devices', ''
diff --git a/src/pybind/mgr/diskprediction_local/predictor.py b/src/pybind/mgr/diskprediction_local/predictor.py
new file mode 100644 (file)
index 0000000..bf9b0d7
--- /dev/null
@@ -0,0 +1,265 @@
+"""Sample code for disk failure prediction.
+
+This sample code is a community version for anyone who is interested in Machine
+Learning and care about disk failure.
+
+This class provides a disk failure prediction module. Given models dirpath to
+initialize a predictor instance and then use 6 days data to predict. Predict
+function will return a string to indicate disk failure status: "Good",
+"Warning", "Bad", or "Unknown".
+
+An example code is as follows:
+
+>>> model = disk_failure_predictor.DiskFailurePredictor()
+>>> status = model.initialize("./models")
+>>> if status:
+>>>     model.predict(disk_days)
+'Bad'
+
+
+Provided by ProphetStor Data Services Inc.
+http://www.prophetstor.com/
+
+"""
+
+from __future__ import print_function
+import os
+import json
+import pickle
+
+
+def get_diskfailurepredictor_path():
+    path = os.path.abspath(__file__)
+    dir_path = os.path.dirname(path)
+    return dir_path
+
+
+class DiskFailurePredictor(object):
+    """Disk failure prediction
+
+    This class implements a disk failure prediction module.
+    """
+
+    CONFIG_FILE = "config.json"
+    EXCLUDED_ATTRS = ['smart_9_raw', 'smart_241_raw', 'smart_242_raw']
+
+    def __init__(self):
+        """
+        This function may throw exception due to wrong file operation.
+        """
+
+        self.model_dirpath = ""
+        self.model_context = {}
+
+    def initialize(self, model_dirpath):
+        """
+        Initialize all models.
+
+        Args: None
+
+        Returns:
+            Error message. If all goes well, return an empty string.
+
+        Raises:
+        """
+
+        config_path = os.path.join(model_dirpath, self.CONFIG_FILE)
+        if not os.path.isfile(config_path):
+            return "Missing config file: " + config_path
+        else:
+            with open(config_path) as f_conf:
+                self.model_context = json.load(f_conf)
+
+        for model_name in self.model_context:
+            model_path = os.path.join(model_dirpath, model_name)
+
+            if not os.path.isfile(model_path):
+                return "Missing model file: " + model_path
+
+        self.model_dirpath = model_dirpath
+
+    def __preprocess(self, disk_days):
+        """
+        Preprocess disk attributes.
+
+        Args:
+            disk_days: Refer to function predict(...).
+
+        Returns:
+            new_disk_days: Processed disk days.
+        """
+
+        req_attrs = []
+        new_disk_days = []
+
+        attr_list = set.intersection(*[set(disk_day.keys())
+                                       for disk_day in disk_days])
+        for attr in attr_list:
+            if (attr.startswith('smart_') and attr.endswith('_raw')) and \
+                    attr not in self.EXCLUDED_ATTRS:
+                req_attrs.append(attr)
+
+        for disk_day in disk_days:
+            new_disk_day = {}
+            for attr in req_attrs:
+                if float(disk_day[attr]) >= 0.0:
+                    new_disk_day[attr] = disk_day[attr]
+
+            new_disk_days.append(new_disk_day)
+
+        return new_disk_days
+
+    @staticmethod
+    def __get_diff_attrs(disk_days):
+        """
+        Get 5 days differential attributes.
+
+        Args:
+            disk_days: Refer to function predict(...).
+
+        Returns:
+            attr_list: All S.M.A.R.T. attributes used in given disk. Here we
+                       use intersection set of all disk days.
+
+            diff_disk_days: A list struct comprises 5 dictionaries, each
+                            dictionary contains differential attributes.
+
+        Raises:
+            Exceptions of wrong list/dict operations.
+        """
+
+        all_attrs = [set(disk_day.keys()) for disk_day in disk_days]
+        attr_list = list(set.intersection(*all_attrs))
+        attr_list = disk_days[0].keys()
+        prev_days = disk_days[:-1]
+        curr_days = disk_days[1:]
+        diff_disk_days = []
+
+        for prev, cur in zip(prev_days, curr_days):
+            diff_disk_days.append({attr:(int(cur[attr]) - int(prev[attr]))
+                                   for attr in attr_list})
+
+        return attr_list, diff_disk_days
+
+    def __get_best_models(self, attr_list):
+        """
+        Find the best model from model list according to given attribute list.
+
+        Args:
+            attr_list: All S.M.A.R.T. attributes used in given disk.
+
+        Returns:
+            modelpath: The best model for the given attribute list.
+            model_attrlist: 'Ordered' attribute list of the returned model.
+                            Must be aware that SMART attributes is in order.
+
+        Raises:
+        """
+
+        models = self.model_context.keys()
+
+        scores = []
+        for model_name in models:
+            scores.append(sum(attr in attr_list
+                              for attr in self.model_context[model_name]))
+        max_score = max(scores)
+
+        # Skip if too few matched attributes.
+        if max_score < 3:
+            print("Too few matched attributes")
+            return None
+
+        best_models = {}
+        best_model_indices = [idx for idx, score in enumerate(scores)
+                              if score > max_score - 2]
+        for model_idx in best_model_indices:
+            model_name = list(models)[model_idx]
+            model_path = os.path.join(self.model_dirpath, model_name)
+            model_attrlist = self.model_context[model_name]
+            best_models[model_path] = model_attrlist
+
+        return best_models
+        # return os.path.join(self.model_dirpath, model_name), model_attrlist
+
+    @staticmethod
+    def __get_ordered_attrs(disk_days, model_attrlist):
+        """
+        Return ordered attributes of given disk days.
+
+        Args:
+            disk_days: Unordered disk days.
+            model_attrlist: Model's ordered attribute list.
+
+        Returns:
+            ordered_attrs: Ordered disk days.
+
+        Raises: None
+        """
+
+        ordered_attrs = []
+
+        for one_day in disk_days:
+            one_day_attrs = []
+
+            for attr in model_attrlist:
+                if attr in one_day:
+                    one_day_attrs.append(one_day[attr])
+                else:
+                    one_day_attrs.append(0)
+
+            ordered_attrs.append(one_day_attrs)
+
+        return ordered_attrs
+
+    def predict(self, disk_days):
+        """
+        Predict using given 6-days disk S.M.A.R.T. attributes.
+
+        Args:
+            disk_days: A list struct comprises 6 dictionaries. These
+                       dictionaries store 'consecutive' days of disk SMART
+                       attributes.
+        Returns:
+            A string indicates prediction result. One of following four strings
+            will be returned according to disk failure status:
+            (1) Good : Disk is health
+            (2) Warning : Disk has some symptoms but may not fail immediately
+            (3) Bad : Disk is in danger and data backup is highly recommended
+            (4) Unknown : Not enough data for prediction.
+
+        Raises:
+            Pickle exceptions
+        """
+
+        all_pred = []
+
+        proc_disk_days = self.__preprocess(disk_days)
+        attr_list, diff_data = DiskFailurePredictor.__get_diff_attrs(proc_disk_days)
+        modellist = self.__get_best_models(attr_list)
+        if modellist is None:
+            return "Unknown"
+
+        for modelpath in modellist:
+            model_attrlist = modellist[modelpath]
+            ordered_data = DiskFailurePredictor.__get_ordered_attrs(
+                diff_data, model_attrlist)
+
+            try:
+                with open(modelpath, 'rb') as f_model:
+                    clf = pickle.load(f_model)
+
+            except UnicodeDecodeError:
+                # Compatibility for python3
+                with open(modelpath, 'rb') as f_model:
+                    clf = pickle.load(f_model, encoding='latin1')
+
+            pred = clf.predict(ordered_data)
+
+            all_pred.append(1 if any(pred) else 0)
+
+        score = 2 ** sum(all_pred) - len(modellist)
+        if score > 10:
+            return "Bad"
+        if score > 4:
+            return "Warning"
+        return "Good"