Resource limit: Oh No, Error running app.
Lin-jun-xiang opened this issue · comments
Problem
- The free model will use
HuggingFaceEmbeddings
which cause lots of memory. - The streamlit free server just have 1GB RAM.
- When there have multiple users using free model in the same time, our app will "over the resource limits".
Reference
Suggestion
- improve streamlit app performance
- RAM in streamlit
- Select a lower embedding model of HuggingFace
-
We use the windows task manager to track the memory usages.
-
Please note that even we declare
model=None
inapp.py
. While the Streamlit app's feature is that "any user interaction will cause the code to be rerun from top to bottom," Python does not immediately release resources, leading to resource consumption issues. (see stackoverflow) -
Solution