DumbledoreWiz commited on
Commit
e8839a4
·
verified ·
1 Parent(s): 674ef1d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -3,6 +3,8 @@ from transformers import ViTForImageClassification, ViTFeatureExtractor, ViTConf
3
  import gradio as gr
4
  from PIL import Image
5
 
 
 
6
  # Define the class labels as used during training
7
  labels = ['Leggings', 'Jogger', 'Palazzo', 'Cargo', 'Dresspants', 'Chinos']
8
 
@@ -12,7 +14,7 @@ config = ViTConfig.from_pretrained("DumbledoreWiz/PantsShape")
12
  # Load the ViT model with the configuration
13
  model = ViTForImageClassification.from_pretrained("DumbledoreWiz/PantsShape", config=config)
14
  feature_extractor = ViTFeatureExtractor.from_pretrained("DumbledoreWiz/PantsShape")
15
-
16
  # Set the model to evaluation mode
17
  model.eval()
18
 
 
3
  import gradio as gr
4
  from PIL import Image
5
 
6
+
7
+ print("p1")
8
  # Define the class labels as used during training
9
  labels = ['Leggings', 'Jogger', 'Palazzo', 'Cargo', 'Dresspants', 'Chinos']
10
 
 
14
  # Load the ViT model with the configuration
15
  model = ViTForImageClassification.from_pretrained("DumbledoreWiz/PantsShape", config=config)
16
  feature_extractor = ViTFeatureExtractor.from_pretrained("DumbledoreWiz/PantsShape")
17
+ print("Model loaded")
18
  # Set the model to evaluation mode
19
  model.eval()
20