title: Why reading colored image as Gray Scale in OpenCv is different from convert same image from BGR to GRAY
body: <p>I am reading colored image as GRAY then I read it as BGR. When I convert BGR to GRAY I found it different from the first one. Can anyone explain why and what the equation for converting and reading image in OpenCV?</p>
  
  <pre><code>import cv2
  import numpy as np
  img_c=cv2.imread("/home/image_7lbl.png",1) 
  img_g=cv2.imread("/home/image_7lbl.png",0)  
  img_cg=cv2.cvtColor(img_c,cv2.COLOR_BGR2GRAY)
  print(np.array_equal(img_g,img_cg))
  False
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/S9HsG.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/S9HsG.png" alt="enter image description here"></a></p>