Spaces:
Sleeping
Sleeping
goodchaeee
commited on
Commit
β’
a83355b
1
Parent(s):
01dadd8
Update app.py
Browse files
app.py
CHANGED
@@ -2,7 +2,7 @@ import streamlit as st
|
|
2 |
from transformers import pipeline
|
3 |
from PIL import Image
|
4 |
# TO-DD: ??? λΆλΆμ μ½λλ₯Ό μμ±νμμ€
|
5 |
-
pipeline = pipeline(
|
6 |
|
7 |
st.title("Hot Dog? Or Not?")
|
8 |
|
@@ -14,7 +14,7 @@ if file_name is not None:
|
|
14 |
image = Image.open(file_name)
|
15 |
col1.image(image, use_column_width=True)
|
16 |
# TO-DO: ??? λΆλΆμ μ½λλ₯Ό μμ±νμμ€
|
17 |
-
predictions =
|
18 |
|
19 |
col2.header("Probabilities")
|
20 |
for p in predictions:
|
|
|
2 |
from transformers import pipeline
|
3 |
from PIL import Image
|
4 |
# TO-DD: ??? λΆλΆμ μ½λλ₯Ό μμ±νμμ€
|
5 |
+
pipeline = pipeline(task="image-classification",model="julien-c/hotdog-not-hotdog")
|
6 |
|
7 |
st.title("Hot Dog? Or Not?")
|
8 |
|
|
|
14 |
image = Image.open(file_name)
|
15 |
col1.image(image, use_column_width=True)
|
16 |
# TO-DO: ??? λΆλΆμ μ½λλ₯Ό μμ±νμμ€
|
17 |
+
predictions = pipeline(image)
|
18 |
|
19 |
col2.header("Probabilities")
|
20 |
for p in predictions:
|