# Computational Methods for Neuron Segmentation in Two-Photon Calcium Imaging Data: A Survey
## 4 Signal/Image Processing-Based Methods
Then they selected negative seeds by uniformly picking pixels from a circle of sufficiently large radius. All the pixels within the radius are compared with the seed to eliminate non-neurons pixels. Although finding superpixels is efficient and all of them can be used as seeds, this process is computationally not efficient. Therefore, the authors considered only 30-40% of all the superpixels with highest average correlation as seeds. They computed correlation space to find similarity between pixels. To compute the value of a pixel \(p_{i}\) in correlation space, they find correlation of temporal trace of the pixel \(p_{i}\) with the temporal traces of all the pixels surrounding it which are inside a bounding box with the pixel \(p_{i}\) in the centre. Then, they averaged all the correlation values to calculate the value of pixel \(p_{i}\) in the correlation space. The authors have tested their approach on the Neurofinder benchmark. The achieved an average F1 score of 59.6%, an average recall of 62% and an average precision of 65.8% on the test datasets provided in the Neurofinder challenge. [PERSON] et al. proposed an open source MATLAB toolbox which they call _NeuroSeg_, for automated analysis of two-photon calcium imaging data [44]. The toolbox includes a custom designed cell detection sub-routine based on Gaussian and Laplacian filters. First, they normalized the image by min-max normalization. Then they use a 2D median filters with a kernel size of 5 for noise reduction. They based their neuron detection approach on the observation that the neurons have circular or elliptical blob like shapes. Therefore, they opted for the gLog algorithm proposed by [PERSON] et al. [45]. They apply the gLog algorithm at different scales to detect neurons of different sizes. The size and orientation of the gLog filter kernels are predefined. These kernels were convolved with the calcium imaging data, thus generating response maps for all the kernels. Then, seeds were initiated by searching local maxima in response maps. An adaptive thresholding algorithm was then used to generate a binary mask of the seeds with cell regions represented by a logical 1 and background represented by a logical 0. Those seeds which were in close proximity were merged. To segment neurons, square windows were drawn with the seeds at their centres. The size of the windows was determined by the size of the kernel which generated to response map of the seed. Next, they calculated two weighting matrices. The first weighting matrix is a Gaussian kernel with an elliptical plateau region whose scales and orientation are determined by the scales and orientations of the original gLog kernels. The second weighting matrix is proportional to the Gaussian gradient of the window and normal vectors pointing from the pixels to the seed. These weighting matrices are multiplied with the square window and the result is binarized. The final binarized window contains the neuron which generated the seed point in first place. They tested their approach on an in vivo two-photon calcium imaging dataset obtained from a C57/BL6J male mouse's cortical neurons with varying view fields. They compared the ROIs detected by their approach to manually annotated ROIs. To quantify the level of agreement between manually annotated ROIs and automatically detected ROIs, they used dice similarity coefficient (DSC) and Hausdorff distance (HD) [46]. They reported a DSC of \(0.83\pm 0.02\) and an HD of \(12.91\pm 1.49\). They also reported a precision of \(87.5\%\pm 6.6\%\), a recall of \(89.3\%\pm 5.3\%\) and an F1 score of \(88.1\%\pm 4.0\%\). Although the approach is simple and analytically tractable, it cannot deal with overlapping neurons. Moreover, it might also find it hard to detect the doughnut-shaped neurons in which calcium activity is concentrated on the borders. [PERSON] et al.