Python Error in Displaying Image
<p>On this Image</p>

<p><a href="http://i.stack.imgur.com/GLcQa.jpg" rel="nofollow"><img src="http://i.stack.imgur.com/GLcQa.jpg" alt="enter image description here"></a></p>

<p>I am trying to apply:</p>

<pre><code>from PIL import Image
img0 = PIL.Image.open('Entertainment.jpg')
img0 = np.float32(img0)
showarray(img0/255.0)
</code></pre>

<p>And I get this error:</p>

<pre><code>TypeErrorTraceback (most recent call last)
&lt;ipython-input-20-c181acf634a8&gt; in &lt;module&gt;()
      2 img0 = PIL.Image.open('Entertainment.jpg')
      3 img0 = np.float32(img0)
----&gt; 4 showarray(img0/255.0)

&lt;ipython-input-8-b253b18ff9a7&gt; in showarray(a, fmt)
     11     f = BytesIO()
     12     PIL.Image.fromarray(a).save(f, fmt)
---&gt; 13     display(Image(data=f.getvalue()))
     14 
     15 def visstd(a, s=0.1):

TypeError: 'module' object is not callable
</code></pre>

<p>I can't understand why.  </p>

<p>What is not callable here?<br>
How can I just display the image? </p>

<p><code>Image</code> is a module that you imported </p>

<pre><code>from PIL import Image
</code></pre>

<p>You can't call it </p>

<pre><code>Image(data=f.getvalue())
</code></pre>

<p>There's a show method that may be useful </p>

<pre><code>img0 = PIL.Image.open('Entertainment.jpg')
img0.show() 
</code></pre>

python image python-imaging-library