# import zsys import ztools as zt import ztools_str as zstr import ztools_web as zweb import ztools_data as zdat import zpd_talib as zta import ztop_ai as zai #----------------------- #1 fsr0 = 'dat/ccpp_' print('#1', fsr0) xlst, ysgn = ['AT', 'V', 'AP', 'RH'], 'PE' x_train, x_test, y_train, y_test = zai.ai_dat_rd(fsr0) funSgn, ftg = 'svm', 'tmp/ccpp_svm.pkl' #2 print('\n#2,mx_svm.wr') tim0 = arrow.now() zai.ai_f_mxWr(ftg, funSgn, x_train, y_train) tn = zt.timNSec('', tim0, True) #3 tim0 = arrow.now() print('\n#3,mx_svm.rd') mx = joblib.load(ftg) tn = zt.timNSec('', tim0, True) #4 print('\n#4,mx_svm')
from sklearn import metrics from sklearn.model_selection import cross_val_predict # import zsys import ztools as zt import ztools_str as zstr import ztools_web as zweb import ztools_data as zdat import ztop_ai as zai import zpd_talib as zta # #----------------------- #1 fsr0 = 'dat/ccpp_' print('#2,', fsr0) #2 k0 = 1 print('\n#2,k0', k0) x_train, x_test, y_train, y_test = zai.ai_dat_rd(fsr0, k0, True) #3 k0 = 10 print('\n#3,k0', k0) x_train, x_test, y_train, y_test = zai.ai_dat_rd(fsr0, k0, True) #----------------------- print('\nok!')