Find boundaries to separate peaks in a 3D plot using matlab or python

171 Views Asked by At

Could you tell me how to find boundaries to separate the peaks in the 3D plot below? Ideally, the boundaries are at the local minimum. Peaks can be generated using Gaussian distributions with some noise. As the top view shows, Gaussians are not in perfect grids, so cannot be seperated by straight lines. The lines are only drawn to illustrate the concept of seperation. The problem is that sometimes noise can be high, so it is difficult to find peaks and valleys precisely.

top view

enter image description here