OSCR

SHAP analysis of an improved EEG-based mental workload classification framework: utilizing data augmentation and explainable AI.

Code ↔ Paper

6 matches between paragraphs of the paper and lines of its authors' code, computed by the harvester (lexical-v1). Click a colored paragraph or line to see its counterpart.

The 6 matches
  1. [1] § Results › SHAP analysis ↔ code_with_smote.py.py, lines 190–298 · score 0.65 · Local Explanation Summary, Gradient Explainer, Global Feature Importance, SHAP, training, Class
  2. [2] § Results › SHAP analysis ↔ code_without_smote.py.py, lines 200–308 · score 0.65 · Local Explanation Summary, Gradient Explainer, Global Feature Importance, SHAP, training, Class
  3. [3] § Results ↔ code_with_smote.py.py, lines 343–397 · score 0.60 · loss curve, confusion matrix, validation accuracy, epochs, SMOTE, trained
  4. [4] § Results ↔ code_without_smote.py.py, lines 311–400 · score 0.59 · loss curve, confusion matrix, validation accuracy, epochs, trained, model
  5. [5] § Methodology › EEGNet model ↔ code_with_smote.py.py, lines 82–104 · score 0.53 · batch normalization, ELU, dropout, kernel, separable, EEGNet
  6. [6] § Methodology › EEGNet model ↔ code_without_smote.py.py, lines 53–75 · score 0.53 · batch normalization, ELU, dropout, kernel, separable, EEGNet

Paper

Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC

The paper is loaded when this pane is shown.

The authors' code

