title: Difference of Gaussian filtering (DoG) doesn't give the expected results
body: <p>I'm trying to implement the method from the original paper ( Enhanced Local Texture Feature Sets for Face
  Recognition Under Difficult Lighting Conditions by Xiaoyang Tan and Bill Triggs) in python 3.6 and Opencv 4.2, <br /> but when I applied the preprocessing to an image it didn't give the same results as in the paper
  although I used the same parameters specified: <br />
  1- for the gamma correction, gamma=0.2 <br />
  2- for the DoG, (sigma0=1, sigma1=2)<br />
  3- for the contrast equalization, tau=10 and alpha=0.1<br /></p>
  
  <p>here is the expected result and the result that i had:</p>
  
  <p><a href="https://i.stack.imgur.com/mNRki.jpg" rel="nofollow noreferrer">Original Image</a>     <a href="https://i.stack.imgur.com/k3cWh.jpg" rel="nofollow noreferrer">resulted image</a>   <a href="https://i.stack.imgur.com/OtBkK.jpg" rel="nofollow noreferrer">expected image</a></p>
  
  <p>and here is the code that I used : </p>
  
  <pre><code>img_original = cv.imread('C:/Users/Ouss/Desktop/TP-LTP/face.jpg', cv.IMREAD_GRAYSCALE)
  
  # gamma correction
  lookUpTable = np.empty((1, 256), np.uint8)
  for i in range(256):
  # calculating the new values
  lookUpTable[0, i] = np.clip(pow(i / 255.0, 2) * 255.0, 0, 255)
  # mapping the new values with the original
  gamma_corrected_img = cv.LUT(img_original, lookUpTable)
  
  # DOG
  blur1 = cv.GaussianBlur(gamma_corrected_img, (3, 3), 1, borderType=cv.BORDER_REPLICATE)
  blur2 = cv.GaussianBlur(gamma_corrected_img, (7, 7), 2, borderType=cv.BORDER_REPLICATE)
  
  dog_img = cv.subtract(blur1, blur2)
  
  # contrast equalisation
  # step 1
  alpha = 0.1
  tau = 10
  temp1 = pow(np.abs(dog_img), alpha)
  meanImg = np.mean(temp1)
  
  Contrast_Equa_step01 = dog_img / pow(meanImg, 1/alpha)
  # step 2
  minMat = np.abs(Contrast_Equa_step01)
  minMat[minMat &gt; tau] = tau
  temp2 = pow(minMat, alpha)
  meanImg2 = np.mean(temp2)
  Contrast_Equa_step02 = Contrast_Equa_step01 / pow(meanImg2, 1/alpha)
  CEqualized_img = tau * np.tanh((Contrast_Equa_step02/tau))
  </code></pre>