Skip to content

albertabionix/EMG_Viability_ML_Algorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EMG_VIABILITY

Pipeline Architecture

Pipeline architecture

Stage 1 — Input & mode split

Raw CSV recordings from the SIAT-LLMD dataset (40 subjects, 9 channels, 1920 Hz) are grouped into three modes based on movement label: sitting (SITDN), standing (STDUP, STC), and walking (WAK, HS, TO, LUGF, LUGB).

Stage 2 — Preprocessing (src/preprocessing/preprocess.py)

Each recording passes through: bandpass filter (20–450 Hz) → notch filter (60 Hz) → DC removal → channel selection. Only channels 0–3 (thigh muscles: TFL, rectus femoris, vastus medialis, semimembranosus) are retained, since channels 4–8 are below the amputation site.

Stage 3 — Windowing & feature extraction (src/dataset/, src/features/)

Signals are sliced into 200-sample (~104 ms) windows with 50% overlap. Each window produces 30 features: Du's 6 time-domain features (integrated, variance, WL, ZC, SSC, WAP) × 4 channels, plus 6 inter-channel Pearson correlations.

Stage 4 — One-class SVM models (src/models/)

Three separate OC-SVMs (RBF kernel, ν = 0.05) are trained on the able-bodied feature distribution — one per mode. At inference, the model scores how closely a candidate's EMG matches the normal population.

Stage 5 — Viability score (src/scoring/)

Per-mode scores are combined as 0.2×sitting + 0.3×standing + 0.5×walking, with optional penalties for low RMS (weak activation) or high variance (noisy signal). The final score is scaled to 0–100.

Score Verdict
≥ 60 Viable
40–59 Borderline — manual review recommended
< 40 Not viable

Data Source

Before attempting to run, please download the data from : https://springernature.figshare.com/articles/dataset/Shenzhen_Institute_of_Advanced_Technology_Lower_Limb_Motion_Dataset_SIAT-LLMD_/22776389?file=40468208

Once downloaded save as follows: ./EMG_Viability_ML_Algorithm/data/SIAT_LLM20230404/

About

This algorithm aims to develop a Model that can efficiently classify the viability of a Trial Candidate based on their EMG sensor data

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors