[Numpy-discussion] profiling line by line

Arnar Flatberg arnar.flatberg@gmail....
Thu Sep 18 11:51:36 CDT 2008


On Wed, Sep 17, 2008 at 10:33 PM, Robert Kern <robert.kern@gmail.com> wrote:

> On Wed, Sep 17, 2008 at 07:12, Arnar Flatberg <arnar.flatberg@gmail.com>
> wrote:
> >
> > On Wed, Sep 17, 2008 at 3:56 AM, Robert Kern <robert.kern@gmail.com>
> wrote:
>

> It should be straightforward to make an ipython %magic, yes. There are
> some questions as to how that would work, though. Do you want the
> top-level code in the file to be profiled?
>
I dont think that will be my primary use.


> Or do you just want
> functions defined inside to be profiled?

That was my initial thought, yes


> Do you want to be able to
> specify functions defined outside of the code to be profiled?

Sounds complicated, but that would be nice.

I'll play around with ipythons %magic to see if I can get a workflow Im
comfortable with.
I was thinking something in the line of ipython's %prun for a quick looksy,
and the possibility to easily write small scripts to test different inputs
(small/large arrays etc.) to a specific function.
Any recommendations are very welcome. I do not have much experience in
profiling code.

Arnar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/numpy-discussion/attachments/20080918/8b0052a0/attachment.html 


More information about the Numpy-discussion mailing list