<jupyter_start><jupyter_text>Neural Network - Scaled with StandardScaller<jupyter_code>steps = [('scaler', StandardScaler()),(('neural', MLPClassifier(solver='adam', alpha=1e-5, hidden_layer_sizes=(50, 32), random_state=42, max_iter=500, warm_start=True)))]
pipeline = Pipeline(steps)<jupyter_output><empty_output><jupyter_text>hidden_layer_sizes=(n1, n2,..., nx) n1 = number of neurons in hidden layer_1 nx = number of neurons in hidden layer_x<jupyter_code>neural_scaled = pipeline.fit(X_train, y_train)
#for i in range(len(y_pred)):
#    print(y_pred_prob[i],y_pred[i])
# cv_scores = cross_val_score(pipeline, X, y, cv=5)
# print(cv_scores)

# print("Average 5-Fold CV Score: {}".format(np.mean(cv_scores)))<jupyter_output><empty_output><jupyter_text>Neural Network - Scaled with MinMaxScaller<jupyter_code>steps = [('scaler', MinMaxScaler()),(('neural', MLPClassifier(solver='adam', alpha=1e-5, hidden_layer_sizes=(50, 32), random_state=42, max_iter=1000, warm_start=True)))]
pipeline = Pipeline(steps)<jupyter_output><empty_output><jupyter_text>hidden_layer_sizes=(n1, n2,..., nx) n1 = number of neurons in hidden layer_1 nx = number of neurons in hidden layer_x<jupyter_code>#neural_scaled = pipeline.fit(X_train, y_train)
pipeline.fit(X_train, y_train)
print(neural_scaled)
y_pred = pipeline.predict(X_train) 
accuracy_score(y_train, y_pred)
y_pred_prob = pipeline.predict_proba(X_train)[:,1]
y_scores = cross_val_predict(pipeline, X_train, y_train, cv=5, method='predict_proba' )
y_train_pred = cross_val_predict(pipeline, X_train, y_train, cv=5)
# hack to work around issue #9589 in Scikit-Learn 0.19.0
if y_scores.ndim == 2:
    y_scores = y_scores[:, 1]
# print(y_scores)
# print(np.mean(y_scores))
# for i in range(len(y_pred)):
#     print(y_pred_prob[i],y_pred[i], y_scores[i])
plotRoc(y_train, y_scores)
printcfm(y_train_pred, y_pred, title='confusion matrix')
print(classification_report(y_train_pred, y_pred))
# cv_scores = cross_val_score(pipeline, X_train, y_train, cv=5)
# print(cv_scores)<jupyter_output><empty_output><jupyter_text>Fine-tunning the model. To turn on Fine-tunning:     define ft = 1<jupyter_code>ft = 0<jupyter_output><empty_output><jupyter_text>1 - Grid Search<jupyter_code>if ft == 1 :
    rn = MLPClassifier(max_iter=1000, random_state=42)
    parameters = {'solver': ['lbfgs','adam','sgd'], 'alpha': 10.0 ** -np.arange(1, 7),
                 'hidden_layer_sizes': [x for x in itertools.product((5,10,20,30,60,100),repeat=3)]
                 }
    cv = GridSearchCV(rn, param_grid=parameters, verbose=3, n_jobs=-1)

    scaler = StandardScaler()
    X_train_scaled = scaler.fit_transform(X_train)
    X_test_scaled = scaler.fit_transform(X_test)

    # rf.fit(X_train, y_train);
    cv.fit(X_train_scaled, y_train);
