[Image-SIG] (no subject)

root root at bbl.med.upenn.edu
Wed Jul 25 18:57:48 CEST 2007


Return-Path: <g>
Received: from smtp-vbr6.xs4all.nl (smtp-vbr6.xs4all.nl [194.109.24.26])
	by bbl.med.upenn.edu (8.13.1/8.13.1) with ESMTP id l6L0b8DS010802
	for <hughett at bbl.med.upenn.edu>; Fri, 20 Jul 2007 20:37:08 -0400
Received: from bag.python.org (bag.python.org [194.109.207.14])
	by smtp-vbr6.xs4all.nl (8.13.8/8.13.8) with ESMTP id l6L0b1sr063518;
	Sat, 21 Jul 2007 02:37:01 +0200 (CEST)
	(envelope-from image-sig-bounces at python.org)
Received: from bag.python.org (bag [127.0.0.1])
	by bag.python.org (Postfix) with ESMTP id 629E41E4002;
	Sat, 21 Jul 2007 02:37:01 +0200 (CEST)
X-Original-To: image-sig at python.org
Delivered-To: image-sig at bag.python.org
Received: from bag.python.org (bag [127.0.0.1])
	by bag.python.org (Postfix) with ESMTP id 6E7FB1E4002
	for <image-sig at python.org>; Sat, 21 Jul 2007 02:36:46 +0200 (CEST)
X-Spam-Status: OK 0.004
Received: from bag (HELO bag.python.org) (127.0.0.1)
	by bag.python.org with SMTP; 21 Jul 2007 02:36:46 +0200
Received: from pink.rahul.net (pink.rahul.net [192.160.13.6])
	by bag.python.org (Postfix) with ESMTP
	for <image-sig at python.org>; Sat, 21 Jul 2007 02:36:41 +0200 (CEST)
Received: from violet.rahul.net (violet.rahul.net [192.160.13.70])
	by pink.rahul.net (Postfix) with ESMTP id BF2B82FEE1
	for <image-sig at python.org>; Fri, 20 Jul 2007 17:03:54 -0700 (PDT)
Received: by violet.rahul.net (Postfix, from userid 2926)
	id 34A0CBC45; Fri, 20 Jul 2007 17:03:48 -0700 (PDT)
Received: from localhost (localhost [127.0.0.1])
	by violet.rahul.net (Postfix) with ESMTP id 2EC5CBC44
	for <image-sig at python.org>; Fri, 20 Jul 2007 17:03:48 -0700 (PDT)
Date: Fri, 20 Jul 2007 17:03:48 -0700 (PDT)
From: Terry Carroll <carroll at tjc.com>
X-X-Sender: carroll at violet.rahul.net
To: image-sig at python.org
In-Reply-To: <46A11815.4010805 at famillepinault.fr>
Message-ID: <Pine.LNX.4.44.0707201657560.1341-100000 at violet.rahul.net>
MIME-Version: 1.0
Subject: Re: [Image-SIG] Exif data
X-BeenThere: image-sig at python.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Image Processing with Python SIG <image-sig.python.org>
List-Unsubscribe: <http://mail.python.org/mailman/listinfo/image-sig>,
	<mailto:image-sig-request at python.org?subject=unsubscribe>
List-Archive: <http://mail.python.org/pipermail/image-sig>
List-Post: <mailto:image-sig at python.org>
List-Help: <mailto:image-sig-request at python.org?subject=help>
List-Subscribe: <http://mail.python.org/mailman/listinfo/image-sig>,
	<mailto:image-sig-request at python.org?subject=subscribe>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Sender: image-sig-bounces at python.org
Errors-To: image-sig-bounces at python.org
X-Virus-Scanned: by XS4ALL Virus Scanner

On Fri, 20 Jul 2007, Nicolas Pinault wrote:

> I'd like to extract exif data from jpeg iages.
> Here what I do :
> 
> import Image
> i = Image.open ("my picture.jpeg")
> i.info["exif"]

I don't know what to do with that raw data. 

An alternate approach: i._getexif will give you a dictionary of EXIF data,
and the keys are documented in the dictionary ExifData.TAGS.  Here's a
quickie example:

#####################################################
import Image, ExifTags
i = Image.open ("81224044_fa8bc97c54_o.jpg")
exifdata = i._getexif()
print "tags found in image exif data:"
for key in exifdata.keys():
    try:     
        print " ", ExifTags.TAGS[key]
    except KeyError:
        print " *** Unsupported EXIF tag no. %s" % key

print "a few selected tags:"
print " ExifVersion:", exifdata[36864]  
print " Make:", exifdata[271]   
print " Model:", exifdata[272]
#####################################################


Prints (for this image of mine):
#####################################################
tags found in image exif data:
  ExifVersion
  ComponentsConfiguration
  ApertureValue
  DateTimeOriginal
  DateTimeDigitized
  ExifInteroperabilityOffset
  FlashPixVersion
  MeteringMode
  Flash
  FocalLength
  ExifImageWidth
  FocalPlaneXResolution
  Make
  Model
  Orientation
  YCbCrPositioning
  XResolution
  YResolution
  ExposureTime
  ExposureProgram
  ColorSpace
  UserComment
  ISOSpeedRatings
  ResolutionUnit
   *** Unsupported EXIF tag no. 41987
  FNumber
  DateTime
   *** Unsupported EXIF tag no. 41985
   *** Unsupported EXIF tag no. 41990
  FocalPlaneYResolution
  ExifImageHeight
  FocalPlaneResolutionUnit
   *** Unsupported EXIF tag no. 41986
  ExifOffset
  MakerNote
a few selected tags:
 ExifVersion: 0221
 Make: Canon
 Model: Canon EOS DIGITAL REBEL XT
#####################################################



_______________________________________________
Image-SIG maillist  -  Image-SIG at python.org
http://mail.python.org/mailman/listinfo/image-sig

-- 
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



More information about the Image-SIG mailing list