gradient, tophat and blackhat are working