Surface EMG is the standard for assessing muscle activation during gait, but it is impractical for everyday wearable applications due to electrode placement sensitivity and setup complexity.
This project investigates whether wearable inertial (IMU) and textile strain-gauge sensors can indirectly estimate EMG-derived muscle activation characteristics using machine learning.
- Study conducted with 12 participants (healthy + multiple sclerosis)
- Synchronized EMG, IMU, and strain-gauge recordings
- Three Support Vector Machine (SVM) models:
- Regression of EMG temporal events (onset, offset, peak)
- Regression of EMG envelope polynomial coefficients
- Classification of healthy vs. MS gait
- Early EMG timing predicted with RMSE ≈ 5–15% of gait cycle
- Strong overfitting observed in cross-subject evaluation
- Limited amplitude estimation capability
- Demonstrates both potential and limitations of indirect EMG estimation
-
Activity Prediction (AP)
- Predicts EMG onset, offset, and peak timing
- Test RMSE ≈ 5–15% (early events)
- Poor generalization for unseen subjects
-
Polynomial Coefficient (PC)
- Estimates EMG envelope shape via polynomial coefficients
- Moderate test correlations (60–75%)
- Large amplitude and timing errors in unseen data
-
Gait Classification (GC)
- Healthy vs. MS gait patterns
- 97–99% test accuracy
- 31–46% accuracy on unseen participants (overfitting)
Wearable IMU and strain signals contain detectable information about EMG timing.
However, amplitude estimation and subject-independent generalization remain major limitations.
-
models
Contains the trained machine learning models:- AP model
- GC model
- PC model
- Shared inference pipeline used by all models
-
documents
Includes:- The original master thesis (PDF)
- All associated figures
-
sample
Provides the required input data structure. Raw participant data is not included due to data protection regulations and ethical restrictions. -
src
Contains the custom libraries developed for:-
Preprocessing
- EMG_preprocess.py – EMG signal preprocessing pipeline
- EMG_rawdata_process.py – Raw EMG data handling
- IMU_rawdata_process.py – Raw IMU data processing
- pants_preprocess.py – Preprocessing for pants sensor data
- pants_rawdata_process.py – Raw pants sensor data handling
- Proband_1_Correction.py – Subject-specific correction procedures
- synchronization.py – Sensor data synchronization
- segmentation.py – Signal segmentation
- onset_offset.py – Onset and offset detection
- start_point.py – Start-point detection logic
-
Feature Extraction & Signal Processing
- emg_ar.py – Autoregressive modeling for EMG
- pants_features.py – Feature extraction from pants sensor data (IMU, knee angle)
- Order_selection.py – AR order selection utilities
-
Model I/O & Evaluation
- extract_model_input_output.py – Preparation of model inputs and outputs
- evaluation.py – Model evaluation metrics and analysis
-
Utilities
- LoadLib.py – Data loading utilities
- Save_processed_data.py – Saving processed datasets
- Plot_methods.py – Visualization and plotting functions
-
Negin Hannani
Master's Thesis
Justus Liebig University Gießen
Data Collection at Universitäts Klinikum Dresden
2025