Python · 399 lines · 16 KB · no license · 3 matches

  1. import itertools
  2. import os
  3. import numpy as np
  4. import pandas as pd
  5. import mne
  6. import warnings
  7. import time
  8. import tensorflow as tf
  9. from scipy.io import loadmat
  10. from sklearn.utils import shuffle
  11. from sklearn.model_selection import train_test_split
  12. from sklearn.metrics import classification_report, confusion_matrix, precision_score, recall_score, f1_score
  13. from tensorflow.keras.models import Model
  14. from tensorflow.keras.layers import Dense, Activation, Permute, Dropout, Conv2D, MaxPooling2D, AveragePooling2D, SeparableConv2D, DepthwiseConv2D, BatchNormalization, SpatialDropout2D, Input, Flatten
  15. from tensorflow.keras.regularizers import l1_l2
  16. from tensorflow.keras.constraints import max_norm
  17. from tensorflow.keras.utils import to_categorical
  18. from tensorflow.keras.callbacks import EarlyStopping, ReduceLROnPlateau
  19. from tensorflow.keras.optimizers import Adam
  20. import shap
  21. import matplotlib.pyplot as plt
  22. # Suppress warnings
  23. warnings.filterwarnings('ignore')
  24. # Set random seeds
  25. np.random.seed(42)
  26. tf.random.set_seed(42)
  27. # Load the Dataset
  28. def load_data(data_path, tasks, n_subs, n_sessions):
  29. x, y = [], []
  30. for sub_n, session_n in itertools.product(range(n_subs), range(n_sessions)):
  31. epochs_data, labels = [], []
  32. for lab_idx, level in enumerate(tasks):
  33. sub = 'P{0:02d}'.format(sub_n + 1)
  34. sess = f'S{session_n + 1}'
  35. path = os.path.join(os.path.join(data_path, sub), sess) + f'/eeg/alldata_sbj{str(sub_n + 1).zfill(2)}_sess{session_n + 1}_{level}.set'
  36. epochs = mne.io.read_epochs_eeglab(path, verbose=False)
  37. epochs.pick_channels(channel_names)
  38. tmp = epochs.get_data()
  39. epochs_data.extend(tmp)
  40. labels.extend([lab_idx] * len(tmp))
  41. x.extend(epochs_data)
  42. y.extend(labels)
  43. return np.array(x), np.array(y)
  44. # SMOTE Function
  45. from imblearn.over_sampling import SMOTE
  46. def apply_smote_3d(X, y, target_ratio=2.0):
  47. """
  48. Applies SMOTE to EEG data.
  49. Parameters:
  50. X (numpy array): Shape (samples, channels, time points, 1)
  51. y (numpy array): Class labels (1D array)
  52. target_ratio (float): Desired increase factor for each class.
  53. Returns:
  54. X_resampled, y_resampled: Augmented dataset
  55. """
  56. n_samples, n_channels, n_timepoints, _ = X.shape
  57. # Flatten EEG data for SMOTE
  58. X_flattened = X.reshape(n_samples, -1) # Shape: (samples, channels*timepoints)
  59. # Determine sampling strategy
  60. class_counts = np.bincount(y)
  61. target_samples = {cls: int(count * target_ratio) for cls, count in enumerate(class_counts)}
  62. smote = SMOTE(sampling_strategy=target_samples, random_state=42)
  63. X_resampled, y_resampled = smote.fit_resample(X_flattened, y)
  64. # Reshape back to 3D EEG format
  65. X_resampled = X_resampled.reshape(-1, n_channels, n_timepoints, 1)
  66. return X_resampled, y_resampled
  67. # EEGNet Model Definition
  68. def build_eegnet(nb_classes, Chans=61, Samples=500, dropoutRate=0.5, kernLength=64, F1=64, D=4, F2=128):
  69. input1 = Input(shape=(Chans, Samples, 1))
  70. block1 = Conv2D(F1, (1, kernLength), padding='same', use_bias=False)(input1)
  71. block1 = BatchNormalization()(block1)
  72. block1 = DepthwiseConv2D((Chans, 1), use_bias=False, depth_multiplier=D, depthwise_constraint=max_norm(1.))(block1)
  73. block1 = BatchNormalization()(block1)
  74. block1 = Activation('elu')(block1)
  75. block1 = AveragePooling2D((1, 4))(block1)
  76. block1 = Dropout(dropoutRate)(block1)
  77. block2 = SeparableConv2D(F2, (1, 16), use_bias=False, padding='same')(block1)
  78. block2 = BatchNormalization()(block2)
  79. block2 = Activation('elu')(block2)
  80. block2 = AveragePooling2D((1, 8))(block2)
  81. block2 = Dropout(dropoutRate)(block2)
  82. flatten = Flatten(name='flatten')(block2)
  83. dense = Dense(nb_classes, name='dense', kernel_constraint=max_norm(0.25))(flatten)
  84. softmax = Activation('softmax', name='softmax')(dense)
  85. return Model(inputs=input1, outputs=softmax)
  86. # Train the Model
  87. def train_model(model, X_train, y_train, X_test, y_test, batch_size=64, epochs=50):
  88. lr_scheduler = ReduceLROnPlateau(monitor='val_loss', factor=0.1, patience=10, verbose=1)
  89. early_stopping = EarlyStopping(monitor='val_loss', patience=20, restore_best_weights=True)
  90. history = model.fit(
  91. X_train, y_train,
  92. batch_size=batch_size,
  93. epochs=epochs,
  94. validation_data=(X_test, y_test),
  95. callbacks=[lr_scheduler, early_stopping],
  96. verbose=1
  97. )
  98. return history
  99. # Evaluate the Model
  100. def evaluate_model(model, X_test, y_test):
  101. y_pred = model.predict(X_test)
  102. y_pred_classes = np.argmax(y_pred, axis=1)
  103. y_true_classes = np.argmax(y_test, axis=1)
  104. # Calculate metrics
  105. precision = precision_score(y_true_classes, y_pred_classes, average='weighted')
  106. recall = recall_score(y_true_classes, y_pred_classes, average='weighted')
  107. f1 = f1_score(y_true_classes, y_pred_classes, average='weighted')
  108. print("Classification Report:")
  109. print(classification_report(y_true_classes, y_pred_classes))
  110. print("Confusion Matrix:")
  111. print(confusion_matrix(y_true_classes, y_pred_classes))
  112. return precision, recall, f1
  113. # Plot and Save Accuracy and Loss Curves
  114. def plot_accuracy_loss_curves(history, trial):
  115. plt.figure(figsize=(12, 6))
  116. # Plot accuracy
  117. plt.subplot(1, 2, 1)
  118. plt.plot(history.history['accuracy'], label='Train Accuracy')
  119. plt.plot(history.history['val_accuracy'], label='Validation Accuracy')
  120. plt.title(f'Trial {trial + 1} - Accuracy Curves')
  121. plt.xlabel('Epoch')
  122. plt.ylabel('Accuracy')
  123. plt.legend()
  124. # Plot loss
  125. plt.subplot(1, 2, 2)
  126. plt.plot(history.history['loss'], label='Train Loss')
  127. plt.plot(history.history['val_loss'], label='Validation Loss')
  128. plt.title(f'Trial {trial + 1} - Loss Curves')
  129. plt.xlabel('Epoch')
  130. plt.ylabel('Loss')
  131. plt.legend()
  132. plt.tight_layout()
  133. plt.savefig(f'Trial_{trial + 1}_Accuracy_Loss_Curves.png')
  134. plt.close()
  135. # Plot and Save Confusion Matrix
  136. def plot_confusion_matrix(model, X_test, y_test, trial):
  137. y_pred = model.predict(X_test)
  138. y_pred_classes = np.argmax(y_pred, axis=1)
  139. y_true_classes = np.argmax(y_test, axis=1)
  140. cm = confusion_matrix(y_true_classes, y_pred_classes)
  141. plt.figure(figsize=(8, 6))
  142. plt.imshow(cm, interpolation='nearest', cmap=plt.cm.Blues)
  143. plt.title(f'Trial {trial + 1} - Confusion Matrix')
  144. plt.colorbar()
  145. tick_marks = np.arange(len(np.unique(y_true_classes)))
  146. plt.xticks(tick_marks, np.unique(y_true_classes))
  147. plt.yticks(tick_marks, np.unique(y_true_classes))
  148. plt.xlabel('Predicted Label')
  149. plt.ylabel('True Label')
  150. for i, j in itertools.product(range(cm.shape[0]), range(cm.shape[1])):
  151. plt.text(j, i, cm[i, j], horizontalalignment="center", color="white" if cm[i, j] > cm.max() / 2 else "black")
  152. plt.tight_layout()
  153. plt.savefig(f'Trial_{trial + 1}_Confusion_Matrix.png')
  154. plt.close()
  155. # SHAP Analysis Function
  156. def shap_analysis(model, X_train, X_test, output_dir, sample_size=50):
  157. # Create output directory if it doesn't exist
  158. os.makedirs(output_dir, exist_ok=True)
  159. print(f"Plots will be saved to: {os.path.abspath(output_dir)}")
  160. # Explain the model's predictions using SHAP
  161. explainer = shap.GradientExplainer(model, X_train[:sample_size])
  162. shap_values = explainer.shap_values(X_test[:sample_size])
  163. # Debug: Check SHAP values shape
  164. print("SHAP values shape:", np.array(shap_values).shape)
  165. # Aggregate SHAP values across the time dimension
  166. shap_values_aggregated = [np.mean(shap_values[class_idx], axis=2) for class_idx in range(len(shap_values))] # Shape: (3, 50, 11)
  167. shap_values_aggregated = [np.squeeze(shap_values_aggregated[class_idx]) for class_idx in range(len(shap_values_aggregated))] # Remove the last dimension
  168. # Aggregate X_test across the time dimension
  169. X_test_aggregated = np.mean(X_test[:sample_size], axis=2) # Shape: (50, 11, 1)
  170. X_test_aggregated = np.squeeze(X_test_aggregated) # Remove the last dimension
  171. # Save SHAP summary plot for each class
  172. print("Saving SHAP summary plot...")
  173. for class_idx in range(len(shap_values_aggregated)):
  174. # Select SHAP values for the current class
  175. shap_values_class = shap_values_aggregated[class_idx] # Shape: (50, 11)
  176. # Plot SHAP summary for the current class
  177. shap.summary_plot(shap_values_class, X_test_aggregated, plot_type="bar", feature_names=channel_names,max_display=61, show=False)
  178. plt.savefig(os.path.join(output_dir, f"shap_summary_plot_class_{class_idx}.png"), dpi=300, bbox_inches='tight')
  179. plt.close()
  180. print("SHAP summary plots saved.")
  181. # Save SHAP image plot
  182. print("Saving SHAP image plot...")
  183. plt.figure(figsize=(14, 12)) # Set figure size
  184. shap.image_plot(shap_values, X_test[:sample_size], show=False)
  185. plt.savefig(os.path.join(output_dir, "shap_image_plot.svg"), bbox_inches='tight')
  186. plt.close()
  187. print("SHAP image plot saved.")
  188. # Save SHAP heatmap for a sample
  189. print("Saving SHAP heatmap...")
  190. sample_idx = 9 # Choose a sample index
  191. shap_values_np = np.array(shap_values)
  192. if len(shap_values_np.shape) == 5:
  193. shap_values_sample = shap_values_np[0, sample_idx, :, :, 0] # Select first class
  194. else:
  195. shap_values_sample = shap_values_np[sample_idx, :, :, 0]
  196. plt.imshow(shap_values_sample, aspect='auto', cmap='RdBu')
  197. plt.colorbar()
  198. plt.xlabel("Time")
  199. plt.ylabel("Channels")
  200. plt.title(f"SHAP Heatmap for Sample {sample_idx}")
  201. plt.savefig(os.path.join(output_dir, "shap_heatmap.png"), dpi=300, bbox_inches='tight')
  202. plt.close()
  203. print("SHAP heatmap saved.")
  204. # Save SHAP dependence plot for each feature
  205. print("Saving SHAP dependence plots...")
  206. for feature_idx in range(X_test_aggregated.shape[1]):
  207. shap.dependence_plot(
  208. feature_idx,
  209. shap_values_aggregated[0], # Use SHAP values for the first class
  210. X_test_aggregated,
  211. feature_names=channel_names,
  212. show=False
  213. )
  214. plt.savefig(os.path.join(output_dir, f"shap_dependence_plot_feature_{feature_idx}.png"), dpi=300, bbox_inches='tight')
  215. plt.close()
  216. print("SHAP dependence plots saved.")
  217. # Save SHAP class comparison plot
  218. print("Saving SHAP class comparison plot...")
  219. shap.summary_plot(shap_values_aggregated, X_test_aggregated, plot_type="bar", feature_names=channel_names, max_display=61,show=False)
  220. plt.savefig(os.path.join(output_dir, "shap_class_comparison_plot.png"), dpi=300, bbox_inches='tight')
  221. plt.close()
  222. print("SHAP class comparison plot saved.")
  223. # Save Global Feature Importance Plot
  224. print("Saving Global Feature Importance Plot...")
  225. # Aggregate SHAP values across time and samples
  226. shap_values_global = np.mean(np.abs(shap_values), axis=(1, 3)) # Shape: (3, 11)
  227. shap_values_global = np.squeeze(shap_values_global) # Remove the last dimension
  228. # Plot global feature importance
  229. shap.summary_plot(shap_values_global, X_test_aggregated, plot_type="bar", feature_names=channel_names, max_display=61,show=False)
  230. plt.savefig(os.path.join(output_dir, "global_feature_importance.png"), dpi=300, bbox_inches='tight')
  231. plt.close()
  232. print("Global Feature Importance Plot saved.")
  233. # Save Local Explanation Summary Plot
  234. print("Saving Local Explanation Summary Plot...")
  235. # Aggregate SHAP values across time and samples for the first class
  236. shap_values_local = np.mean(shap_values[0], axis=2) # Shape: (50, 11)
  237. shap_values_local = np.squeeze(shap_values_local) # Remove the last dimension
  238. # Plot local explanation summary for the first class
  239. shap.summary_plot(shap_values_local, X_test_aggregated, plot_type="dot", feature_names=channel_names, max_display=61,show=False)
  240. plt.savefig(os.path.join(output_dir, "local_explanation_summary.png"), dpi=300, bbox_inches='tight')
  241. plt.close()
  242. print("Local Explanation Summary Plot saved.")
  243. print("All SHAP plots saved successfully!")
  244. # Main Workflow
  245. if __name__ == "__main__":
  246. # Dataset Parameters
  247. data_path = 'Dataset_path'
  248. tasks = ['MATBeasy', 'MATBmed', 'MATBdiff']
  249. n_subs, n_sessions = 15, 2
  250. channel_names =['Fp1', 'Fz', 'F3', 'F7', 'FT9', 'FC5', 'FC1', 'C3', 'T7', 'CP5', 'CP1', 'Pz', 'P3', 'P7', 'O1', 'Oz', 'O2', 'P4', 'P8', 'TP10', 'CP6', 'CP2', 'FCz', 'C4', 'T8', 'FT8', 'FC6', 'FC2', 'F4', 'F8', 'Fp2', 'AF7', 'AF3', 'AFz', 'F1', 'F5', 'FT7', 'FC3', 'C1', 'C5', 'TP7', 'CP3', 'P1', 'P5', 'PO7', 'PO3', 'POz', 'PO4', 'PO8', 'P6', 'P2', 'CPz', 'CP4', 'TP8', 'C6', 'C2', 'FC4', 'FT10', 'F6', 'AF8', 'AF4','F2']
  251. # Load Data
  252. X, Y = load_data(data_path, tasks, n_subs, n_sessions)
  253. X = (X - np.mean(X, axis=(0, 2), keepdims=True)) / (np.std(X, axis=(0, 2), keepdims=True) + 1e-10)
  254. X, Y = shuffle(X, Y, random_state=42)
  255. X = X.reshape((X.shape[0], X.shape[1], X.shape[2], 1))
  256. Y = to_categorical(Y, len(np.unique(Y)))
  257. # Initialize DataFrame to store metrics
  258. results_df = pd.DataFrame(columns=['Trial', 'Train_Accuracy', 'Train_Loss', 'Validation_Accuracy', 'Validation_Loss', 'Test_Accuracy', 'Precision', 'Recall', 'F1_Score', 'Training_Time'])
  259. # Variables to hold last SMOTE'd training set for shape print
  260. X_smote = None
  261. Y_smote = None
  262. # Run 5 trials
  263. for trial in range(5):
  264. print(f"\n=== Trial {trial + 1} ===")
  265. # Train-Test Split (first split, then apply SMOTE ONLY on training set)
  266. X_train, X_test, y_train, y_test = train_test_split(
  267. X, Y,
  268. test_size=0.25,
  269. random_state=42
  270. )
  271. # Apply SMOTE on training set only
  272. y_train_int = np.argmax(y_train, axis=1)
  273. X_train_smote, y_train_smote_int = apply_smote_3d(X_train, y_train_int)
  274. y_train_smote = to_categorical(y_train_smote_int, num_classes=3)
  275. # Save last trial's SMOTE shapes for printing later
  276. X_smote = X_train_smote
  277. Y_smote = y_train_smote
  278. # Build and Compile Model
  279. model = build_eegnet(nb_classes=3) # Ensure nb_classes matches the number of unique classes
  280. model.compile(optimizer=Adam(learning_rate=0.0001), loss='categorical_crossentropy', metrics=['accuracy'])
  281. # Measure training time
  282. start_time = time.time()
  283. # Train Model (using SMOTE'd training set, original test set)
  284. history = train_model(model, X_train_smote, y_train_smote, X_test, y_test, batch_size=64, epochs=50)
  285. end_time = time.time()
  286. training_time = end_time - start_time
  287. # Evaluate Model
  288. train_accuracy = history.history['accuracy'][-1]
  289. train_loss = min(history.history['loss'])
  290. val_accuracy = history.history['val_accuracy'][-1]
  291. val_loss = min(history.history['val_loss'])
  292. test_accuracy = model.evaluate(X_test, y_test, verbose=0)[1]
  293. precision, recall, f1 = evaluate_model(model, X_test, y_test)
  294. # Save metrics
  295. results_df = results_df.append({
  296. 'Trial': trial + 1,
  297. 'Train_Accuracy': train_accuracy,
  298. 'Train_Loss': train_loss,
  299. 'Validation_Accuracy': val_accuracy,
  300. 'Validation_Loss': val_loss,
  301. 'Test_Accuracy': test_accuracy,
  302. 'Precision': precision,
  303. 'Recall': recall,
  304. 'F1_Score': f1,
  305. 'Training_Time': training_time
  306. }, ignore_index=True)
  307. # Save the .h5 file
  308. model.save(f"EEGNet_Trial_{trial + 1}.h5")
  309. # Plot and save accuracy and loss curves
  310. plot_accuracy_loss_curves(history, trial)
  311. # Plot and save confusion matrix
  312. plot_confusion_matrix(model, X_test, y_test, trial)
  313. # Save SHAP plots for this trial
  314. shap_output_dir = f"Trial_{trial + 1}_SHAP_Plots"
  315. shap_analysis(model, X_train_smote, X_test, shap_output_dir, sample_size=50)
  316. # Save results to Excel
  317. results_df.to_excel("Trial_Results.xlsx", index=False)
  318. print("Results saved to Trial_Results.xlsx")
  319. print(X.shape)
  320. print(Y.shape)
  321. print(X_smote.shape)
  322. print(Y_smote.shape)
  323. # print("All trials completed and plots saved successfully!")

