Upload README.md with huggingface_hub
Browse files
README.md
ADDED
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
|
2 |
+
---
|
3 |
+
tags:
|
4 |
+
- image-classification
|
5 |
+
- ecology
|
6 |
+
- fungi
|
7 |
+
- FGVC
|
8 |
+
library_name: DanishFungi
|
9 |
+
license: cc-by-nc-4.0
|
10 |
+
---
|
11 |
+
# Model card for BVRA/DF23M-inception_v4.tf_in1k-299
|
12 |
+
|
13 |
+
## Model Details
|
14 |
+
- **Model Type:** inception_v4.tf_in1k
|
15 |
+
- **Model Stats:**
|
16 |
+
- Params (M): ??
|
17 |
+
- Image size: 299 x 299
|
18 |
+
- **Papers:**
|
19 |
+
- **Original:** ??
|
20 |
+
- **Train Dataset:** DF23M --> https://sites.google.com/view/danish-fungi-dataset
|
21 |
+
|
22 |
+
## Model Usage
|
23 |
+
### Image Embeddings
|
24 |
+
```python
|
25 |
+
import timm
|
26 |
+
import torch
|
27 |
+
import torchvision.transforms as T
|
28 |
+
from PIL import Image
|
29 |
+
from urllib.request import urlopen
|
30 |
+
model = timm.create_model("hf-hub:BVRA/DF23M-inception_v4.tf_in1k-299", pretrained=True)
|
31 |
+
model = model.eval()
|
32 |
+
train_transforms = T.Compose([T.Resize(299),
|
33 |
+
T.ToTensor(),
|
34 |
+
T.Normalize([0.5, 0.5, 0.5], [0.5, 0.5, 0.5])])
|
35 |
+
img = Image.open(PATH_TO_YOUR_IMAGE)
|
36 |
+
output = model(train_transforms(img).unsqueeze(0)) # output is (batch_size, num_features) shaped tensor
|
37 |
+
# output is a (1, num_features) shaped tensor
|
38 |
+
```
|
39 |
+
|
40 |
+
## Citation
|
41 |
+
https://openaccess.thecvf.com/content/WACV2022/papers/Picek_Danish_Fungi_2020_-_Not_Just_Another_Image_Recognition_Dataset_WACV_2022_paper.pdf
|