Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > ANN: cElementTree 0.9.8 (january 23, 2005)

Reply
Thread Tools

ANN: cElementTree 0.9.8 (january 23, 2005)

 
 
Fredrik Lundh
Guest
Posts: n/a
 
      01-23-2005
effbot.org proudly presents release 0.9.8 of the cElementTree library,
a fast and very efficient implementation of the ElementTree API, for
Python 2.1 and later. On typical documents, it's 15-20 times faster
than the Python version of ElementTree, and uses 2-5 times less
memory.

Here are some benchmark figures, using a number of popular XML tool-
kits to parse a 3405k document-style XML file from disk:

library memory time
------------------------------------------------------------
amara 20300k 6.4s
minidom (python 2.4) 53000k 1.4s
ElementTree 1.2.4 14500k 1.1s
cDomlette 20500k 0.54s
pyRXPU 10850k 0.175s
libxml2 16000k 0.098s
cElementTree 0.9 4900k 0.047s
------------------------------------------------------------
readlines (read as utf- 8850k 0.093s
readlines (read as ascii) 5050k 0.032s
------------------------------------------------------------

This release also includes a new "iterparse" mechanism, which can be
used to process the tree as it is being built. While not quite as
fast as a full parse, it's over 4 times faster than Python's standard
SAX interface, and even a bit faster than sgmlop.

The library is available as C source code, and as Windows installers
for all recent Python versions. Get your copy here:

http://effbot.org/downloads#celementtree

The cElementTree module uses some support functions from the standard
ElementTree library, and will not work properly without it. If you
haven't installed it already, you can get it from:

http://effbot.org/downloads#elementtree

enjoy /F

"effbot.org -- not knowing how Python is used since 1995"



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using cElementTree and elementtree.ElementInclude Mark E. Smith Python 0 10-23-2006 02:40 PM
Using cElementTree and elementtree.ElementInclude Mark Python 0 10-20-2006 09:38 PM
cElementTree encoding woes Diez B. Roggisch Python 3 02-20-2006 11:55 AM
cElementTree clear semantics Igor V. Rafienko Python 27 09-26-2005 11:56 AM
Subclassing cElementTree.Element Kent Johnson Python 1 02-08-2005 08:50 AM



Advertisments