[Numpy-discussion] Getting rid of annoying weave nag (original) (raw)

Fernando Perez fperez.net at gmail.com
Fri Jun 9 17:19:14 EDT 2006


On 6/9/06, David M. Cooke <cookedm at physics.mcmaster.ca> wrote:

On Thu, Jun 08, 2006 at 11:28:04PM -0600, Fernando Perez wrote:

> Anyone object to this patch against current numpy SVN to get rid of > this thing? (tracking where the hell that thing was coming from was > all kinds of fun)

Go ahead. I'm against random messages being printed out anyways -- I'd get rid of the '<weave: compiling>' too. There's a bunch of code in scipy with 'print' statements that I don't think belong in a library. (Now, if we defined a logging framework, that'd be ok with me!)

Before I commit anything, let's decide on that one. Weave used to print 'None' whenever it compiled anything, I changed it a while ago to the current 'weave:compiling'. I'm also of the opinion that libraries should operate quietly, but with weave I've always wanted that message in there. The reason is that when weave compiles (esp. with blitz in the picture), the execution takes a long time. The same function goes from miliseconds to 30 seconds of run time depending on whether compilation is happening or not.

This difference is so dramatic that I think a message is justified (absent a proper logging framework). It's helpful to know that the time is going into c++ compilation, and not your code hanging for 30 seconds.

Opinions?

f



More information about the NumPy-Discussion mailing list