[SciPy-user] Passing boolean array to weave.inline

Angus McMorland amcmorl@gmail....
Sat Aug 25 16:54:21 CDT 2007

Hi all,

I'm having trouble passing a boolean array into a weave.inline block.
This works-

def build():
    ar = n.empty((200,200,200))
    return weave.inline( '', ['ar'] )

but this doesn't-

def build():
    ar = n.empty((200,200,200), dtype=bool)
    return weave.inline( '', ['ar'] )

failing with KeyError: '?', and I understand '?' to be the character
code for a boolean array. Is this deliberate, or perhaps a missed type
translation case in weave?


AJC McMorland, PhD Student
Physiology, University of Auckland

More information about the SciPy-user mailing list