Spaces:
Runtime error
Runtime error
Rename app.txt to app.py
Browse files- app.txt → app.py +1 -2
app.txt → app.py
RENAMED
@@ -1,9 +1,8 @@
|
|
1 |
-
SeyedAli/Food-Image-Classification-VIT
|
2 |
import gradio as gr
|
3 |
import torch
|
4 |
from transformers import ViTFeatureExtractor,pipeline
|
5 |
|
6 |
-
model = ViTFeatureExtractor.from_pretrained(
|
7 |
|
8 |
def FoodClassification(image):
|
9 |
pipline = pipeline(task="image-classification", model=model)
|
|
|
|
|
1 |
import gradio as gr
|
2 |
import torch
|
3 |
from transformers import ViTFeatureExtractor,pipeline
|
4 |
|
5 |
+
model = ViTFeatureExtractor.from_pretrained('SeyedAli/Food-Image-Classification-VIT')
|
6 |
|
7 |
def FoodClassification(image):
|
8 |
pipline = pipeline(task="image-classification", model=model)
|