From ee90cca9021642ca2dfbc9b7ffa544e0060913d8 Mon Sep 17 00:00:00 2001 From: Tom Zayats Date: Thu, 12 Dec 2024 22:09:40 -0800 Subject: [PATCH] update how we store df results --- journeys/evaluation.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/journeys/evaluation.py b/journeys/evaluation.py index 9765394c..00eb7c7c 100644 --- a/journeys/evaluation.py +++ b/journeys/evaluation.py @@ -275,10 +275,10 @@ def write_eval_results(frame: pd.DataFrame) -> None: # Save results to frame as string frame_to_write["ANALYST_RESULT"] = frame["ANALYST_RESULT"].apply( - lambda x: x.to_string(index=False) if isinstance(x, pd.DataFrame) else x + lambda x: x.to_json(orient="records") if isinstance(x, pd.DataFrame) else x ) frame_to_write["GOLD_RESULT"] = frame["GOLD_RESULT"].apply( - lambda x: x.to_string(index=False) if isinstance(x, pd.DataFrame) else x + lambda x: x.to_json(orient="records") if isinstance(x, pd.DataFrame) else x ) frame_to_write["SEMANTIC_MODEL_STRING"] = st.session_state["working_yml"]