Line segments, overlap, and bits

Paul Rubin http
Wed Mar 26 22:16:38 EDT 2008


Sean Davis <seandavi at gmail.com> writes:
> OR, NOT, etc.).  Any suggestions on how to (1) set up the bit string
> and (2) operate on 1 or more of them?  Java has a BitSet class that
> keeps this kind of thing pretty clean and high-level, but I haven't
> seen anything like it for python.

You could wrap something around the array module, or the bit vector
objects from numarray, or use something like PyJudy (google for it).
Or consider using something like a tree data structure that supports
set operations, rather than a bitmap, if that's closer to what you're
really trying to do.



More information about the Python-list mailing list