if ft == 1:
    print("Best params: ", cv.best_params_,) 
    print("Best Score: %3.3f" %(cv.best_score_))
    y_pred = cv.predict(X_train_scaled)
    final_model =cv.best_estimator_
    print(final_model)<jupyter_output><empty_output><jupyter_text>Best Model Result (11/2019) - 38 WellsUsing cross validationMLPClassifier(activation='relu', alpha=0.01, batch_size='auto', beta_1=0.9,       beta_2=0.999, early_stopping=False, epsilon=1e-08,       hidden_layer_sizes=(10, 30, 5), learning_rate='constant',       learning_rate_init=0.001, max_iter=1000, momentum=0.9,       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,       solver='adam', tol=0.0001, validation_fraction=0.1, verbose=False,       warm_start=False)  Best Model Result (11/2018) - 38 WellsMLPClassifier(activation='relu', alpha=0.001, batch_size='auto', beta_1=0.9,       beta_2=0.999, early_stopping=False, epsilon=1e-08,       hidden_layer_sizes=(60, 10, 30), learning_rate='constant',       learning_rate_init=0.001, max_iter=1000, momentum=0.9,       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,       solver='lbfgs', tol=0.0001, validation_fraction=0.1, verbose=False,       warm_start=False)  Best Model Result (11/2018) - 89 WellsMLPClassifier(activation='relu', alpha=0.01, batch_size='auto', beta_1=0.9,       beta_2=0.999, early_stopping=False, epsilon=1e-08,       hidden_layer_sizes=(30, 100, 5), learning_rate='constant',       learning_rate_init=0.001, max_iter=1000, momentum=0.9,       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,       solver='lbfgs', tol=0.0001, validation_fraction=0.1, verbose=False,       warm_start=False)  Best Model Result (09/2018) - 89 WellsMLPClassifier(activation='relu', alpha=alpha, batch_size='auto', beta_1=0.9,       beta_2=0.999, early_stopping=False, epsilon=1e-08,       hidden_layer_sizes=(5, 60), learning_rate='constant',       learning_rate_init=0.001, max_iter=1000, momentum=0.9,       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,       solver='lbfgs', tol=0.0001, validation_fraction=0.1, verbose=False,       warm_start=False)  Regularization of the best model   Fill alpha value<jupyter_code>alpha=0.1<jupyter_output><empty_output><jupyter_text>Alpha is a parameter for regularization term, aka penalty term, that combats overfitting by constraining the size of the weights. Increasing alpha may fix high variance (a sign of overfitting) by encouraging smaller weights, resulting in a decision boundary plot that appears with lesser curvatures. Similarly, decreasing alpha may fix high bias (a sign of underfitting) by encouraging larger weights, potentially resulting in a more complicated decision boundary.<jupyter_code>steps = [('scaler', StandardScaler()),(('neural', MLPClassifier(activation='relu', alpha=alpha, batch_size='auto', beta_1=0.9,
       beta_2=0.999, early_stopping=False, epsilon=1e-08,
       hidden_layer_sizes=(50, 32), learning_rate='constant',
       learning_rate_init=0.001, max_iter=1000, momentum=0.9,
       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,
       solver='adam', tol=0.0001, validation_fraction=0.1, verbose=False,
       warm_start=False)))]
pipeline = Pipeline(steps)
#neural_scaled = pipeline.fit(X_train, y_train)
pipeline.fit(X_train, y_train)<jupyter_output><empty_output><jupyter_text>Predicting the Classes in Trainning Set<jupyter_code>y_train_pred = pipeline.predict(X_train) 
y_train_prob = pipeline.predict_proba(X_train)[:,1]
acc_train = accuracy_score(y_train, y_train_pred)
auc_train = roc_auc_score(y_train, y_train_pred)
plotRoc(y_train, y_train_prob)
auc_train = roc_auc_score(y_train, y_train_prob)
printcfm(y_train, y_train_pred, title='confusion matrix')
print(classification_report(y_train, y_train_pred))<jupyter_output>precision    recall  f1-score   support

          0       1.00      1.00      1.00        60
          1       1.00      1.00      1.00        60

avg / total       1.00      1.00      1.00       120<jupyter_text>Precision/Recall Tradeoff<jupyter_code>#y_scores = cross_val_predict(pipeline, X_train, y_train, cv=3, method='predict_proba' )
# print(y_scores)
# print(np.mean(y_scores))
#y_pred_prob
# y_scores.shape
# # hack to work around issue #9589 in Scikit-Learn 0.19.0
# if y_scores.ndim == 2:
#     y_scores = y_scores[:, 1]
precisions, recalls, thresholds = precision_recall_curve(y_train, y_scores)
def plot_precision_recall_vs_threshold(precisions, recalls, thresholds):
    plt.plot(thresholds, precisions[:-1], "b--", label="Precision")
    plt.plot(thresholds, recalls[:-1], "g-", label="Recall")
    plt.xlabel("Threshold")
    plt.legend(loc="upper left")
    plt.ylim([0, 1])
