**Appendix A**

During the inference phase, the CNN's probability map could suffer from a lack of information near the edges of the image. To overcome this problem, an *Extended image* is synthesized by padding the original image with mirror reflections of 256 × 256 pixels along each direction. As shown in Figure A1, the result of this operation is an RGB image of 1024 × 1024 pixels. A sliding window operator with a size of 512 × 512 is then passed over the extended image with an overlap of 256 pixels between consecutive windows. The deep network is applied to each 512 × 512 window, and only the center of each prediction is kept for the creation of the initial softmax. This operation yields a heat map of size 768 × 768 which is further center cropped to obtain the final softmax with the same size as the input image. The final softmax can be considered as an RGB image, where the red layer contains the probability for each pixel of belonging to the "blood vessel" class, while the green layer represents the probability for each pixel of belonging to the "blood vessel boundaries" class.

**Figure A1.** Procedure for the creation of the final CNN softmax. The original image is mirrored around the boundaries to obtain the extended image. Then, a sliding window approach is employed to classify each patch, and only the center of each prediction is kept to build the final softmax.
