code: def test_oof_pred_bag_mode(self):
      S_test_temp = np.zeros((X_test.shape[0], n_folds))
      # Usind StratifiedKFold because by defauld cross_val_predict uses StratifiedKFold
      kf = StratifiedKFold(
          n_splits=n_folds, shuffle=False, random_state=0
      )
      for fold_counter, (tr_index, te_index) in enumerate(
          kf.split(X_train, y_train)
      ):
          # Split data and target
          X_tr = X_train[tr_index]
          y_tr = y_train[tr_index]
          X_te = X_train[te_index]
          y_te = y_train[te_index]
          model = LogisticRegression(
              random_state=0, solver="liblinear", multi_class="ovr"
          )
          _ = model.fit(X_tr, y_tr)
          S_test_temp[:, fold_counter] = model.predict(X_test)
      S_test_1 = st.mode(S_test_temp, axis=1)[0]
  
      model = LogisticRegression(
          random_state=0, solver="liblinear", multi_class="ovr"
      )
      S_train_1 = cross_val_predict(
          model,
          X_train,
          y=y_train,
          cv=n_folds,
          n_jobs=1,
          verbose=0,
          method="predict",
      ).reshape(-1, 1)
  
      models = [
          LogisticRegression(
              random_state=0, solver="liblinear", multi_class="ovr"
          )
      ]
      S_train_2, S_test_2 = stacking(
          models,
          X_train,
          y_train,
          X_test,
          regression=False,
          n_folds=n_folds,
          shuffle=False,
          save_dir=temp_dir,
          mode="oof_pred_bag",
          random_state=0,
          verbose=0,
          stratified=True,
      )
  
      # Load OOF from file
      # Normally if cleaning is performed there is only one .npy file at given moment
      # But if we have no cleaning there may be more then one file so we take the latest
      file_name = sorted(glob.glob(os.path.join(temp_dir, "*.npy")))[
          -1
      ]  # take the latest file
      S = np.load(file_name, allow_pickle=True)
      S_train_3 = S[0]
      S_test_3 = S[1]
  
      assert_array_equal(S_train_1, S_train_2)
      assert_array_equal(S_test_1, S_test_2)
  
      assert_array_equal(S_train_1, S_train_3)
      assert_array_equal(S_test_1, S_test_3)
  
imports: from __future__ import print_function
  from __future__ import division
  import unittest
  from numpy.testing import assert_array_equal
  from numpy.testing import assert_equal
  import os
  import glob
  import numpy
  import scipy.stats
  from sklearn.model_selection import cross_val_predict
  from sklearn.model_selection import cross_val_score
  from sklearn.model_selection import StratifiedKFold
  from sklearn.datasets import make_classification
  from sklearn.metrics import accuracy_score
  from sklearn.metrics import log_loss
  from sklearn.metrics import make_scorer
  from sklearn.linear_model import LogisticRegression
  from sklearn.naive_bayes import GaussianNB
  from vecstack import stacking
label_desc: Use image node_id 7 for calling the TestFuncClassificationMulticlass obj's underlying member method code with example usage: obj.test_oof_pred_bag_mode() without return types