plot_precision_recall_vs_threshold(precisions, recalls, thresholds)
plt.show()
cv_scores = cross_val_score(pipeline, X_train, y_train, cv=3)
print(cv_scores)
print(np.mean(cv_scores))
def plot_precision_vs_recall(precisions, recalls):
    plt.plot(recalls, precisions, "b-", linewidth=2)
    plt.xlabel("Recall", fontsize=16)
    plt.ylabel("Precision", fontsize=16)
    plt.axis([0, 1.01, 0, 1])

plt.figure(figsize=(8, 6))
plot_precision_vs_recall(precisions, recalls)
plt.show()
# precisions, recalls, thresholds = precision_recall_curve(y_train, y_pred_prob)
# def plot_precision_recall_vs_threshold(precisions, recalls, thresholds):
#     plt.plot(thresholds, precisions[:-1], "b--", label="Precision")
#     plt.plot(thresholds, recalls[:-1], "g-", label="Recall")
#     plt.xlabel("Threshold")
#     plt.legend(loc="upper left")
#     plt.ylim([0, 1])
# plot_precision_recall_vs_threshold(precisions, recalls, thresholds)
# plt.show()<jupyter_output><empty_output><jupyter_text>Varying the Threshold for train set<jupyter_code>predict_mine = np.where(y_train_prob > 0.5, 1, 0)
y_train_pred_90 = (y_scores > .5)
precision = precision_score(y_train, y_train_pred_90)
recall = recall_score(y_train, y_train_pred_90)
print(precision, recall)
printcfm(y_train, predict_mine, title='confusion matrix')
print(classification_report(y_train, predict_mine))<jupyter_output>precision    recall  f1-score   support

          0       1.00      1.00      1.00        60
          1       1.00      1.00      1.00        60

avg / total       1.00      1.00      1.00       120<jupyter_text>Evaluating the model with Cross-Validation<jupyter_code>y_pred_prob = pipeline.predict_proba(X_train)[:,1]
y_scores = cross_val_predict(pipeline, X_train, y_train, cv=5, verbose=3, method='predict_proba')
y_train_pred = cross_val_predict(pipeline, X_train, y_train, cv=5, verbose=3)
# hack to work around issue #9589 in Scikit-Learn 0.19.0
if y_scores.ndim == 2:
    y_scores = y_scores[:, 1]
# print(y_scores)
# print(np.mean(y_scores))
plotRoc(y_train, y_scores)
auc_cv = roc_auc_score(y_train, y_scores)
# auc_train = roc_auc_score(y_train, y_train_pred)
# auc_train
printcfm(y_train, y_train_pred, title='confusion matrix')
print(classification_report(y_train, y_train_pred))<jupyter_output>precision    recall  f1-score   support

          0       0.98      0.80      0.88        60
          1       0.83      0.98      0.90        60

avg / total       0.91      0.89      0.89       120<jupyter_text>Evaluating the model with LOO<jupyter_code>loo = LeaveOneOut()
loo.get_n_splits(dfFase1)
for train, test in loo.split(dfFase1):
     print("%s %s" % (train, test))
cv=loo
y_pred_prob = pipeline.predict_proba(X_train)[:,1]
y_scores = cross_val_predict(pipeline, X_train, y_train, cv=cv, verbose=10, method='predict_proba', n_jobs=-1)
y_train_pred = cross_val_predict(pipeline, X_train, y_train, cv=cv, verbose=10)
# hack to work around issue #9589 in Scikit-Learn 0.19.0
if y_scores.ndim == 2:
    y_scores = y_scores[:, 1]
# print(y_scores)
# print(np.mean(y_scores))
plotRoc(y_train, y_scores)
auc_LoO = roc_auc_score(y_train, y_scores)
auc_LoO
printcfm(y_train, y_train_pred, title='confusion matrix')
print(classification_report(y_train, y_train_pred))<jupyter_output>precision    recall  f1-score   support

          0       0.98      0.83      0.90        60
          1       0.86      0.98      0.91        60