code_with_smote.py.py at commit 5de4da8, no license · at the source

Overview

Authors: Sushil Chaturvedi1, Mitul Kumar Ahirwal1
  1. Department of Computer Science and Engineering, Maulana Azad National Institute of Technology,Bhopal, M.P. India
Journal: Scientific reports, volume 16, issue 1, article 22886
Dates: received 8 January 2026; accepted 5 May 2026; published online 20 May 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI 10.1038/s41598-026-52330-z · PMID 42162083 · PMCID PMC13389205 · OpenAlex W7161759045
Open access: gold, a free copy (OpenAlex)
Status: code verified
Categories: EEG (modality), human (organism), methods / tools (subfield)
Methods: Evoked potentials, Machine learning
Keywords: Electroencephalography (EEG), Mental workload (MWL), EEGNet, Synthetic minority oversampling technique (SMOTE), Explainable artificial intelligence (XAI), Computational biology and bioinformatics, Engineering, Mathematics and computing, Neuroscience
MeSH: Artificial Intelligence*, Electroencephalography*, Workload*, Algorithms, Brain-Computer Interfaces, Humans, Signal Processing, Computer-Assisted (* major topic)
Topic: EEG and Brain-Computer Interfaces (Cognitive Neuroscience, Neuroscience), according to OpenAlex
Citations: not cited yet (Europe PMC); 37 references in the paper

