Data Frame Error

Hello everyone,
I am working on a Streamlit app for my project and encountering a MessageSizeError when attempting to display a large DataFrame using the st.dataframe function. The error message is: “Data of size 1000.00 MB exceeds the message size limit of 200.0 MB.”

Here is a snippet of my code:

Create a data frame

data = {‘Name of file’: }
df = pd.DataFrame(data)

Display dataframe

st.dataframe(df)

I believe the issue is related to the size of the DataFrame being too large. Can anyone provide guidance on how to resolve this MessageSizeError? Are there any specific techniques or best practices for efficiently displaying large datasets in a Streamlit app?
Thank you in advance for your assistance! :innocent:

2 Likes

You can easily check this by using st.dataframe(df.tail(200)) or something. The Dataframe will be passed then. Just have to make it smaller.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.