avg / total       0.92      0.91      0.91       120<jupyter_text>Evaluating the model with Repeated K fold<jupyter_code>def perform_repeated_cv(X, y , model):
    #set random seed for repeatability
    random.seed(1)

    #set the number of repetitions
    n_reps = 45

    # perform repeated cross validation
    accuracy_scores = np.zeros(n_reps)
    precision_scores=  np.zeros(n_reps)
    recall_scores =  np.zeros(n_reps)
    auc_scores =  np.zeros(n_reps)
    #result_pred = pd.DataFrame(index=np.arange(30))
    result_pred = y
    
    ##############################
    tprs = []
    aucs = []
    mean_fpr = np.linspace(0, 1, 100)
    fig = plt.figure(figsize=(20, 10))
    ###############################

    for u in range(n_reps):

        #randomly shuffle the dataset
        indices = np.arange(X.shape[0])
        np.random.shuffle(indices)
#         X = X[indices]
#         y = y[indices] #dataset has been randomly shuffled
        X = X.iloc[indices]
        y = y.iloc[indices] #dataset has been randomly shuffled

        #initialize vector to keep predictions from all folds of the cross-validation
        y_predicted = np.zeros(y.shape)
        probas = np.zeros(y.shape)

        #perform 10-fold cross validation
        kf = KFold(n_splits=4 , random_state=142)
        for train, test in kf.split(X):

            #split the dataset into training and testing
#             X_train = X[train]
#             X_test = X[test]
#             y_train = y[train]
#             y_test = y[test]
            X_train = X.iloc[train]
            X_test = X.iloc[test]
            y_train = y.iloc[train]
            y_test = y.iloc[test]

#             #standardization
#             scaler = preprocessing.StandardScaler().fit(X_train)
#             X_train = scaler.transform(X_train)
#             X_test = scaler.transform(X_test)

            #train model
            clf = model
            clf.fit(X_train, y_train)

            #make predictions on the testing set
            y_predicted[test] = clf.predict(X_test)
#            print(y_predicted[test],y_test,type(y_predicted))
            #y_train_pred_array = np.append(y_train_pred_array,y_train_pred)
#            print(result_pred)



            
            ###############################plot
#             probas_ = clf.predict_proba(X_test)
            probas[test] = clf.predict_proba(X_test)[:, 1]
#             print(probas[test], type(probas), probas.size)
         
#        print(y,y_predicted)
        #result_pred = y
        df_pred = pd.DataFrame(y_predicted, index=y.index,columns=[u])
        result_pred = pd.concat([result_pred, df_pred], axis=1) 
        

                
    
        # Compute ROC curve and area the curve
        fpr, tpr, thresholds = roc_curve(y, probas)
        tprs.append(interp(mean_fpr, fpr, tpr))
        tprs[-1][0] = 0.0
        #roc_auc = auc(fpr, tpr) - Change to obtain AUC by predict proba
#06/11 - 23:26                roc_auc = roc_auc_score(y, y_predicted)
        roc_auc = roc_auc_score(y, probas)
        aucs.append(roc_auc)
        plt.plot(fpr, tpr, lw=1, alpha=0.3,
        label='ROC fold %d (AUC = %0.2f)' % (u, roc_auc))

            
            ################################

        #record scores
        accuracy_scores[u] = accuracy_score(y, y_predicted)
        precision_scores[u] = precision_score(y, y_predicted)
        recall_scores[u]  = recall_score(y, y_predicted)
#06/11 - 18:39                auc_scores[u] = roc_auc_score(y, y_predicted)
        auc_scores[u] = roc_auc_score(y, probas)
    ###############################plot
#    print(result_pred)
    
    plt.plot([0, 1], [0, 1], linestyle='--', lw=2, color='r',
    label='Chance', alpha=.8)

    mean_tpr = np.mean(tprs, axis=0)
    mean_tpr[-1] = 1.0
#     mean_auc = auc(mean_fpr, mean_tpr)
    mean_auc = np.mean(aucs)
    std_auc = np.std(aucs)
    plt.plot(mean_fpr, mean_tpr, color='b',
             label=r'Mean ROC (AUC = %0.2f $\pm$ %0.2f)' % (mean_auc, std_auc),
             lw=2, alpha=.8)


    std_tpr = np.std(tprs, axis=0)
    tprs_upper = np.minimum(mean_tpr + std_tpr, 1)
    tprs_lower = np.maximum(mean_tpr - std_tpr, 0)
    plt.fill_between(mean_fpr, tprs_lower, tprs_upper, color='grey', alpha=.2,
                     label=r'$\pm$ 1 std. dev.')

    plt.xlim([-0.05, 1.05])
    plt.ylim([-0.05, 1.05])
    plt.xlabel('False Positive Rate')
    plt.ylabel('True Positive Rate')
    plt.title('Receiver operating characteristic example')
    #plt.legend(loc="lower right")
    plt.legend(loc='upper center', bbox_to_anchor=(0.5, -0.05),
               fancybox=True, shadow=True, ncol=5)
    plt.show()
    ################################
    
    #return all scores
    return accuracy_scores, precision_scores, recall_scores, auc_scores, result_pred
