[Bf-python] Fwd: ANN: PyJudy 1.0

Toni Alatalo antont at kyperjokki.fi
Mon Nov 7 15:50:43 CET 2005


dunno if you guys follow these but this seemed quite cool .. perhaps something 
for http://mediawiki.blender.org/index.php/BlenderDev/PythonBlender even .. 
although i'm most interested in this for it, "Numeric3 has begun which aims 
to replace Numeric as the array object in SciPy. It's more ambitious aim is 
to be included in the Python core. A design document has been posted and your 
comments are appreciated." http://www.scipy.org/wikis/numdesign/

----------  Forwarded Message  ----------

Subject: ANN: PyJudy 1.0
Date: Sunday 06 November 2005 20:35
From: Andrew Dalke <dalke at dalkescientific.com>
To: python-announce-list at python.org

Over the last three weeks of on-and-off work I've developed and have
just released PyJudy 1.0, a wrapper to the Judy sparse dynamic array
library.  It is available for download at
   http://dalkescientific.com/Python/PyJudy.html

Judy, from http://judy.sourceforge.net/ , is ...

    a C library that provides a state-of-the-art core technology that
    implements a sparse dynamic array. Judy arrays are declared simply
    with a null pointer. A Judy array consumes memory only when it is
    populated, yet can grow to take advantage of all available memory
    if desired.  Judy's key benefits are scalability, high performance,
    and memory efficiency. A Judy array is extensible and can scale up
    to a very large number of elements, bounded only by machine memory.
    Since Judy is designed as an unbounded array, the size of a Judy
    array is not pre-allocated but grows and shrinks dynamically with
    the array population.

Continuing from the PyJudy page at
   http://dalkescientific.com/Python/PyJudy.html

    PyJudy arrays are similar to Python dictionaries and sets. The
    primary difference is that PyJudy keys are sorted; by unsigned
    value if an integer, byte ordering if a string and object id if
    a Python object. In addition to wrapping the underlying Judy
    functions, PyJudy implements a subset of the Python dictionary
    interface for the JudyL and JudySL API and a subset of the set
    interface for the Judy1 API, along with some extensions for
    iterating a subrange of the sorted keys, values and items.


In my performance tests I found that overall JudyL arrays were a
bit slower than Python dictionaries.  Part of that might be my
inexperience with the details of writing Python extensions.  Part
might be that JudyL arrays are sorted.

I found that the Judy1 arrays were faster than the set class
in Python 2.4.  It'll be interesting to see how Raymond's new
set implementation affects that.

I did not do any memory comparisons.

PyJudy is distributed under the MIT license because that
has few upper-case letters than the BSD one.

					Andrew Dalke
					dalke at dalkescientific.com


					Andrew
					dalke at dalkescientific.com

--
http://mail.python.org/mailman/listinfo/python-announce-list

        Support the Python Software Foundation:
        http://www.python.org/psf/donations.html

-------------------------------------------------------



More information about the Bf-python mailing list