yuvipanda / notebooksharing.space

BSD 3-Clause "New" or "Revised" License
84 stars 10 forks source link

Cell execution times #28

Open kafonek opened 3 years ago

kafonek commented 3 years ago

The reason I discovered this awesome application and tried posting a notebook was to demonstrate different approaches to solving a Python problem that people were offering me on a stackoverflow post. However, a key point in that discussion was how long each approach took to execute.

%%timeit is a great piece of magic, and I use it often. In this particular case, I thought seeing the single cell execution times using the classic Notebook ExecuteTime extension (from jupyter-contrib-nbextensions) was good enough to give a general sense of execution speed and greatly improved the readability over having lots of %%timeit outputs and not being able to display last-line-of-cell-outputs (because timeit eats those).

I'd like to see the ExecuteTime info displayed if it's part of the cell metadata in the uploaded Notebook. Here's an example of what the extension looks like and one particular cell metadata opened up:

image