Abstract

Mental workload (MWL) classification using electroencephalogram (EEG) signals is crucial for cognitive neuroscience and is also a challenging research area in brain-computer interface (BCI). Since the EEG signals fluctuate a lot across sessions and individuals, there is a need for a robust classification model that generalizes well for real-world applications. In this work, we used the publicly available dataset “An EEG dataset for cross-session mental workload estimation: passive BCI competition of the Neuroergonomics Conference 2021”, and the standard EEGNet model to classify the MWL into three classes (Low, Med, and High). To improve the performance of the model, a synthetic minority oversampling technique (SMOTE) was used by creating synthetic EEG samples, and key hyperparameters (F1, F2, and D) of EEGNet were systematically varied to identify the optimal configuration. Furthermore, Shapley Additive Explanations (SHAP) analysis was performed to identify the most influential EEG channels for model prediction. The proposed approach achieves the highest accuracy of 80.5% and 82.7% without and with SMOTE, respectively. The comparative analysis showed that applying SMOTE resulted in an average performance improvement of approximately 3%. A Wilcoxon signed-rank test confirmed that this improvement was statistically significant (p < 0.05). Finally, the SHAP analysis revealed that the most informative EEG channels were located over the parieto-occipital and temporal regions, which is consistent with established neurophysiological evidence related to MWL processing. The proposed framework improves both performance and explainability in EEG-based MWL classification, representing a systematic integration of SMOTE and SHAP analysis.

