Instructions to use Thastp/efficientnet_b0 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Thastp/efficientnet_b0 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="Thastp/efficientnet_b0", trust_remote_code=True) pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")# Load model directly from transformers import AutoImageProcessor, AutoModelForImageClassification processor = AutoImageProcessor.from_pretrained("Thastp/efficientnet_b0", trust_remote_code=True) model = AutoModelForImageClassification.from_pretrained("Thastp/efficientnet_b0", trust_remote_code=True) - Notebooks
- Google Colab
- Kaggle
Upload processor
Browse files
image_processing_efficientnet.py
CHANGED
|
@@ -1,6 +1,5 @@
|
|
| 1 |
from PIL import Image
|
| 2 |
from torch import Tensor, stack
|
| 3 |
-
from numpy import ndarray
|
| 4 |
from typing import Union, List
|
| 5 |
|
| 6 |
from transformers.image_processing_utils import BaseImageProcessor, BatchFeature
|
|
|
|
| 1 |
from PIL import Image
|
| 2 |
from torch import Tensor, stack
|
|
|
|
| 3 |
from typing import Union, List
|
| 4 |
|
| 5 |
from transformers.image_processing_utils import BaseImageProcessor, BatchFeature
|