Robust local slope estimation by deep learning