Calibration of the 1D shallow water equations: a comparison of Monte Carlo and gradient-based optimization methods