Update README.md
Browse files
README.md
CHANGED
@@ -79,15 +79,13 @@ Users should evaluate the model on their specific crops and farming conditions.
|
|
79 |
## How to Get Started with the Model
|
80 |
|
81 |
```python
|
82 |
-
import matplotlib.pyplot as plt
|
83 |
from PIL import Image, UnidentifiedImageError
|
84 |
from transformers import ViTFeatureExtractor, ViTForImageClassification
|
85 |
-
feature_extractor = ViTFeatureExtractor.from_pretrained('
|
86 |
model = ViTForImageClassification.from_pretrained(
|
87 |
'wambugu1738/crop_leaf_diseases_vit',
|
88 |
ignore_mismatched_sizes=True
|
89 |
)
|
90 |
-
from PIL import Image
|
91 |
image = Image.open('<image_path>')
|
92 |
inputs = feature_extractor(images=image, return_tensors="pt")
|
93 |
outputs = model(**inputs)
|
|
|
79 |
## How to Get Started with the Model
|
80 |
|
81 |
```python
|
|
|
82 |
from PIL import Image, UnidentifiedImageError
|
83 |
from transformers import ViTFeatureExtractor, ViTForImageClassification
|
84 |
+
feature_extractor = ViTFeatureExtractor.from_pretrained('wambugu71/crop_leaf_diseases_vit')
|
85 |
model = ViTForImageClassification.from_pretrained(
|
86 |
'wambugu1738/crop_leaf_diseases_vit',
|
87 |
ignore_mismatched_sizes=True
|
88 |
)
|
|
|
89 |
image = Image.open('<image_path>')
|
90 |
inputs = feature_extractor(images=image, return_tensors="pt")
|
91 |
outputs = model(**inputs)
|