Skip to content

Commit

Permalink
make species stats up to 70% faster
Browse files Browse the repository at this point in the history
  • Loading branch information
ehpersonal38 committed May 19, 2023
1 parent 0e40aa5 commit d224f04
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scripts/plotly_streamlit.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ def get_connection(path: str):
return sqlite3.connect(path, check_same_thread=False)


def get_data(conn: Connection):
@st.cache_data()
def get_data(_conn: Connection):
df1 = pd.read_sql("SELECT * FROM detections", con=conn)
return df1

Expand Down

0 comments on commit d224f04

Please sign in to comment.