Hello. As far as I know, there are two main ways to implement a deep learning (convolutional) neural network training algorithm in Matlab. There is the Matconvnet package by Vedaldi et al, (freely) available from https://github.com/vlfeat/matconvnet
(I'm not sure if it's still maintained but the technical report is good.)
The other main option is to spend the money and get the deep learning toolbox for Matlab. If you wish to run on a PC with an NVIDIA GPU with the CUDA/cuDNN libraries, you will need the parallel processing toolbox also. Note that Matconvnet can run on a GPU if you configure it (see https://www.vlfeat.org/matconvnet/install/)
The rest is regular deep learning, which is basically feeding heaps of image pairs (image and either classification or segmentation template) into your favourite convnet until it stabilises and gives a decent validation or test score.
Good luck. Please recommend if you find this answer useful.