Runtime profiler for Streamlit, powered by pyinstrument
Project description
streamlit-profiler 🏄🏼
Runtime profiler for Streamlit, powered by pyinstrument.
streamlit-profiler is a Streamlit component that helps you find out which parts of your app are slow. It profiles the code via pyinstrument and shows the results right within your Streamlit app.
Alpha version, use with care.
⏱️ Live demo ⏱️
Installation
pip install streamlit-profiler
Usage
import streamlit as st
from streamlit_profiler import Profiler
with Profiler():
st.title("My app")
# ... other code
# Or:
# p = Profiler()
# p.start()
# ...
# p.stop()
Then start your app as usual: streamlit run my_app.py
The Profiler
class is an extension of pyinstrument.Profiler
, so you can use
all of its functions.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file streamlit-profiler-0.2.4.tar.gz
.
File metadata
- Download URL: streamlit-profiler-0.2.4.tar.gz
- Upload date:
- Size: 3.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.8 CPython/3.8.5 Darwin/20.5.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0d87494abdbd9d8372fc004360e06e18dfce316432853d210334026bf616cd2b |
|
MD5 | 8dd40742d51a2c8da13333c32559ab5d |
|
BLAKE2b-256 | f4ec23e0cc71902cae6373fcbf76d76bbae423908b53279aa2fc2e9c01ddbef7 |
File details
Details for the file streamlit_profiler-0.2.4-py3-none-any.whl
.
File metadata
- Download URL: streamlit_profiler-0.2.4-py3-none-any.whl
- Upload date:
- Size: 3.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.8 CPython/3.8.5 Darwin/20.5.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 66b0a95da4bd2377ee1c7c9020f5b535bb03cd77ffe801b341dfaa2490676506 |
|
MD5 | ffc9c50833b219858184825d0a28b7ef |
|
BLAKE2b-256 | f49a56378a39d060b2ac883e947c23aaa8688ad7991636151e68ec08b264a37e |