Spaces:
Runtime error
Runtime error
Commit
·
cdc5cee
1
Parent(s):
7f4a322
Update app.py
Browse files
app.py
CHANGED
@@ -1,9 +1,14 @@
|
|
1 |
import gradio as gr
|
2 |
from transformers import pipeline
|
|
|
|
|
|
|
|
|
|
|
3 |
|
4 |
pipe = pipeline(task="image-classification",
|
5 |
# model that can do 22k-category classification
|
6 |
-
model=
|
7 |
gr.Interface.from_pipeline(pipe,
|
8 |
title="22k Image Classification",
|
9 |
description="Object Recognition using Microsoft BEIT",
|
|
|
1 |
import gradio as gr
|
2 |
from transformers import pipeline
|
3 |
+
from transformers import AutoFeatureExtractor, AutoModelForImageClassification
|
4 |
+
|
5 |
+
extractor = AutoFeatureExtractor.from_pretrained("Rajaram1996/FacialEmoRecog")
|
6 |
+
|
7 |
+
model_heh = AutoModelForImageClassification.from_pretrained("Rajaram1996/FacialEmoRecog")
|
8 |
|
9 |
pipe = pipeline(task="image-classification",
|
10 |
# model that can do 22k-category classification
|
11 |
+
model=model_heh)
|
12 |
gr.Interface.from_pipeline(pipe,
|
13 |
title="22k Image Classification",
|
14 |
description="Object Recognition using Microsoft BEIT",
|