Incorrect parameter count when loading some models after exporting
- Dominant language
- Python
- Stars
- 1.1k
- Forks
- 237
- PR merge metrics
- No merged PRs in 30d
Description
Parameter counts are different for some models when you import the same model from `prototxt` (Caffe) and `json` (Keras). The count for prototxt is wrong.
**Steps to reproduce:**
- Export one of the following models to Keras and Caffe from the model zoo. Note the parameter count:
- Inception V3
- Inception V4
- Yolo
- ResNet 101
- Import the models back to Fabrik via Keras and Caffe import. Note that the parameter count is different for the Keras method and the Caffe method. The parameter count for the Caffe method would not match the Keras method.
**Parameter Counts:**
| Name | Model Zoo | Keras Import | Caffe Import |
|:------------: |:-----------: |:------------: |:--------------: |
| Inception V3 | 23,851,784 | 23,851,784 | 30,013,000 |
| Inception V4 | 42,712,937 | 42,712,937 | 47,357,129 |
| Yolo | 271,703,550 | 217,177,598 | 3,354,516,990 |
| ResNet 101 | 44,654,504 | 44,654,504 | 23,490,158,504 |
**Notes:**
1. I have not tested for all models, so errors may exist in some others as well.
2. Some models like VGG16 have **no errors**. As in, parameter counts are equal for Model zoo, Caffe and Keras.
3. Parameter count in Keras mostly matches the model zoo values, except in Yolo (for the ones I have tested).
4. Some models have very high error in parameter count in Caffe.
Contributor guide
Assessment
This issue has not been assessed yet.