File size: 715 Bytes
95e86de 8153008 95e86de |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# EfficientNet Model
## Model Class
```python
model = efficientnet_b0(weights='IMAGENET1K_V1')
in_features = model.classifier[1].in_features
model.classifier[1] = nn.Linear(in_features, 2)
device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
model.to(device)
criterion = nn.MSELoss()
optimizer = optim.Adam(model.parameters(), lr=1e-4)
```
## How to Run
In the notebook Run_EfficientNet.ipynb, replace the line:
```python
dataset_test = load_dataset("gydou/released_img")
```
with the proper location of the testing dataset.
## Training Dataset Statistics
```python
lat_std = 0.0006914493505038013
lon_std = 0.0006539239061573955
lat_mean = 39.9517411499467
lon_mean = -75.19143213125122
``` |