title: 'int' object is not callable in for in range loop
body: <p>so i am using loops to get each pixels in an image, but i am getting an error which i don't understand.I am using for in range loop to do this</p>
  
  <pre><code>height,width=img.shape
  </code></pre>
  
  <p>when i log these it gives the result alright. The dimensions are being logged, but then when i loop it gives error. I have seen a lot of code use this, but now it is giving some error. What is happening here?</p>
  
  <pre><code>for i in range(0, height):
  TypeError: 'int' object is not callable
  </code></pre>
  
  <p>The code for the loop looks like:</p>
  
  <pre><code>p =[]
  p.append(5000)
  p.append(0)
  p.append(5000)
  p.append(0)
  for i in range(0, height):
    for j in range(0, width):
      if mask[i][j]==0:
          if i&lt;p[0]:
              p[0]=i
          if i&gt;p[1] :
              p[1] = i
          if j&lt;p[2]:
              p[2]=j
          if j&gt;p[3] :
              p[3] = j
      else:
          img[i,j]=[255,255,255]
  </code></pre>