General
Follow


Thoughts about TIMEIT

Steve Eddins on 15 Jan 2025 at 22:33
Latest activity Edit by Adam Danz on 16 Jan 2025 at 20:12

I just published a blog post called "The Story of TIMEIT." I've been thinking about writing something like this ever since Mike Croucher's tic/toc blog post last spring.
There were a lot of opinions about TIMEIT expressed in the comments of that blog post, including some of mine.
My blog post today gives a more full history of the function, its design goals, and how it works. I thought it might prompt more discussion, so I'm creating this thread as a place for it.
If you are an interested user of TIMEIT, feel free to weigh in here with your thoughts. Perhaps the thread will influence MathWorks regarding what to do with TIMEIT, or with related performance measurement capabilities.
Adam Danz
Adam Danz on 16 Jan 2025 at 19:20 (Edited on 16 Jan 2025 at 20:12)
I really value these types of historic perspectives of MATLAB products.
My workflow to measure perfomance in grad school was similar to what timeit is doing except I stored the durations on each iteration so that I could plot the distribution of durations as a boxchart. After collecting data from two versions of a function, the visualization makes it clear whether there is a winner.
It would be great to have those additional outputs.
goc3
goc3 on 16 Jan 2025 at 19:54
I have done similar work in the past, but it often was cumbersome.
It would be great if timeit could take input of two function handles. Then, it could run statistical calculations on runtimes (e.g., t-statistic test) and let the user know (using one of the outputs) if one function really is faster than the other.
Mike Croucher
Mike Croucher on 16 Jan 2025 at 10:25
That's a great post Steve!

Tags

No tags entered yet.