[Numpy-discussion] Optionally using Numeric in another compiled extension package.

peter.chang at nottingham.ac.uk peter.chang at nottingham.ac.uk
Thu Jan 16 08:47:04 CST 2003


On Wed, 15 Jan 2003, Chris Barker wrote:
[...]

> My idea is that I could make sure Numeric was around at compile time, so
> I could use all the Numeric API to access the array data, but it
> wouldn't have to be installed at runtime, as none of the Numeric calls
> would be executed if Numeric hadn't been imported. Would this work, or
> would the system try to load the .dll or .so or whatever even if the
> calls weren't executed?

One way is to import a dynamic library, explicitly, which has glue code to
handle the array objects when you need them.

[...]

> My timing indicated something different, but I'm using Linux/wxGTK/X11,
> and I think the drawing calls return after the message has been sent to
> X, but X may not have completed the actual drawing yet.

That's right. X's communication model between client and server is
asynchronous.

> This means that I'm not timing the whole process, and if I did, I might
> not see such a difference.

You can synchronise the output buffer using XSync(3) and then do the 
timing.

Peter






More information about the Numpy-discussion mailing list