PathoOpenGait: Pathological Gait Analysis With an Open-Source Cloud-Enabled Platform Empowered by Semi-Supervised Learning
For the details, please refer to our papar published in IEEE journal of biomedical and health informatics.
- Please execute
setup.sh
to download pretrained weights for several models.$ ./setup.sh
- Please modify
database/sql/create_user.sql
first to create accounts for default admin users. - Please create an
.env
file with the following format.JWT_SECRET_KEY=... MYSQL_ROOT_PASSWORD=... SQLALCHEMY_DATABASE_URI=mysql+pymysql://root:<MYSQL_ROOT_PASSWORD>@db:3306/ndd
- Please make sure the model weights are present in the following path
./backend/algorithms/gait_basic/VideoPose3D/checkpoint/pretrained_h36m_detectron_coco.bin ./backend/algorithms/gait_basic/gait_study_semi_turn_time/weights/semi_vanilla_v2/epoch_94.pth
- (Optional) By default, the video will be provided with a black backgound and full keypoints. If you would like to show the patients' body and the surrounding, please modify
backend/routers/user.py
# video_path = f'data/{video_uuid}/out/render-black-background.mp4' # default one video_path = f'data/{video_uuid}/out/render.mp4' # change to this one
- Execute
$ docker-compose up --build -d
- Please create a folder:
backend/algorithms/<YOUR_ALGORITHM_NAME>
. - Your folder should have a
__init__.py
andmain
files. - In
main.py
, addfrom .._analyzer import Analyzer
. - Create a class for your algorithm, which should inherit
Analyzer
.class CustomizedAnalyzer(Analyzer): def __init__( self, ... ): ... def run( self, data_root_dir, file_id, # '2021-04-01-1-4' ) -> t.List[t.Dict[str, t.Any]]: ...
- Make sure the return of
run
is in the format oft.List[t.Dict[str, t.Any]]
. - Modify
MAPPING
inbackend/inference/config.py
. For example,
YOUR_MODELS = {
'your_model_name_1': CustomizedAnalyzer,
'your_model_name_2': CustomizedAnalyzerV2,
}
MAPPING = {
'data_type': YOUR_MODELS,
}
- Finish. If you need to modify the input interface or anything else, please directly modify those files.
@article{ho2024pathological,
title={Pathological Gait Analysis With an Open-Source Cloud-Enabled Platform Empowered by Semi-Supervised Learning-PathoOpenGait},
author={Ho, Ming-Yang and Kuo, Ming-Che and Chen, Ciao-Sin and Wu, Ruey-Meei and Chuang, Ching-Chi and Shih, Chi-Sheng and Tseng, Yufeng Jane},
journal={IEEE journal of biomedical and health informatics},
volume={28},
number={2},
pages={1066--1077},
year={2024}
}