Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Code for Deep Predictive Motion Tracking in Magnetic Resonance Imaging: Application to Fetal Imaging to model robust spatiotemporal motion in fetal MRI

tSNE projection of internal states of encoder lstm

Model Architecture

model_architecture

Results

results

Getting started

  1. Install all the dependencies in python >v3.6 using python setup.py install
  2. The main.py script runs all training and evaluation OR just evaluation using a pretrained model.
  3. Simply configure the sample_experiment.json in ./experiments directory and pass it as an argument to the main script
>>> python main.py ./experiments/sample_experiment.json 
  1. If step 2 is training then once the model is trained, the results of held out test set, a copy of experiments .json and model itself will be persisted to given directory.
  2. An example of how to configure experiments is put in ./experiments directory.
  3. If a pretrained model path is provided then only evaluation will be done by loading the pretrained model otherwise training from scratch will be performed.

Notes

  • We have used CUDA implementation of LSTM which needs a NVIDIA GPU to train these models however in ./models/our_model.py you can switch CuDNNLSTM by generic LSTM to train on CPU.
  • In ./experiments/sample_experiment.json you will find network section where you can define what kind of network you would like to train from resnet18, vgg16, direct_lstm, and our_model where in our_model you can specify whether to train a single_head: true network or single_head: false model as well has size of layers using hidden_units: 512.
  • In data section of ./experiments/sample_experiment.json you can also set mask: true/false to enable training models on masked/unmasked data.

To download pretrained models please visit this gdrive link and place them in preferably ./models directory

About

Code for Deep Predictive Motion Tracking in Magnetic Resonance Imaging: Application to Fetal Imaging

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages