SoulPerforms commited on
Commit
7fcafbb
·
verified ·
1 Parent(s): ab191a0

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +13 -1
README.md CHANGED
@@ -10,4 +10,16 @@ Butterfly image classification model that use pre-trained cnn model resnet18 and
10
  The model used the best checkpoint with 90% test accuracy. The model constructed on Pytorch environment.
11
 
12
  training and testing result:
13
- Epoch: 28 Train Loss: 0.17 Train Accuracy: 0.96 Test Accuracy: 0.90
 
 
 
 
 
 
 
 
 
 
 
 
 
10
  The model used the best checkpoint with 90% test accuracy. The model constructed on Pytorch environment.
11
 
12
  training and testing result:
13
+
14
+ Epoch: 28 Train Loss: 0.17 Train Accuracy: 0.96 Test Accuracy: 0.90
15
+
16
+ to use this model you have to:
17
+
18
+ 1. download the model
19
+ 2. # load pretrained model resnet18
20
+ 3. model = models.resnet18(pretrained=True)
21
+ 4. # load checkpoint from your local
22
+ 5. checkpoint = torch.load('butterfly_resnet_checkpoint.model')
23
+ 7. model_for_predict.load_state_dict(checkpoint)
24
+ 8. # predict the images
25
+ 9. model_for_predict.eval())