Spaces:
Runtime error
Runtime error
Commit ·
f58179a
1
Parent(s): e1b0e11
Update app.py
Browse files32 unmodified lines33343536373839404142434445464732 unmodified linespred_confidence = result[idx][2]textdic_easyocr[pred_text] = {}textdic_easyocr[pred_text]['pred_confidence'] = pred_confidencedf = pd.DataFrame.from_dict(textdic_easyocr).Tst.table(df)ax1.plot(agg_df.year, agg_df.rating)st.pyplot(fig1)for res in result:top_left = tuple(res[0][0]) # top left coordinates as tuplebottom_right = tuple(res[0][2]) # bottom right coordinates as tuple32 unmodified lines33343536373839404142434432 unmodified linespred_confidence = result[idx][2]textdic_easyocr[pred_text] = {}textdic_easyocr[pred_text]['pred_confidence'] = pred_confidence# create a dataframe which shows the predicted text and prediction confidencedf = pd.DataFrame.from_dict(textdic_easyocr).Tst.table(df)# Plot image with text box and predicted textfor res in result:top_left = tuple(res[0][0]) # top left coordinates as tuplebottom_right = tuple(res[0][2]) # bottom right coordinates as tuple
app.py+3-6