accuracy_scores, precision_scores, recall_scores, auc_scores, result_pred = perform_repeated_cv(X_train, y_train, pipeline)
print(accuracy_scores, accuracy_scores.size)
print(precision_scores, recall_scores)
print(auc_scores, auc_scores.size)
fig = plt.figure(figsize=(20, 10))
plt.plot(auc_scores, '--o')
plt.legend(loc='lower right')
plt.ylabel('AUC', fontsize=20);
plt.xlabel('Repetições', fontsize=20);
plt.tick_params(axis='both', which='major', labelsize=20);
plt.tick_params(axis='both', which='minor', labelsize=18);
#plt.xlim([0, 18])
#plt.ylim([0.5, 1])
plt.legend(('Acurácia', 'AUC'), loc='lower right', prop={'size': 20})
plt.show()
auc_scores.mean()
auc_scores.std()
print("Accuracy: %0.2f (+/- %0.2f)" % (np.mean(auc_scores), np.std(auc_scores)))
#result_pred.to_csv('result_kfold_MLP.csv', encoding='utf-8')<jupyter_output><empty_output><jupyter_text>Predicting the Classes in Test Set<jupyter_code>pipeline.fit(X_train, y_train)
y_pred = pipeline.predict(X_test)
y_pred_prob = pipeline.predict_proba(X_test)[:,1]
plotRoc(y_test, y_pred_prob)
auc_test = roc_auc_score(y_test, y_pred_prob)
printcfm(y_test, y_pred, title='confusion matrix')
print(classification_report(y_test, y_pred))<jupyter_output>precision    recall  f1-score   support

          0       0.88      0.88      0.88        25
          1       0.73      0.73      0.73        11

avg / total       0.83      0.83      0.83        36<jupyter_text>Varying the Threshold for test set<jupyter_code>predict_mine = np.where(y_pred_prob > .0, 1, 0)
printcfm(y_test, predict_mine, title='confusion matrix')
print(classification_report(y_test, predict_mine))<jupyter_output>precision    recall  f1-score   support

          0       0.00      0.00      0.00        25
          1       0.31      1.00      0.47        11

avg / total       0.09      0.31      0.14        36<jupyter_text>Results<jupyter_code>print("alpha: ", alpha)
print("AUC Train: %3.3f" % (auc_train))
print("AUC Repeated k-fold: %0.2f (+/- %0.2f)" % (np.mean(auc_scores), np.std(auc_scores)))
print("AUC LoO: %3.3f" % (auc_LoO))
print("AUC test: %3.3f" % (auc_test))
print("AUC cv: %3.3f" % (auc_cv))
#print("Accuracy Train: %3.2f%%" % (acc_train*100))
#print("Accuracy Test %3.2f%%" % (acc_test*100))<jupyter_output>alpha:  0.1
AUC Train: 1.000
AUC Repeated k-fold: 0.89 (+/- 0.02)
AUC LoO: 0.915
AUC test: 0.880
AUC cv: 0.928<jupyter_text>Draft<jupyter_code>#  validation curve off
vc = 0
if vc == 1:
    #X=np.concatenate((X_train_scaled,X_test_scaled),axis=0)
    scaler = StandardScaler()
    X_train_scaled = scaler.fit_transform(X_train)
    X=X_train_scaled
    # print(X)
    #y=np.append(y_train,y_test)
    y=y_train
    # print(y)
    param_range =  10.0 ** np.arange(-10, 10)
    final_model = MLPClassifier(activation='relu', alpha=alpha, batch_size='auto', beta_1=0.9,
       beta_2=0.999, early_stopping=False, epsilon=1e-08,
       hidden_layer_sizes=(50, 32), learning_rate='constant',
       learning_rate_init=0.001, max_iter=1000, momentum=0.9,
       nesterovs_momentum=True, power_t=0.5, random_state=42, shuffle=True,
       solver='adam', tol=0.0001, validation_fraction=0.1, verbose=False,
       warm_start=False)
