[Python-Dev] I think my set module is ready for prime time; comments?
Tue, 23 Jan 2001 15:06:16 -0500
Neil Schemenauer [email@example.com] wrote:
> On Tue, Jan 23, 2001 at 02:06:05PM -0500, Christopher Petrilli wrote:
> > Unfortunately, for me, a Python implementation of Sets is only
> > interesting academicaly. Any time I've needed to work with them at a
> > large scale, I've needed them *much* faster than Python could achieve
> > without a C extension.
> I think this argues that if sets are added to the core they
> should be implemented as an extension type with the speed of
> dictionaries and the memory usage of lists. Basicly, we would
> use the implementation of PyDict but drop the values.
This is effectively the implementation that Zope has for Sets. In
addition we have "buckets" that have scores on them (which are
implemented as a modified BTree).
Unfortunately Jim Fulton (who wrote all the code for that level) is in
a meeting, but I hope he'll comment on the implementation that was
chosen for our software.
| Christopher Petrilli