fix ripples detection