Upload EfficientNet-B0 fine-tuned model (100 classes)
Browse files- README.md +184 -0
- config.json +293 -0
- model.safetensors +3 -0
- model_info.json +119 -0
- preprocessor_config.json +29 -0
README.md
ADDED
|
@@ -0,0 +1,184 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
language: en
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
library_name: transformers
|
| 5 |
+
tags:
|
| 6 |
+
- image-classification
|
| 7 |
+
- efficientnet
|
| 8 |
+
- pytorch
|
| 9 |
+
- computer-vision
|
| 10 |
+
datasets:
|
| 11 |
+
- custom
|
| 12 |
+
metrics:
|
| 13 |
+
- accuracy
|
| 14 |
+
- f1
|
| 15 |
+
base_model: google/efficientnet-b0
|
| 16 |
+
---
|
| 17 |
+
|
| 18 |
+
# huytranduck/efficientnet_b0_50x_dataset
|
| 19 |
+
|
| 20 |
+
## Model Description
|
| 21 |
+
|
| 22 |
+
This is a fine-tuned **EfficientNet-B0** model for image classification with **100 classes**.
|
| 23 |
+
|
| 24 |
+
The model is based on `google/efficientnet-b0` and has been fine-tuned on a custom dataset for specialized image classification tasks.
|
| 25 |
+
|
| 26 |
+
### Model Architecture
|
| 27 |
+
- **Base Model**: EfficientNet-B0
|
| 28 |
+
- **Framework**: PyTorch + Transformers
|
| 29 |
+
- **Task**: Image Classification
|
| 30 |
+
- **Classes**: 100
|
| 31 |
+
- **Input Size**: 224x224 pixels
|
| 32 |
+
|
| 33 |
+
### Classes
|
| 34 |
+
```
|
| 35 |
+
['Acacia melanoxylon', 'Acer saccharinum', 'Afzelia africana', 'Afzelia pachyloba', 'Afzelia quanzensis', 'Albizia lucida (Albizia lucidior)', 'Allophylus cobbe (Pometia pinnata)', 'Anisoptera costata (Anisoptera Robusta)', 'Apuleia\xa0leiocarpa', 'Artocarpus calophyllus (Artocarpus asperulus)', 'Artocarpus heterophyllus', 'Autranella congolensis', 'Berlinia bracteosa', 'Betula pendula', 'Bobgunnia fistuloides (Swartzia fistuloides)', 'Brachystegia sp', 'Burckella obovata', 'Burretiodendron tonkinense', 'Callitris columellaris', 'Calocedrus sp', 'Canarium album', 'Chrysophyllum sp', 'Cinnamomum camphora', 'Clarisia racemosa', 'Colophospermum mopane', 'Cunninghamia lanceolata', 'Cupressus funebris (Cupressus pendula)', 'Cylicodiscus gabunensis', 'Dalbergia cochinchinensis', 'Dalbergia oliveri', 'Detarium macrocarpum', 'Dialium bipindense', 'Didelotia africana', 'Diospyros mun', 'Diospyros salletii', 'Distemonanthus benthamianus', 'Engelhardia chrysolepis (Engelhardia roxburghiana)', 'Entandrophragma cylindricum', 'Entandrophragma utile', 'Erythrophleum fordii\xa0', 'Erythrophleum ivorense', 'Eucalyptus cladocalyx', 'Eucalyptus grandis', 'Eucalyptus microcorys', 'Eucalyptus saligna', 'Fokienia hodginsii', 'Fraxinus excelsior', 'Gilbertiodendron dewevrei', 'Guarea cedrata', 'Guibourtia coleosperma', 'Heritiera littoralis', 'Hevea brasiliensis', 'Homalium caryophyllaceum', 'Homalium foetidum', 'Hopea iriana', 'Hopea pierrei', 'Hymenaea courbaril', 'Hymenolobium heterocarpum', 'Juglans regia', 'Khaya senegalensis', 'Klainedoxa gabonensis', 'Lithocarpus ducampii', 'Lophira alata', 'Magnolia hypolampra', 'Martiodendron parviflorum', 'Milicia excelsa', 'Milicia regia', 'Millettia laurentii', 'Monopetalanthus letestui (Bikinia letestui)', 'Myracrodruon urundeuva', 'Myroxylon balsamum', 'Myroxylon balsamum_v2', 'Myroxylon peruiferum', 'Nauclea diderrichii', 'Pachyelasma tessmannii', 'Palaquium waburgianum', 'Pericopsis elata', 'Pinus sp', 'Piptadeniastrum africanum', 'Populus sp', 'Prunus serotina', 'Pterocarpus macrocarpus', 'Pterocarpus soyauxii', 'Pterocarpus sp', 'Qualea paraensis', 'Quercus petraea', 'Quercus robur', 'Quercus rubra', 'Samanea saman', 'Shorea hypochra (Anthoshorea hypochra)', 'Shorea roxburghii (Anthoshorea roxburghii)', 'Sindora cochinchinensis', 'Staudtia stipitata', 'Syzygium hemisphericum (Syzygium chanlos)', 'Tarrietia cochinchinensis (Heritiera cochinchinesis)', 'Tectona grandis', 'Terminalia superba', 'Tetraberlinia bifoliolata', 'Toona sureni', 'Xylia xylocarpa']
|
| 36 |
+
```
|
| 37 |
+
|
| 38 |
+
## Training Details
|
| 39 |
+
|
| 40 |
+
### Training Configuration
|
| 41 |
+
- **Epochs**: 2
|
| 42 |
+
- **Batch Size**: 64
|
| 43 |
+
- **Learning Rate**: 0.0001
|
| 44 |
+
- **Optimizer**: AdamW
|
| 45 |
+
- **Loss Function**: CrossEntropyLoss
|
| 46 |
+
- **Image Size**: 224x224
|
| 47 |
+
- **Data Augmentation**: ✅ Enabled
|
| 48 |
+
- Random Horizontal Flip (p=0.5)
|
| 49 |
+
- Random Vertical Flip (p=0.2)
|
| 50 |
+
- Random Affine (shear=0.2)
|
| 51 |
+
- Color Jitter (brightness, contrast, saturation, hue=0.2)
|
| 52 |
+
- Random Rotation (15°)
|
| 53 |
+
|
| 54 |
+
### Data Augmentation Pipeline
|
| 55 |
+
```python
|
| 56 |
+
transforms.Compose([
|
| 57 |
+
transforms.RandomApply([
|
| 58 |
+
transforms.ColorJitter(brightness=0.2, contrast=0.2, saturation=0.2, hue=0.2),
|
| 59 |
+
transforms.RandomHorizontalFlip(p=0.5),
|
| 60 |
+
transforms.RandomVerticalFlip(p=0.2),
|
| 61 |
+
transforms.RandomAffine(degrees=15, shear=0.2, scale=(0.9, 1.1)),
|
| 62 |
+
transforms.RandomRotation(degrees=15),
|
| 63 |
+
], p=0.5),
|
| 64 |
+
transforms.Resize((224, 224)),
|
| 65 |
+
transforms.RandomResizedCrop(224, scale=(0.8, 1.0)),
|
| 66 |
+
transforms.ToTensor(),
|
| 67 |
+
transforms.Normalize(mean=[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]),
|
| 68 |
+
])
|
| 69 |
+
```
|
| 70 |
+
|
| 71 |
+
### Performance Metrics
|
| 72 |
+
- Metrics will be updated after evaluation
|
| 73 |
+
|
| 74 |
+
|
| 75 |
+
|
| 76 |
+
|
| 77 |
+
## Usage
|
| 78 |
+
|
| 79 |
+
### Quick Start
|
| 80 |
+
```python
|
| 81 |
+
from transformers import EfficientNetForImageClassification, EfficientNetImageProcessor
|
| 82 |
+
import torch
|
| 83 |
+
from PIL import Image
|
| 84 |
+
import requests
|
| 85 |
+
|
| 86 |
+
# Load model and processor
|
| 87 |
+
model = EfficientNetForImageClassification.from_pretrained("huytranduck/efficientnet_b0_50x_dataset")
|
| 88 |
+
processor = EfficientNetImageProcessor.from_pretrained("huytranduck/efficientnet_b0_50x_dataset")
|
| 89 |
+
|
| 90 |
+
# Load image
|
| 91 |
+
url = "http://images.cocodataset.org/val2017/000000039769.jpg"
|
| 92 |
+
image = Image.open(requests.get(url, stream=True).raw)
|
| 93 |
+
|
| 94 |
+
# Preprocess image
|
| 95 |
+
inputs = processor(image, return_tensors="pt")
|
| 96 |
+
|
| 97 |
+
# Make prediction
|
| 98 |
+
with torch.no_grad():
|
| 99 |
+
outputs = model(**inputs)
|
| 100 |
+
predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
|
| 101 |
+
predicted_class_id = predictions.argmax().item()
|
| 102 |
+
confidence = predictions.max().item()
|
| 103 |
+
|
| 104 |
+
print(f"Predicted class: {predicted_class_id}")
|
| 105 |
+
print(f"Confidence: {confidence:.4f}")
|
| 106 |
+
```
|
| 107 |
+
|
| 108 |
+
### Batch Inference
|
| 109 |
+
```python
|
| 110 |
+
# For multiple images
|
| 111 |
+
images = [image1, image2, image3] # List of PIL Images
|
| 112 |
+
inputs = processor(images, return_tensors="pt")
|
| 113 |
+
|
| 114 |
+
with torch.no_grad():
|
| 115 |
+
outputs = model(**inputs)
|
| 116 |
+
predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
|
| 117 |
+
predicted_classes = predictions.argmax(dim=-1)
|
| 118 |
+
```
|
| 119 |
+
|
| 120 |
+
### GPU Inference
|
| 121 |
+
```python
|
| 122 |
+
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
| 123 |
+
model = model.to(device)
|
| 124 |
+
|
| 125 |
+
inputs = processor(image, return_tensors="pt")
|
| 126 |
+
inputs = {k: v.to(device) for k, v in inputs.items()}
|
| 127 |
+
|
| 128 |
+
with torch.no_grad():
|
| 129 |
+
outputs = model(**inputs)
|
| 130 |
+
predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
|
| 131 |
+
```
|
| 132 |
+
|
| 133 |
+
## Model Performance
|
| 134 |
+
|
| 135 |
+
The model was trained with extensive data augmentation and achieved strong performance on the validation set. The training process used:
|
| 136 |
+
|
| 137 |
+
- **Weighted F1-Score** for handling class imbalance
|
| 138 |
+
- **Best model saving** based on F1-Score
|
| 139 |
+
- **AdamW optimizer** with learning rate 0.0001
|
| 140 |
+
|
| 141 |
+
## Training Code
|
| 142 |
+
|
| 143 |
+
<details>
|
| 144 |
+
<summary>Click to expand training code</summary>
|
| 145 |
+
|
| 146 |
+
```python
|
| 147 |
+
import torch
|
| 148 |
+
from transformers import EfficientNetConfig, EfficientNetForImageClassification, EfficientNetImageProcessor
|
| 149 |
+
|
| 150 |
+
# Model setup
|
| 151 |
+
model_name = "google/efficientnet-b0"
|
| 152 |
+
config = EfficientNetConfig.from_pretrained(model_name)
|
| 153 |
+
config.num_labels = 100
|
| 154 |
+
model = EfficientNetForImageClassification(config)
|
| 155 |
+
processor = EfficientNetImageProcessor.from_pretrained(model_name)
|
| 156 |
+
|
| 157 |
+
# Training parameters
|
| 158 |
+
epochs = 2
|
| 159 |
+
batch_size = 64
|
| 160 |
+
learning_rate = 0.0001
|
| 161 |
+
|
| 162 |
+
# Training loop with F1-score monitoring
|
| 163 |
+
optimizer = torch.optim.AdamW(model.parameters(), lr=learning_rate)
|
| 164 |
+
criterion = torch.nn.CrossEntropyLoss()
|
| 165 |
+
```
|
| 166 |
+
</details>
|
| 167 |
+
|
| 168 |
+
## Citation
|
| 169 |
+
|
| 170 |
+
If you use this model, please cite:
|
| 171 |
+
|
| 172 |
+
```bibtex
|
| 173 |
+
@misc{huytranduck_efficientnet_b0_50x_dataset,
|
| 174 |
+
title={Custom EfficientNet-B0 for Image Classification},
|
| 175 |
+
author={Your Name},
|
| 176 |
+
year={2024},
|
| 177 |
+
publisher={Hugging Face},
|
| 178 |
+
url={https://huggingface.co/huytranduck/efficientnet_b0_50x_dataset}
|
| 179 |
+
}
|
| 180 |
+
```
|
| 181 |
+
|
| 182 |
+
## License
|
| 183 |
+
|
| 184 |
+
This model is released under the Apache 2.0 License.
|
config.json
ADDED
|
@@ -0,0 +1,293 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"EfficientNetForImageClassification"
|
| 4 |
+
],
|
| 5 |
+
"batch_norm_eps": 0.001,
|
| 6 |
+
"batch_norm_momentum": 0.99,
|
| 7 |
+
"depth_coefficient": 1.0,
|
| 8 |
+
"depth_divisor": 8,
|
| 9 |
+
"depthwise_padding": [],
|
| 10 |
+
"drop_connect_rate": 0.2,
|
| 11 |
+
"dropout_rate": 0.2,
|
| 12 |
+
"expand_ratios": [
|
| 13 |
+
1,
|
| 14 |
+
6,
|
| 15 |
+
6,
|
| 16 |
+
6,
|
| 17 |
+
6,
|
| 18 |
+
6,
|
| 19 |
+
6
|
| 20 |
+
],
|
| 21 |
+
"hidden_act": "swish",
|
| 22 |
+
"hidden_dim": 1280,
|
| 23 |
+
"id2label": {
|
| 24 |
+
"0": "LABEL_0",
|
| 25 |
+
"1": "LABEL_1",
|
| 26 |
+
"2": "LABEL_2",
|
| 27 |
+
"3": "LABEL_3",
|
| 28 |
+
"4": "LABEL_4",
|
| 29 |
+
"5": "LABEL_5",
|
| 30 |
+
"6": "LABEL_6",
|
| 31 |
+
"7": "LABEL_7",
|
| 32 |
+
"8": "LABEL_8",
|
| 33 |
+
"9": "LABEL_9",
|
| 34 |
+
"10": "LABEL_10",
|
| 35 |
+
"11": "LABEL_11",
|
| 36 |
+
"12": "LABEL_12",
|
| 37 |
+
"13": "LABEL_13",
|
| 38 |
+
"14": "LABEL_14",
|
| 39 |
+
"15": "LABEL_15",
|
| 40 |
+
"16": "LABEL_16",
|
| 41 |
+
"17": "LABEL_17",
|
| 42 |
+
"18": "LABEL_18",
|
| 43 |
+
"19": "LABEL_19",
|
| 44 |
+
"20": "LABEL_20",
|
| 45 |
+
"21": "LABEL_21",
|
| 46 |
+
"22": "LABEL_22",
|
| 47 |
+
"23": "LABEL_23",
|
| 48 |
+
"24": "LABEL_24",
|
| 49 |
+
"25": "LABEL_25",
|
| 50 |
+
"26": "LABEL_26",
|
| 51 |
+
"27": "LABEL_27",
|
| 52 |
+
"28": "LABEL_28",
|
| 53 |
+
"29": "LABEL_29",
|
| 54 |
+
"30": "LABEL_30",
|
| 55 |
+
"31": "LABEL_31",
|
| 56 |
+
"32": "LABEL_32",
|
| 57 |
+
"33": "LABEL_33",
|
| 58 |
+
"34": "LABEL_34",
|
| 59 |
+
"35": "LABEL_35",
|
| 60 |
+
"36": "LABEL_36",
|
| 61 |
+
"37": "LABEL_37",
|
| 62 |
+
"38": "LABEL_38",
|
| 63 |
+
"39": "LABEL_39",
|
| 64 |
+
"40": "LABEL_40",
|
| 65 |
+
"41": "LABEL_41",
|
| 66 |
+
"42": "LABEL_42",
|
| 67 |
+
"43": "LABEL_43",
|
| 68 |
+
"44": "LABEL_44",
|
| 69 |
+
"45": "LABEL_45",
|
| 70 |
+
"46": "LABEL_46",
|
| 71 |
+
"47": "LABEL_47",
|
| 72 |
+
"48": "LABEL_48",
|
| 73 |
+
"49": "LABEL_49",
|
| 74 |
+
"50": "LABEL_50",
|
| 75 |
+
"51": "LABEL_51",
|
| 76 |
+
"52": "LABEL_52",
|
| 77 |
+
"53": "LABEL_53",
|
| 78 |
+
"54": "LABEL_54",
|
| 79 |
+
"55": "LABEL_55",
|
| 80 |
+
"56": "LABEL_56",
|
| 81 |
+
"57": "LABEL_57",
|
| 82 |
+
"58": "LABEL_58",
|
| 83 |
+
"59": "LABEL_59",
|
| 84 |
+
"60": "LABEL_60",
|
| 85 |
+
"61": "LABEL_61",
|
| 86 |
+
"62": "LABEL_62",
|
| 87 |
+
"63": "LABEL_63",
|
| 88 |
+
"64": "LABEL_64",
|
| 89 |
+
"65": "LABEL_65",
|
| 90 |
+
"66": "LABEL_66",
|
| 91 |
+
"67": "LABEL_67",
|
| 92 |
+
"68": "LABEL_68",
|
| 93 |
+
"69": "LABEL_69",
|
| 94 |
+
"70": "LABEL_70",
|
| 95 |
+
"71": "LABEL_71",
|
| 96 |
+
"72": "LABEL_72",
|
| 97 |
+
"73": "LABEL_73",
|
| 98 |
+
"74": "LABEL_74",
|
| 99 |
+
"75": "LABEL_75",
|
| 100 |
+
"76": "LABEL_76",
|
| 101 |
+
"77": "LABEL_77",
|
| 102 |
+
"78": "LABEL_78",
|
| 103 |
+
"79": "LABEL_79",
|
| 104 |
+
"80": "LABEL_80",
|
| 105 |
+
"81": "LABEL_81",
|
| 106 |
+
"82": "LABEL_82",
|
| 107 |
+
"83": "LABEL_83",
|
| 108 |
+
"84": "LABEL_84",
|
| 109 |
+
"85": "LABEL_85",
|
| 110 |
+
"86": "LABEL_86",
|
| 111 |
+
"87": "LABEL_87",
|
| 112 |
+
"88": "LABEL_88",
|
| 113 |
+
"89": "LABEL_89",
|
| 114 |
+
"90": "LABEL_90",
|
| 115 |
+
"91": "LABEL_91",
|
| 116 |
+
"92": "LABEL_92",
|
| 117 |
+
"93": "LABEL_93",
|
| 118 |
+
"94": "LABEL_94",
|
| 119 |
+
"95": "LABEL_95",
|
| 120 |
+
"96": "LABEL_96",
|
| 121 |
+
"97": "LABEL_97",
|
| 122 |
+
"98": "LABEL_98",
|
| 123 |
+
"99": "LABEL_99"
|
| 124 |
+
},
|
| 125 |
+
"image_size": 224,
|
| 126 |
+
"in_channels": [
|
| 127 |
+
32,
|
| 128 |
+
16,
|
| 129 |
+
24,
|
| 130 |
+
40,
|
| 131 |
+
80,
|
| 132 |
+
112,
|
| 133 |
+
192
|
| 134 |
+
],
|
| 135 |
+
"initializer_range": 0.02,
|
| 136 |
+
"kernel_sizes": [
|
| 137 |
+
3,
|
| 138 |
+
3,
|
| 139 |
+
5,
|
| 140 |
+
3,
|
| 141 |
+
5,
|
| 142 |
+
5,
|
| 143 |
+
3
|
| 144 |
+
],
|
| 145 |
+
"label2id": {
|
| 146 |
+
"LABEL_0": 0,
|
| 147 |
+
"LABEL_1": 1,
|
| 148 |
+
"LABEL_10": 10,
|
| 149 |
+
"LABEL_11": 11,
|
| 150 |
+
"LABEL_12": 12,
|
| 151 |
+
"LABEL_13": 13,
|
| 152 |
+
"LABEL_14": 14,
|
| 153 |
+
"LABEL_15": 15,
|
| 154 |
+
"LABEL_16": 16,
|
| 155 |
+
"LABEL_17": 17,
|
| 156 |
+
"LABEL_18": 18,
|
| 157 |
+
"LABEL_19": 19,
|
| 158 |
+
"LABEL_2": 2,
|
| 159 |
+
"LABEL_20": 20,
|
| 160 |
+
"LABEL_21": 21,
|
| 161 |
+
"LABEL_22": 22,
|
| 162 |
+
"LABEL_23": 23,
|
| 163 |
+
"LABEL_24": 24,
|
| 164 |
+
"LABEL_25": 25,
|
| 165 |
+
"LABEL_26": 26,
|
| 166 |
+
"LABEL_27": 27,
|
| 167 |
+
"LABEL_28": 28,
|
| 168 |
+
"LABEL_29": 29,
|
| 169 |
+
"LABEL_3": 3,
|
| 170 |
+
"LABEL_30": 30,
|
| 171 |
+
"LABEL_31": 31,
|
| 172 |
+
"LABEL_32": 32,
|
| 173 |
+
"LABEL_33": 33,
|
| 174 |
+
"LABEL_34": 34,
|
| 175 |
+
"LABEL_35": 35,
|
| 176 |
+
"LABEL_36": 36,
|
| 177 |
+
"LABEL_37": 37,
|
| 178 |
+
"LABEL_38": 38,
|
| 179 |
+
"LABEL_39": 39,
|
| 180 |
+
"LABEL_4": 4,
|
| 181 |
+
"LABEL_40": 40,
|
| 182 |
+
"LABEL_41": 41,
|
| 183 |
+
"LABEL_42": 42,
|
| 184 |
+
"LABEL_43": 43,
|
| 185 |
+
"LABEL_44": 44,
|
| 186 |
+
"LABEL_45": 45,
|
| 187 |
+
"LABEL_46": 46,
|
| 188 |
+
"LABEL_47": 47,
|
| 189 |
+
"LABEL_48": 48,
|
| 190 |
+
"LABEL_49": 49,
|
| 191 |
+
"LABEL_5": 5,
|
| 192 |
+
"LABEL_50": 50,
|
| 193 |
+
"LABEL_51": 51,
|
| 194 |
+
"LABEL_52": 52,
|
| 195 |
+
"LABEL_53": 53,
|
| 196 |
+
"LABEL_54": 54,
|
| 197 |
+
"LABEL_55": 55,
|
| 198 |
+
"LABEL_56": 56,
|
| 199 |
+
"LABEL_57": 57,
|
| 200 |
+
"LABEL_58": 58,
|
| 201 |
+
"LABEL_59": 59,
|
| 202 |
+
"LABEL_6": 6,
|
| 203 |
+
"LABEL_60": 60,
|
| 204 |
+
"LABEL_61": 61,
|
| 205 |
+
"LABEL_62": 62,
|
| 206 |
+
"LABEL_63": 63,
|
| 207 |
+
"LABEL_64": 64,
|
| 208 |
+
"LABEL_65": 65,
|
| 209 |
+
"LABEL_66": 66,
|
| 210 |
+
"LABEL_67": 67,
|
| 211 |
+
"LABEL_68": 68,
|
| 212 |
+
"LABEL_69": 69,
|
| 213 |
+
"LABEL_7": 7,
|
| 214 |
+
"LABEL_70": 70,
|
| 215 |
+
"LABEL_71": 71,
|
| 216 |
+
"LABEL_72": 72,
|
| 217 |
+
"LABEL_73": 73,
|
| 218 |
+
"LABEL_74": 74,
|
| 219 |
+
"LABEL_75": 75,
|
| 220 |
+
"LABEL_76": 76,
|
| 221 |
+
"LABEL_77": 77,
|
| 222 |
+
"LABEL_78": 78,
|
| 223 |
+
"LABEL_79": 79,
|
| 224 |
+
"LABEL_8": 8,
|
| 225 |
+
"LABEL_80": 80,
|
| 226 |
+
"LABEL_81": 81,
|
| 227 |
+
"LABEL_82": 82,
|
| 228 |
+
"LABEL_83": 83,
|
| 229 |
+
"LABEL_84": 84,
|
| 230 |
+
"LABEL_85": 85,
|
| 231 |
+
"LABEL_86": 86,
|
| 232 |
+
"LABEL_87": 87,
|
| 233 |
+
"LABEL_88": 88,
|
| 234 |
+
"LABEL_89": 89,
|
| 235 |
+
"LABEL_9": 9,
|
| 236 |
+
"LABEL_90": 90,
|
| 237 |
+
"LABEL_91": 91,
|
| 238 |
+
"LABEL_92": 92,
|
| 239 |
+
"LABEL_93": 93,
|
| 240 |
+
"LABEL_94": 94,
|
| 241 |
+
"LABEL_95": 95,
|
| 242 |
+
"LABEL_96": 96,
|
| 243 |
+
"LABEL_97": 97,
|
| 244 |
+
"LABEL_98": 98,
|
| 245 |
+
"LABEL_99": 99
|
| 246 |
+
},
|
| 247 |
+
"model_type": "efficientnet",
|
| 248 |
+
"num_block_repeats": [
|
| 249 |
+
1,
|
| 250 |
+
2,
|
| 251 |
+
2,
|
| 252 |
+
3,
|
| 253 |
+
3,
|
| 254 |
+
4,
|
| 255 |
+
1
|
| 256 |
+
],
|
| 257 |
+
"num_channels": 3,
|
| 258 |
+
"num_hidden_layers": 64,
|
| 259 |
+
"out_channels": [
|
| 260 |
+
16,
|
| 261 |
+
24,
|
| 262 |
+
40,
|
| 263 |
+
80,
|
| 264 |
+
112,
|
| 265 |
+
192,
|
| 266 |
+
320
|
| 267 |
+
],
|
| 268 |
+
"out_features": null,
|
| 269 |
+
"pooling_type": "mean",
|
| 270 |
+
"squeeze_expansion_ratio": 0.25,
|
| 271 |
+
"stage_names": [
|
| 272 |
+
"stem",
|
| 273 |
+
"stage1",
|
| 274 |
+
"stage2",
|
| 275 |
+
"stage3",
|
| 276 |
+
"stage4",
|
| 277 |
+
"stage5",
|
| 278 |
+
"stage6",
|
| 279 |
+
"stage7"
|
| 280 |
+
],
|
| 281 |
+
"strides": [
|
| 282 |
+
1,
|
| 283 |
+
2,
|
| 284 |
+
2,
|
| 285 |
+
2,
|
| 286 |
+
1,
|
| 287 |
+
2,
|
| 288 |
+
1
|
| 289 |
+
],
|
| 290 |
+
"torch_dtype": "float32",
|
| 291 |
+
"transformers_version": "4.52.4",
|
| 292 |
+
"width_coefficient": 1.0
|
| 293 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0391d4df5ef1686e6e5a765c37e5f23e375ec0829f4fa7c8d2cdc83970fda148
|
| 3 |
+
size 16757384
|
model_info.json
ADDED
|
@@ -0,0 +1,119 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"model_type": "efficientnet",
|
| 3 |
+
"base_model": "google/efficientnet-b0",
|
| 4 |
+
"num_classes": 100,
|
| 5 |
+
"class_names": [
|
| 6 |
+
"Acacia melanoxylon",
|
| 7 |
+
"Acer saccharinum",
|
| 8 |
+
"Afzelia africana",
|
| 9 |
+
"Afzelia pachyloba",
|
| 10 |
+
"Afzelia quanzensis",
|
| 11 |
+
"Albizia lucida (Albizia lucidior)",
|
| 12 |
+
"Allophylus cobbe (Pometia pinnata)",
|
| 13 |
+
"Anisoptera costata (Anisoptera Robusta)",
|
| 14 |
+
"Apuleia\u00a0leiocarpa",
|
| 15 |
+
"Artocarpus calophyllus (Artocarpus asperulus)",
|
| 16 |
+
"Artocarpus heterophyllus",
|
| 17 |
+
"Autranella congolensis",
|
| 18 |
+
"Berlinia bracteosa",
|
| 19 |
+
"Betula pendula",
|
| 20 |
+
"Bobgunnia fistuloides (Swartzia fistuloides)",
|
| 21 |
+
"Brachystegia sp",
|
| 22 |
+
"Burckella obovata",
|
| 23 |
+
"Burretiodendron tonkinense",
|
| 24 |
+
"Callitris columellaris",
|
| 25 |
+
"Calocedrus sp",
|
| 26 |
+
"Canarium album",
|
| 27 |
+
"Chrysophyllum sp",
|
| 28 |
+
"Cinnamomum camphora",
|
| 29 |
+
"Clarisia racemosa",
|
| 30 |
+
"Colophospermum mopane",
|
| 31 |
+
"Cunninghamia lanceolata",
|
| 32 |
+
"Cupressus funebris (Cupressus pendula)",
|
| 33 |
+
"Cylicodiscus gabunensis",
|
| 34 |
+
"Dalbergia cochinchinensis",
|
| 35 |
+
"Dalbergia oliveri",
|
| 36 |
+
"Detarium macrocarpum",
|
| 37 |
+
"Dialium bipindense",
|
| 38 |
+
"Didelotia africana",
|
| 39 |
+
"Diospyros mun",
|
| 40 |
+
"Diospyros salletii",
|
| 41 |
+
"Distemonanthus benthamianus",
|
| 42 |
+
"Engelhardia chrysolepis (Engelhardia roxburghiana)",
|
| 43 |
+
"Entandrophragma cylindricum",
|
| 44 |
+
"Entandrophragma utile",
|
| 45 |
+
"Erythrophleum fordii\u00a0",
|
| 46 |
+
"Erythrophleum ivorense",
|
| 47 |
+
"Eucalyptus cladocalyx",
|
| 48 |
+
"Eucalyptus grandis",
|
| 49 |
+
"Eucalyptus microcorys",
|
| 50 |
+
"Eucalyptus saligna",
|
| 51 |
+
"Fokienia hodginsii",
|
| 52 |
+
"Fraxinus excelsior",
|
| 53 |
+
"Gilbertiodendron dewevrei",
|
| 54 |
+
"Guarea cedrata",
|
| 55 |
+
"Guibourtia coleosperma",
|
| 56 |
+
"Heritiera littoralis",
|
| 57 |
+
"Hevea brasiliensis",
|
| 58 |
+
"Homalium caryophyllaceum",
|
| 59 |
+
"Homalium foetidum",
|
| 60 |
+
"Hopea iriana",
|
| 61 |
+
"Hopea pierrei",
|
| 62 |
+
"Hymenaea courbaril",
|
| 63 |
+
"Hymenolobium heterocarpum",
|
| 64 |
+
"Juglans regia",
|
| 65 |
+
"Khaya senegalensis",
|
| 66 |
+
"Klainedoxa gabonensis",
|
| 67 |
+
"Lithocarpus ducampii",
|
| 68 |
+
"Lophira alata",
|
| 69 |
+
"Magnolia hypolampra",
|
| 70 |
+
"Martiodendron parviflorum",
|
| 71 |
+
"Milicia excelsa",
|
| 72 |
+
"Milicia regia",
|
| 73 |
+
"Millettia laurentii",
|
| 74 |
+
"Monopetalanthus letestui (Bikinia letestui)",
|
| 75 |
+
"Myracrodruon urundeuva",
|
| 76 |
+
"Myroxylon balsamum",
|
| 77 |
+
"Myroxylon balsamum_v2",
|
| 78 |
+
"Myroxylon peruiferum",
|
| 79 |
+
"Nauclea diderrichii",
|
| 80 |
+
"Pachyelasma tessmannii",
|
| 81 |
+
"Palaquium waburgianum",
|
| 82 |
+
"Pericopsis elata",
|
| 83 |
+
"Pinus sp",
|
| 84 |
+
"Piptadeniastrum africanum",
|
| 85 |
+
"Populus sp",
|
| 86 |
+
"Prunus serotina",
|
| 87 |
+
"Pterocarpus macrocarpus",
|
| 88 |
+
"Pterocarpus soyauxii",
|
| 89 |
+
"Pterocarpus sp",
|
| 90 |
+
"Qualea paraensis",
|
| 91 |
+
"Quercus petraea",
|
| 92 |
+
"Quercus robur",
|
| 93 |
+
"Quercus rubra",
|
| 94 |
+
"Samanea saman",
|
| 95 |
+
"Shorea hypochra (Anthoshorea hypochra)",
|
| 96 |
+
"Shorea roxburghii (Anthoshorea roxburghii)",
|
| 97 |
+
"Sindora cochinchinensis",
|
| 98 |
+
"Staudtia stipitata",
|
| 99 |
+
"Syzygium hemisphericum (Syzygium chanlos)",
|
| 100 |
+
"Tarrietia cochinchinensis (Heritiera cochinchinesis)",
|
| 101 |
+
"Tectona grandis",
|
| 102 |
+
"Terminalia superba",
|
| 103 |
+
"Tetraberlinia bifoliolata",
|
| 104 |
+
"Toona sureni",
|
| 105 |
+
"Xylia xylocarpa"
|
| 106 |
+
],
|
| 107 |
+
"training_config": {
|
| 108 |
+
"epochs": 2,
|
| 109 |
+
"batch_size": 64,
|
| 110 |
+
"learning_rate": 0.0001,
|
| 111 |
+
"optimizer": "AdamW",
|
| 112 |
+
"loss_function": "CrossEntropyLoss",
|
| 113 |
+
"image_size": 224,
|
| 114 |
+
"data_augmentation": true
|
| 115 |
+
},
|
| 116 |
+
"metrics": {},
|
| 117 |
+
"framework": "transformers",
|
| 118 |
+
"torch_dtype": "float32"
|
| 119 |
+
}
|
preprocessor_config.json
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"crop_size": {
|
| 3 |
+
"height": 289,
|
| 4 |
+
"width": 289
|
| 5 |
+
},
|
| 6 |
+
"do_center_crop": false,
|
| 7 |
+
"do_normalize": true,
|
| 8 |
+
"do_rescale": true,
|
| 9 |
+
"do_resize": true,
|
| 10 |
+
"image_mean": [
|
| 11 |
+
0.485,
|
| 12 |
+
0.456,
|
| 13 |
+
0.406
|
| 14 |
+
],
|
| 15 |
+
"image_processor_type": "EfficientNetImageProcessor",
|
| 16 |
+
"image_std": [
|
| 17 |
+
0.47853944,
|
| 18 |
+
0.4732864,
|
| 19 |
+
0.47434163
|
| 20 |
+
],
|
| 21 |
+
"include_top": true,
|
| 22 |
+
"resample": 0,
|
| 23 |
+
"rescale_factor": 0.00392156862745098,
|
| 24 |
+
"rescale_offset": false,
|
| 25 |
+
"size": {
|
| 26 |
+
"height": 224,
|
| 27 |
+
"width": 224
|
| 28 |
+
}
|
| 29 |
+
}
|