Skip to content

timnotavailable/QuantitativeMPI

Repository files navigation

QuantitativeMPI

0 Introduction

According to the related laws and regulations in Germany and Bavaria(General Data Protection Regulation- GDPR and Federal Data Protection Act Bundesdatenschutzgesetz - BDSG), medical personal data on a public website without the individual's explicit consent would typically violate these regulations. Yet all code is provided with some illustrative examples.

File Structure

|-config ## Training and inferring are configured with hydra

  • ReadImageBin.py ## Class for reading image.bin, which was exported from MunichHeart
  • preprocess.py ## preprocessing the data
  • Res18.reg.py ## training code
  • utils.py ## dataloader and savepoints
  • test_single.py ## code for test set
  • loc.py ## a library for localization, including all the localization tools
  • models ## models for training
  • run_copy.ipynb ## examples of running result, an example patient with stress and rest polar map is shown, providing how the localization is going from scratch.

1 Preprocess the data (ReadImageBin.py and preprocess.py )

This part is about how to preprocess the data ReadImageBin.py:

  1. Data was exported in a format of image.bin from MunichHeart, including stress/rest polar map, the area of stress and rest polar map (15x36) , and a standard polar map in (3,256,256) of stress/rest/difference polar map. preprocess.py:
  2. Stress and rest map are further processed in such a way: first from (15,36) to (224,224), then duplicate to (3,224,224) for adapting proper size to use Grad CAM++
  3. Critical point: Stress and rest polar map should be in the same training dataset, if individually trained with different models, it would be misregistered.
  4. Simultanuously image, label, severity score are save in a dict for next step training

2. Train and checkpoints(utils.py and Res18.reg.py )

utils.py: including dataloader and dataset,save and read checkpoints Res18_reg.py: Train, optimizer

3. Test (test_single.py)

function and class for test

4. Localization libary(loc.py)

function and class for localization with Grad-CAM,GradCAM++,and other CAM family

5.run_copy.py

an illustrative example of a running result.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published