Detecting water bunds automatically