vm24 adi-123 commited on
Commit
b421cb9
1 Parent(s): 5db7c63

Update app.py (#1)

Browse files

- Update app.py (3e3120479f19666ccbce3c04bf443a01d6dca910)


Co-authored-by: Aditya Chourasiya <adi-123@users.noreply.huggingface.co>

Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -20,4 +20,12 @@ if uploaded_file is not None:
20
  result = pipe(image)
21
 
22
  # Display the result
23
- st.write(result)
 
 
 
 
 
 
 
 
 
20
  result = pipe(image)
21
 
22
  # Display the result
23
+ st.write("Classification Result:")
24
+ st.write("---------------")
25
+
26
+ for i, res in enumerate(result):
27
+ label = res["label"]
28
+ score = res["score"]
29
+ st.write(f"**{i+1}. {label}**: {score:.2f}%")
30
+
31
+ st.write("---------------")