Reproduced under the paper's license (CC BY), from the paper cited above.

Repository

Its files are read in the Code ↔ Paper reader above, with 6 matches between paragraphs and lines of code.

213112003/EEG-Based-Mental-Workload-Classification

License: none: the authors keep all their rights
State: the link answers, verified on 28 September 2026
Evidence: files inventoried
Commit: 5de4da8ae9549f2149b7369f4b5bb18d7646ef60, 30 April 2026
Languages: Python (2)
Size: 3 files, 2 scripts
Software Heritage: not archived
Found in: “Code availability”
Holds: README
Not found: license file, CITATION.cff, environment file, tests, continuous integration, documentation
Tools: Keras (2 files), Matplotlib (2 files), MNE-Python (2 files), NumPy (2 files), pandas (2 files), scikit-learn (2 files), SciPy (2 files), SHAP (2 files), TensorFlow (2 files), imbalanced-learn (1 file), OpenCV (1 file)
Availability: 1 check, the latest on 28 September 2026: the link answers
  • 28 September 2026: the link answers
3 files

Code availability

The code used in this work is publicly available at: https://github.com/213112003/EEG-Based-Mental-Workload-Classification.git.

Reproduced under the paper's license (CC BY), from the paper cited above.

Tracing map

Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.

What the map holds:

  • 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 2 scripts, each with its path and the digest of its content;
  • 6 matches between paragraphs of the paper and lines of the code (method lexical-v1);
  • neither the text of the paper nor the code itself.

Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.

