kmcgrady / streamlit-autorefresh

An autorefresh component for Streamlit apps
MIT License
176 stars 16 forks source link

autorefresh SOME things #2

Closed malfonsoNeoris closed 2 years ago

malfonsoNeoris commented 3 years ago

hi, this is great. can i autorefresh only part of the application? for example im loading some ML models, and capturing a video and doing thins on the video. this refresh is great for that.. but i only want to rerun a funcion.. not the whole script. thanks

kmcgrady commented 2 years ago

Hey @malfonsoNeoris ! At this time, Streamlit does not allow refreshing a specific function without rerunning a script. The only option would be to consider caching so when the script is rerun, heavy work is not executed multiple times. We have some new experimental caching primitives that might also help.