if vc == 1:

    print(__doc__)

    plt.rcParams["figure.figsize"] = (20,10)
    plt.rcParams.update({'font.size': 20})
    plt.grid(True,which="both", linestyle='--')
    
    train_scores, test_scores = validation_curve(
        final_model, X, y, param_name="alpha", param_range=param_range,
        cv=10, scoring="roc_auc", n_jobs=-1)

    train_scores_mean = np.mean(train_scores, axis=1)
    train_scores_std = np.std(train_scores, axis=1)
    test_scores_mean = np.mean(test_scores, axis=1)
    test_scores_std = np.std(test_scores, axis=1)

    plt.title("Validation Curve with RF")
    plt.xlabel("alpha")
    plt.ylabel("AUC")
    #plt.ylim(0.0, 1.1)
    #plt.xlim(-1, 22)
    lw = 2
    plt.semilogx(param_range, train_scores_mean, label="Training score",
                 color="darkorange", lw=lw)
    plt.fill_between(param_range, train_scores_mean - train_scores_std,
                     train_scores_mean + train_scores_std, alpha=0.2,
                     color="darkorange", lw=lw)
    plt.semilogx(param_range, test_scores_mean, label="Cross-validation score",
                 color="navy", lw=lw)
    plt.fill_between(param_range, test_scores_mean - test_scores_std,
                     test_scores_mean + test_scores_std, alpha=0.2,
                     color="navy", lw=lw)
    plt.legend(loc="best")
    plt.show()
if vc == 1:
    print(__doc__)

    plt.rcParams["figure.figsize"] = (20,10)
    plt.rcParams.update({'font.size': 20})
    plt.grid(True,which="both", linestyle='--')
    
    train_scores, test_scores = validation_curve(
        final_model, X, y, param_name="alpha", param_range=param_range,
        cv=10, scoring="accuracy", n_jobs=-1)
    
    train_scores_mean = np.mean(train_scores, axis=1)
    train_scores_std = np.std(train_scores, axis=1)
    test_scores_mean = np.mean(test_scores, axis=1)
    test_scores_std = np.std(test_scores, axis=1)

    plt.title("Validation Curve with SVC")
    plt.xlabel("$\gamma$")
    plt.ylabel("Accuracy")
    #plt.ylim(0.0, 1.1)
    #plt.xlim(-1, 22)
    lw = 2
    
    plt.semilogx(param_range, train_scores_mean, label="Treino",
                 color="darkorange", lw=lw)
 
    plt.fill_between(param_range, train_scores_mean - train_scores_std,
                     train_scores_mean + train_scores_std, alpha=0.2,
                     color="darkorange", lw=lw)
    plt.semilogx(param_range, test_scores_mean, label="Validação cruzada",
                 color="navy", lw=lw)

    plt.fill_between(param_range, test_scores_mean - test_scores_std,
                     test_scores_mean + test_scores_std, alpha=0.2,
                     color="navy", lw=lw)
    plt.legend(loc="best")
    plt.show()
np.arange(-1, 10)<jupyter_output><empty_output><jupyter_text>Export results<jupyter_code>export = 1
MLP_df = pd.concat([X_test, y_test], axis=1)  # features and actual
MLP_df['Predicted'] = y_pred  # creates a predicted column to the complete_df, now you'll have features, actual, and predicted
MLP_df
if export == 1:
    MLP_df.to_csv('MLP_results.csv', encoding='utf-8')<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.1388156099335941, 'fraction_numerical': 0.03970708632766306, 'mean_word_length': 3.7365359758724686, 'pattern_counts': {'":': 0, '<': 70, '<?xml version=': 0, '>': 73, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 12, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '19', 'dir': 'jupyter-structured-clean-dedup', 'id': '507373', 'license': 'MIT', 'n_tokens_mistral': 8792, 'n_tokens_neox': 8068, 'n_words': 1487, 'path': 'Model-Study/mlModelsMlpKFoldLooRepeated.ipynb', 'repo_name': 'giovanimachado/masterOfScience', 'size': '21986'}