ozair23 commited on
Commit
5a2adf6
·
verified ·
1 Parent(s): b33f80a

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +11 -0
README.md CHANGED
@@ -19,6 +19,17 @@ datasets:
19
  - A2H0H0R1/plant-disease-new
20
  license: apache-2.0
21
  ---
 
 
 
 
 
 
 
 
 
 
 
22
 
23
  # Model Trained Using AutoTrain
24
 
 
19
  - A2H0H0R1/plant-disease-new
20
  license: apache-2.0
21
  ---
22
+ #Inference Pipeline
23
+ --
24
+ from transformers import AutoModelForImageClassification, AutoProcessor
25
+
26
+ model = AutoModelForImageClassification.from_pretrained("ozair23/autotrain-w5nk2-rvmqx")
27
+ processor = AutoProcessor.from_pretrained("ozair23/autotrain-w5nk2-rvmqx")
28
+
29
+ def predict(image):
30
+ inputs = processor(images=image, return_tensors="pt")
31
+ outputs = model(**inputs)
32
+ return outputs
33
 
34
  # Model Trained Using AutoTrain
35