Professional Documents
Culture Documents
Diagnosis of Neuromuscular Diseases Via Deep Learning: BTP Part-1 Abhishek Shringi (2018CH10187)
Diagnosis of Neuromuscular Diseases Via Deep Learning: BTP Part-1 Abhishek Shringi (2018CH10187)
Learning
Submitted in partial fulfilment of the requirements for the award of the degree of
BACHELOR OF TECHNOLOGY IN CHEMICAL ENGINEERING
BTP Part-1
By
Abhishek Shringi
(2018CH10187)
Signature of student:
Signature of Supervisor:
(Signature of supervisor)
Prof. Hariprasad Kodamana
Assistant Professor
Department of Chemical Engineering
(Jointly with) School of AI
IIT Delhi
ii | P a g e
Declaration
I do certify that this report explains the work carried out by me in the Course
CHD 411 - Major Project Part-1 under the overall supervision of Prof. Hariprasad
Kodamana. The contents of the report including text, figures, tables, etc. have not
been reproduced from other sources such as books, journals, reports, manuals,
websites, etc. Wherever limited reproduction from another source had been made
the source had been duly acknowledged at that point and also listed in the
References.
(Signature of student)
Abhishek Shringi
2018CH10187
iii | P a g e
Acknowledgements
I would like to take this opportunity to express my deep sense of gratitude and
profound feeling of admiration to my supervisor. I would like to express my
special thanks of gratitude to Prof. Hariprasad Kodamana who gave me the
golden opportunity to do this wonderful project on the topic Deep Learning
based diagnosis of Neuromuscular Diseases which also helped me in doing a
lot of research. I gained valuable knowledge working on the project. I am really
thankful to him and for his guidance. His willingness to share his vast knowledge
made me understand this project and its manifestations in great depths and helped
us to complete the assigned tasks. I would like to express my gratitude towards
my parents for their belief in me and encouragement which help me in completion
of this project. I express my love and gratitude to my beloved family and friends;
for their understanding & endless love, through the duration of the project.
iv | P a g e
Abstract
The manual diagnosis of neuro-muscular diseases like muscle dystrophy in thighs
can be very much time consuming and tedious process. This thesis provides
details insights about our work aimed towards the automated diagnosis of Neuro-
muscular diseases in thighs leveraging the use of deep learning on the fat-water
decomposition MRI. A pipeline of segmentation and classification on the MRI
image was deployed to serve the purpose of diagnosis.
The dataset used in this pipeline is known as MyoSegmentum Thighs. It consists
of 25 MRI scans (3 scans of patients and 21 scans of healthy volunteers).
For the segmentation purpose, U-Net model was used and for classification
purpose, ResNet50 was used. IOU score was used as a metric in segmentation,
and we are able to obtain a IOU-score as high as .901.
Further work is required and is being continued in hyperparameter tuning and
training the classification model, so that our pipeline gives us the optimum
results.
Thus, we propose our novel segmentation classification pipeline for the
diagnosis purpose at the clinical level. This work is is in collaboration with
AIIMS Delhi.
v|Page
Contents
Certificate................................................................................................................................................ ii
Acknowledgements ................................................................................................................................ iv
Abstract ................................................................................................................................................... v
1. Introduction ..................................................................................................................................... 1
2. Literature Review............................................................................................................................ 2
5. Dataset ............................................................................................................................................ 5
7. Pipeline ........................................................................................................................................... 7
9. Conclusion: ................................................................................................................................... 13
vi | P a g e
List of Figures
Figure 1 ...................................................................................................................................... 1
Figure 2 ...................................................................................................................................... 1
Figure 3 ...................................................................................................................................... 2
Figure 4 ...................................................................................................................................... 3
Figure 5 ...................................................................................................................................... 4
Figure 6 ...................................................................................................................................... 5
Figure 7 ...................................................................................................................................... 5
Figure 8 ...................................................................................................................................... 6
Figure 9 ...................................................................................................................................... 7
Figure 10 .................................................................................................................................... 7
Figure 11 .................................................................................................................................... 8
Figure 12 .................................................................................................................................... 9
Figure 13 .................................................................................................................................. 10
Figure 14 .................................................................................................................................. 10
Figure 15 .................................................................................................................................. 11
Figure 16 .................................................................................................................................. 12
Figure 17 .................................................................................................................................. 12
vii | P a g e
Nomenclature
Symbol Meaning
NMD Neuromuscular Disease
QF Quadriceps Femoris
GR Gracilis
SA Sartorious
HA Hamstring
viii | P a g e
1. Introduction
Neuromuscular Diseases (NMDs) forms a rare class of diseases. One of the
examples of NMD is Duchenne
Muscular Dystrophy(DMD). It has been
reported that over 350 Million[1] people
are suffering from DMD ,worldwide.
India has over 0.8 million children
suffering from DMD [1]
These are the numbers that have been
diagnosed , it is highly likely that many
people remain undiagnosed to such a Figure 1
deadly disease for a long time because the diagnosis of DMD is not only very
time consuming and tedious but also prone to knowledge of subject matter expert.
This situation clearly demands for a better and faster way for diagnosis of this
disease in patients.
Recently, computer vision is finding a lot
of applications in diagnosis of various
diseases like COVID-19, Pneumothorax
etc. that can be but are hard to diagnose by
understand medical imaging techniques
like magnetic resonance imaging (MRI)
and X-rays. Not only computer vision is
successfully applied but have achieved
remarkable success in diagnosis of these
Figure 2
diseases.
So, it makes a sense to dive into computer vision to find a solution to our problem.
Not to mention computer vision have been able to achieve such a landmark only
after the advent of various deep learning models. So, we decided to use deep
learning as a tool for the diagnosis of NMDs.
The thesis starts by presenting the literature review of how this problem have
been approached till now. This is followed by detailed mathematical explanation
of the deep learning models like U-Net, ResNet50, that have been used in this
work. Then a detailed explanation of the dataset (Myosegmentum Thighs) have
been provided. Then a vivid description of various software/libraries used in my
work. Finally , results obtained have been discussed , followed by conclusion and
then future work to be done is presented.
1|Page
2. Literature Survey[2]
Fat Infiltration
Literature[3] reports that the person having NMD has been observed to have
fat infiltration (which means higher fat fraction in muscles). Hence, fat-
fraction would serve as a better marker for the disease diagnosis.
Quantitative MRI analysis
This bring us in search of an effective quantitative MRI technique, so that fat
fraction in the muscle can be estimated non-invasively. One of the suitable
technique reported in the literature is Fat-Water Decomposition MRI. This
technique was first invented by Dixon[4]. It can differentiate MRI signals
from water and fat protons based on their chemical shift differences, making
it ideal for fat-fraction estimates. Now, Multipoint Dixon sequences are
clinically used and widely used in research studies to assess intramuscular fat
infiltration in the thigh.
Figure 3
Segmentation
This is a crucial step
for fat-fraction
estimation after
obtaining fat-water
decomposition MRI.
It severely limits the
application of fat
water decomposition
MRI for fat fraction
estimation as the manual segmentation of various muscle is not only time
consuming and complex process but also subjected to various errors and
reproducibility issues. A study reported that for a scan it takes about 6 hrs on
an average to manually segment the 4 muscle regions in thighs namely QF,
GR, SA, HA.
To overcome the limitation of manual segmentation, Ding et al. proposed a
very novel method of segmenting the regions with the U-Net Model and then
classifying the normal & abnormal thighs on the basis of mean fat fraction.
2|Page
3. U-Net Model
Biomedical Image Segmentation
The U-Net was developed by Olaf Ronneberger et al. for Bio Medical
Image Segmentation in 2015. [5]
Encoder-Decoder Architecture
The architecture contains two paths. First path is the contraction path (also
called as the encoder) which is used to capture the context in the image. The
encoder is just a traditional stack of convolutional and max pooling layers.
The second path is the symmetric expanding path (also called as the
decoder) which is used to enable precise localization using transposed
convolutions. Thus it is an end-to-end fully convolutional network (FCN),
i.e. it only contains Convolutional layers and does not contain any Dense
layer because of which it can accept image of any size.
Figure 4
3|Page
4. ResNet
ResNets are deep residual networks,
which were invented in 2012[6],
they were one of the most ground
breaking invention in the field of
computer vision, since they allowed
the training of the deeper networks
more efficiently and correctly.
They are based upon simple fact that
identity matrices can be stacked over
each other, so it is just required to
train the residual and not the whole
functions , which usually lead to
problems of vanishing and
exploding gradients. They utilised
the skip connections as shown in the
figure, in order to take this problem
into account and solve it efficiently.
4|Page
5. Dataset
Magnetic Resonance
Imaging (MRI) can
help to evaluate
muscle anatomy and
diagnose various
disorders and Neuro-
muscular diseases. In
addition to this,
quantitative MRIs
with chemical shift
encoding fat-water
images can also help
to estimate the muscle
Figure 6
volume and the fat fraction in the muscles.
The dataset used for our thesis is known as MyoSegmenTUM thigh. This
contains the MRI images of left & right thighs with a voxel size of 3.2x2x4
mm3 of 15 healthy volunteers and 4 patients having NMD[7]. The dataset
contains PDFF maps , Fat images , Water images of the thigh region, the file
.
training and testing purpose for our model.The thighs have been manually
segmented into quadriceps femoris muscle, sartorius muscle, gracilis muscle
and hamstring muscles, and have been provided format. The data
provided is volumetric in nature , while we have extracted 2D slices from the
data for our analysis. This dataset is specially designed so as to facilitate
research in the area of automatic segmentation of muscles.
The following tables provide details of healthy & unhealthy patients:
Figure 7
5|Page
6. Software and Libraries Used
The following table describes various software and libraries used in this work:
Figure 8
6|Page
7. Pipeline
This section describes about the pipeline that have been proposed for the
diagnosis of NMDs via deep learning
Figure 9
7|Page
7.2 Data Pre-Processing :
Figure 11
Thresholding:
It is one of the simplest methods to segment and process the images
digitally. In this a grayscale image is converted into a binary image (i.e.
image having only black and white pixels)[8]. In thresholding, a particular
threshold intensity is chosen say T and the image having various intensity
over the space, suppose at a particular position (xi , yj) the intensity is I. If
I is greater than T then the pixel is assigned white pixel else black pixel.
In consideration with our data we used it to remove the subcutaneous fat,
the extra fat that is present between skin region and thigh region.
8|Page
For the pre-processing of mask images , the following step was done:
Combination:
In the dataset MyoSegmentum, masks of 4 muscles namely QF,GR,HA,SA
are given for both left and right thighs separately. So , we combined all the
individual muscle and made a mask out of that using a self written python
script. The following image explains how it has been done:
Figure 22
The pre-processing of all images was done using a python script , and pre-
processed images were stored in separate folder in pickle format, so that they
could be retrieved easily during training of the deep learning model.
7.3 Segmentation Model:
In order to perform ,delineation of 4 ROIs namely QF,GR,HA,SA, U-Net is used,
working of which has been explained in previous section. Now for the
segmentation both water & fat image should be important , so we stacked them
over each other and formulated the training data and testing data in various ratios.
We used Segmentation_Models library for the implementation of U-Net and used
ResNet34 as its backbone. IOU-score was used as the metric for the segmentation
accuracy. Basically IOU-score is the ratio of overlapping area of segmented mask
to the union of the area of predicted and actual mask.
9|Page
The learning parameter was set to 10^-6 , while the number of epochs and batch
size were varied and its effect on training and testing error was observed using
plots (given in results section) .
Figure 33
65 * ResNet50
Unhealthy
We have used ResNet50 for the classification of 2D images and the later part of
it is simple python script. However training and hyperparameter tuning is yet to
be done for the classification model.
10 | P a g e
8. Results & Discussion
The value of learning parameter was taken to be 10^(-6). For the training data
5 stacks of MRI Images of healthy volunteers were taken and 2 stacks of
unhealthy patients were taken, having 65 slices in each stack & each slice is
672*672 pixel2. For the testing Since this was initial part of our work , we
have set the batch size to be 32 and no. of epochs were varied and variation of
training error & IOU score was observed.
The images shown below gives a qualitative idea of our predictions on the
unseen data. One can clearly observe striking similarity between the predicted
and the actual masks. And clearly puts the authenticity of U-Net in carrying
out automatic segmentation for biomedical images.
Figure 14
Figure 15
11 | P a g e
Quantitative analysis of results:
The training was carried out firstly for 10 epochs and the loss function with
no. of epochs was plotted , the IOU-score clearly increases with more no. of
epochs , while the loss decreases. We were able to achieve the IOU score of
around .85 with 10 epoch, and that is a reasonable accuracy of segmentation.
Figure 46
Then we went ahead and trained out model for 200 epochs , so we were able
to get a segmentation accuracy as high as 90% , which is exceptional, but the
curve gets saturated around 80 epochs, so there exists a lot of scope for
improvement in training other parameters.
Figure 57
12 | P a g e
9. Conclusion
With our novel pipeline which includes segmentation followed by
classification, we are able to develop a system for automated diagnosis of
NMDs (particularly muscular dystrophies). It has a clear advantage of very
smooth and efficient automated segmentation which takes only around 10s
for to delineate ROIs, whilst for manual segmentation it was around 6h,
that is a remarkable achievement. It also provides non-invasive strategy for
diagnosis of muscular dystrophy, as opposite to the invasive techniques
like biopsy which is a painful and time taking process.
AIIMS Dataset
Since this project is in collaboration with AIIMS, we will be getting MRI
images for various patients having NMD , which in-turn will make our
model more generalisable in future. We have submitted joint proposal for
ethical clearance of the same.
13 | P a g e
Bibliography
[1]
https://www.thepharmaletter.com/article/india-s-first-medicine-to-treat-duchenne-
muscular-dystrophy-cleared-for-
testing?__cf_chl_jschl_tk__=pmd_dpqlZGM8yZqfqaGSKMvko.0U7oD4kWeBrqwkg6jw89U-
1633660988-0-gqNtZGzNArujcnBszQcR (accessed Nov. 14, 2021).
[6]
Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern
Recognition, vol. 2016-December, pp. 770 778, Dec. 2015, doi: 10.1109/CVPR.2016.90.
[8] Image Pr -
processing/07-thresholding/ (accessed Nov. 14, 2021).
[9]
Nov. 14, 2021).
14 | P a g e