Data

Datasets cited

Data availability

The dataset used in this work is open access (online available) and can be found at: 10.5281/zenodo.5055046.

Reproduced under the paper's license (CC BY), from the paper cited above.

Versions

The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.

Version 1, 28 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 2 authors, 9 keywords, 7 MeSH terms, 24 references.

Cite

This paper

Chaturvedi, S., & Ahirwal, M. K. (2026). SHAP analysis of an improved EEG-based mental workload classification framework: utilizing data augmentation and explainable AI. Scientific reports, 16(1), 22886. https://doi.org/10.1038/s41598-026-52330-z

BibTeX

@article{chaturvedi2026shap,
author = {Chaturvedi, Sushil and Ahirwal, Mitul Kumar},
title = {{SHAP analysis of an improved EEG-based mental workload classification framework: utilizing data augmentation and explainable AI}},
journal = {Scientific reports},
year = {2026},
month = may,
volume = {16},
number = {1},
pages = {22886},
publisher = {Nature Publishing Group},
issn = {2045-2322},
doi = {10.1038/s41598-026-52330-z},
url = {https://doi.org/10.1038/s41598-026-52330-z},
pmid = {42162083},
pmcid = {PMC13389205}
}

RIS

TY - JOUR
AU - Chaturvedi, Sushil
AU - Ahirwal, Mitul Kumar
TI - SHAP analysis of an improved EEG-based mental workload classification framework: utilizing data augmentation and explainable AI
T2 - Scientific reports
J2 - Sci Rep
PY - 2026
DA - 2026/05/20
VL - 16
IS - 1
SP - 22886
SN - 2045-2322
PB - Nature Publishing Group
DO - 10.1038/s41598-026-52330-z
UR - https://doi.org/10.1038/s41598-026-52330-z
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41598-026-52330-z",
"type": "article-journal",
"title": "SHAP analysis of an improved EEG-based mental workload classification framework: utilizing data augmentation and explainable AI",
"container-title": "Scientific reports",
"author": [
{
"family": "Chaturvedi",
"given": "Sushil"
},
{
"family": "Ahirwal",
"given": "Mitul Kumar"
}
],
"container-title-short": "Sci Rep",
"volume": "16",
"issue": "1",
"page": "22886",
"DOI": "10.1038/s41598-026-52330-z",
"PMID": "42162083",
"PMCID": "PMC13389205",
"ISSN": "2045-2322",
"publisher": "Nature Publishing Group",
"URL": "https://doi.org/10.1038/s41598-026-52330-z",
"language": "en",
"issued": {
"date-parts": [
[
2026,
5,
20
]
]
}
}

