# Computational Methods for Neuron Segmentation in Two-Photon Calcium Imaging Data: A Survey
## 2 Major Trends  
Current neuron segmentation approaches in calcium imaging face the following open challenges: (i) some brain sections present regions with densely located neurons, which can synchronously spike, making the detection and segmentation difficult, (ii) similarly, the summary of the 3D structure of the brain may introduce overlapping neurons, which can confuse the individual cell annotation and (iii) there is a need for automated analysis methods due to the large availability of calcium imaging data, but there is a lack of public large annotated datasets for learning complex models (such as deep learning approaches) that could be used to segment the data available. The survey analyses three main trends followed for neuron segmentation/neural activity detection for calcium imaging data in the literature: neuron segmentation using signal/image processing methods, matrix factorization techniques and machine learning algorithms. The taxonomy of these trends is shown in Figure 2.  
Image processing methods use unsupervised signal processing (see Section 4) to filter the neurons on each temporal frame. These methods benefit from the structural features of the neurons' boundaries to highlight them either using convolutions with specific filters, mathematical morphology filters, graph based-clustering, pixel-value thresholding or a combination of them. Most of the approaches which fall in this category rely on some form of background estimation. Since neural activity is recognized by looking for compact spatial regions which exhibit different calcium indicator dynamics than the surroundings, background estimation is a relatively efficient approach to filter out these regions [11; 12; 13]. The underlying assumption is that calcium indicators will always emit a baseline fluorescence, even when the neurons are not active. An effective background estimation method which caters to this baseline fluorescence and random noise can therefore quickly isolate any active neurons. Another particular case of unsupervised learning is the use of matrix factorization methods [14; 15; 16]. These methods are based on the assumption that the image is generated by a linear combination of a set of latent variables, which usually correlate with the neuronal signal. Matrix factorization has been widely used in many computer vision tasks, such as face classification [17], unsupervised image denoising [18] and hyperspectral image classification [19]. This can be further sub-divided into two main categories, independent component analysis (ICA) (see Appendix A.2 for details) and non-negative matrix factorization (NMF) (see Appendix A.1 for details). In ICA, the spatial and temporal footprints of the  
Figure 2: General taxonomy of the major trends and approaches covered in this survey. neurons are estimated by solving the matrix factorization framework for two independent matrices, one for spatial footprint and the other for temporal traces. In NMF, the matrix factorization framework is solved in a constrained manner by borrowing one key fact from the physics behind neural florescence i.e., the factorized matrices for spatial footprint and temporal traces cannot contain negative values since a negative value in either spatial footprint or temporal traces is not physically possible. Section 5 reviews some of the most relevant approaches. The third ensemble of approaches relies on supervised methods. Supervised methods use either manually or anatomically annotated masks to train a robust classifier that performs the neuron segmentation task. These methods usually require large amounts of labelled data, and obtain improved generalization accuracies. With the advent of deep learning methods, two main architectures emerged as the most prominent: convolutional neural networks (CNNs) for pixel classification [20] and U-Net architectures for dense segmentation [21]. These two methods are then applied to the spatio-temporal calcium imaging stacks in two approaches.