CLOCS is a patient-specific contrastive learning method that can be used to pre-train medical time-series data. It can improve the generalization performance of downstream supervised tasks.
This method is described in "CLOCS: Contrastive Learning of Cardiac Signals"
The CLOCS code requires
- Python 3.6 or higher
- PyTorch 1.0 or higher
The datasets can be downloaded from the following links:
- PhysioNet 2020: https://physionetchallenges.github.io/2020/
- Chapman: https://figshare.com/collections/ChapmanECG/4560497/2
- Cardiology: https://irhythm.github.io/cardiol_test_set/
- PhysioNet 2017: https://physionet.org/content/challenge-2017/1.0.0/
In order to pre-process the datasets appropriately for CLOCS and the downstream supervised tasks, please refer to the following repository: https://anonymous.4open.science/r/9ecc66f3-e173-4771-90ce-ff35ee29a1c0/
To train the model(s) in the paper, run this command:
python run_experiments.py
To evaluate the model(s) in the paper, run this command:
python run_experiments.py