45
45
46
46
Polyps
47
47
48
- The polyps dataset can be found `[ here] <https://drive.google.com/file/d/0B_60jvsCt1hhZWNfcW4wbHE5N3M/view>`__.
49
- In each of the training, validation and test data , the input images are in the
48
+ The polyps dataset can be found `here <https://drive.google.com/file/d/0B_60jvsCt1hhZWNfcW4wbHE5N3M/view>`__.
49
+ In each of the training, validation and test directory , the input images are in the
50
50
/images directory and the polyps mask (segmentation map) are in /masks2. The
51
51
segmentation maps in the *masks2* directory indicate the presence or absence
52
52
of polyps for each pixel. The other subdirectories (/masks3 and /masks4) are,
53
53
respectively, for a segmentation task with 3 and 4 classes, but will not be
54
- presented here.
54
+ presented here.
55
55
56
56
57
57
Model
@@ -135,15 +135,26 @@ number of pixels in the union between those two segmentation maps,
135
135
also for that specified class.
136
136
137
137
.. math::
138
- :label: jaccard
138
+ :label: jaccard_equation
139
139
140
140
jacc(P(class), GT(class)) = \frac{|P(class)\cap GT(class)|}{|P(class)\cup GT(class)|}
141
141
142
- where :math:`P` is the predicted segmentation map and :math: `GT` is the ground
143
- truth segmentation map. Often, a class is well segmented if its respective jaccard
142
+ where `P` is the predicted segmentation map and `GT` is the ground
143
+ truth segmentation map. `P(class)` is then the binary mask indicating if each
144
+ pixel is predicted as *class* or not.
145
+ Often, a class is well segmented if its respective jaccard
144
146
is at least 0.5. In the polyps dataset, the jaccard(polyps) must thus be at
145
147
least 0.5.
146
148
149
+ .. figure:: images/jaccard.png
150
+ :align: center
151
+ :scale: 40%
152
+
153
+ **Figure 5** : Jaccard visualisation
154
+
155
+
156
+ TODO: reference image from this `website <http://www.pyimagesearch.com/2016/11/07/intersection-over-union-iou-for-object-detection/>`__
157
+
147
158
Code - Citations - Contact
148
159
++++++++++++++++++++++++++
149
160
@@ -152,13 +163,16 @@ Code
152
163
153
164
The FCN-8 implementation can be found in the following file:
154
165
155
- * `fcn8.py <http://deeplearning.net/tutorial/ code/fcn8.py>`_ : Defines the model.
156
- * `train_fcn8.py <http://deeplearning.net/tutorial/ code/train_fcn8 .py>`_ : Training loop.
166
+ * `fcn8.py <../ code/fcn_2D_segm/ fcn8.py>`_ : Defines the model.
167
+ * `train_fcn8.py <../ code/fcn_2D_segm/fcn8 .py>`_ : Training loop.
157
168
158
169
159
170
TODO : import model_helpers, dataset_loader, metrics
171
+ TODO : remove /Tmp/romerosa path and make them relative path
160
172
161
-
173
+ .. literalinclude:: ../code/fcn_2D_segm/fcn8.py
174
+ :start-after: start-snippet-1
175
+ :end-before: end-snippet-1
162
176
163
177
Papers
164
178
======
0 commit comments