Instructions to use FredZhang7/efficientnetv25_rw_s with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use FredZhang7/efficientnetv25_rw_s with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="FredZhang7/efficientnetv25_rw_s", trust_remote_code=True) pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("FredZhang7/efficientnetv25_rw_s", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
Commit ·
2995779
1
Parent(s): cdbd71c
update code
Browse files
README.md
CHANGED
|
@@ -26,13 +26,13 @@ in terms of top-1 accuracy, efficiency, and robustness on my dataset and [CMAD b
|
|
| 26 |
|
| 27 |
<br>
|
| 28 |
|
| 29 |
-
### Load
|
| 30 |
```python
|
| 31 |
from transformers import AutoModel
|
| 32 |
model = AutoModel.from_pretrained("FredZhang7/efficientnetv2.5_rw_s", trust_remote_code=True)
|
| 33 |
```
|
| 34 |
|
| 35 |
-
###
|
| 36 |
To change the number of classes, replace the linear classification layer.
|
| 37 |
Here's an example of how to convert the architecture into a trainable model.
|
| 38 |
```bash
|
|
|
|
| 26 |
|
| 27 |
<br>
|
| 28 |
|
| 29 |
+
### Load PyTorch Jit Model with 1000 Classes
|
| 30 |
```python
|
| 31 |
from transformers import AutoModel
|
| 32 |
model = AutoModel.from_pretrained("FredZhang7/efficientnetv2.5_rw_s", trust_remote_code=True)
|
| 33 |
```
|
| 34 |
|
| 35 |
+
### Load Model with Custom Classes
|
| 36 |
To change the number of classes, replace the linear classification layer.
|
| 37 |
Here's an example of how to convert the architecture into a trainable model.
|
| 38 |
```bash
|