The tracing map gets a citation of its own once an author has validated it and it has a DOI.

Similar papers

The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.

[1] doi:10.3390/s26175327 [code]
Subject Identity Confounds qEEG Emotion Recognition on DEAP and DREAMER.
Journal: Sensors (Basel, Switzerland)
In common: imbalanced-learn, SHAP, Keras, 7 other tools, EEG
[2] doi:10.1038/s42003-026-10957-8 [code]
Brain defence by the extracellular matrix protein Cochlin.
Journal: Communications biology
In common: imbalanced-learn, SHAP, Keras, 7 other tools
[3] doi:10.1371/journal.pone.0347671 [code]
RMETNet: A cross-subject motor imagery EEG signal classification model based on TSLANet and riemannian geometry features.
Journal: PloS one
In common: imbalanced-learn, TensorFlow, MNE-Python, 5 other tools, methods / tools, EEG, 1 reference
[4] doi:10.1038/s41597-025-05174-7 [code]
A large-scale MEG and EEG dataset for object recognition in naturalistic scenes
Journal: n/a
In common: Keras, TensorFlow, MNE-Python, 6 other tools, methods / tools, EEG
[5] doi:10.1126/sciadv.aed3650 [code]
Truthful visualizations for mass spectrometry imaging enable high-spatial-resolution interactive &lt;i&gt;m/z&lt;/i&gt; mapping and exploration.
Journal: Science advances
In common: SHAP, Keras, TensorFlow, 6 other tools, methods / tools
[6] doi:10.1371/journal.pone.0354976 [code]
Improved motor imagery BCI performance via task-unaware compression in the BELT Bayesian Edge-Cloud architecture.
Journal: PloS one
In common: Keras, TensorFlow, MNE-Python, 4 other tools, methods / tools, EEG, 1 reference
[7] doi:10.1038/s43856-026-01606-6 [code]
Validation of remote multimodal AI screening for Parkinson disease across diverse settings.
Journal: Communications medicine
In common: imbalanced-learn, SHAP, OpenCV, 5 other tools
[8] doi:10.1039/d6ra03343a [code]
A benchmark dataset and interpretable deep learning framework for drug-induced developmental neurotoxicity prediction.
Journal: RSC advances
In common: SHAP, Keras, TensorFlow, 5 other tools, methods / tools
[9] doi:10.1038/s41598-026-55163-y [code]
Autism spectrum disorder identification using machine learning models on MRI data.
Journal: Scientific reports
In common: imbalanced-learn, Keras, TensorFlow, 5 other tools
[10] doi:10.1038/s41398-026-04081-8 [code]
Functional system-specific brain aging across the Alzheimer's disease continuum.
Journal: Translational psychiatry
In common: imbalanced-learn, Keras, TensorFlow, 5 other tools

Contribute

The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.

Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.

Request its removal

To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).

Discussion, reproductions, activity

Discussion: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.

Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.

Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.