rkern / line_profiler

(OLD REPO) Line-by-line profiling for Python - Current repo ->
https://github.com/pyutils/line_profiler
Other
3.6k stars 256 forks source link

How to select timer unit? #136

Closed kylekeppler closed 5 years ago

kylekeppler commented 5 years ago

I see that #98 adds the ability to set the unit for the timer used. How do I input that?

I am currently doing:

kernprof -l myscript.py

then

python -m line_profiler myscript.py.lprof
rkaplan commented 5 years ago

I have the same request. It looks like that PR only adds support for selecting timer units using the Jupyter notebook magic command. Maybe @caethan or @rkern can add support for this when using python -m line_profiler ... as well?

caethan commented 5 years ago

Sorry, currently magic command only. I don't have time to add support for using it from the command line, but I'd be happy to look at pull requests to do so.