Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7415401
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T07:17:48+00:00 2026-05-29T07:17:48+00:00

My system: Mac OS X 10.7 Python 2.7.1 NumPy version 1.5.1 My code: image

  • 0

My system: Mac OS X 10.7
Python 2.7.1
NumPy version 1.5.1

My code:

image = openImage(fileDir)  
print image  
image = np.asarray(image)  
print image

If I run this:

python main.py 1010.png

the output is:

<PIL.PngImagePlugin.PngImageFile image mode=RGB size=10x10 at 0x10A835368>  
[[[226 226 226] ...    `

If I run this:

python main.py google.jpg 

the output is:

<PIL.JpegImagePlugin.JpegImageFile image mode=RGB size=488x640 at 0x10140B368>  
<PIL.JpegImagePlugin.JpegImageFile image mode=RGB size=488x640 at 0x10140B368>

I cannot figure out why numpy can converts png’s but can’t do it on jpg’s, why? How can I solve this?

edit:

ok tried with

image.show()

and got following error-message:

IOError: decoder jpeg not available

i solved the problem with the information i got from this page:
http://mariz.org/blog/2007/01/26/mac-os-x-decoder-jpeg-not-available/

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T07:17:49+00:00Added an answer on May 29, 2026 at 7:17 am

    i solved the problem with the information i got from this page:

    http://mariz.org/blog/2007/01/26/mac-os-x-decoder-jpeg-not-available/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

System: Mac OSX 10.6.5, Python 2.6 I try to run the python script below:
I want to run Mac OS in my Windows operative system, is there any
I want to get MySQL working with the system Python 2.7 in Mac OS
System info: Python 2.7.2 MAC OSX 10.7.2 Problem (+background): I have a large '.csv'
I've installed Python 2.7 (32-bit) version on my mac with an apparently successful installation
Via fink install I put the following Python version on my Mac OS X
I am trying to run python in 32 bit mode on Mac OS X
I'd like to monitor the current system-wide CPU usage on a Mac with Python.
System Info: Mac OSX 10.7, Python 2.6.7, Plone 4.0.7 I'm creating an uninstall profile
We're using SCons + swtoolkit for our build system on Mac, Linux, and Windows.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.