https://github.com/zfturbo/pretrained-vgg-neural-nets-in-tensorflow
Set of VGG neural net models for TensorFlow. Weights converted from Pytorch.
https://github.com/zfturbo/pretrained-vgg-neural-nets-in-tensorflow
batch-normalization pretrained-models tensorflow vgg16 vgg19
Last synced: 7 months ago
JSON representation
Set of VGG neural net models for TensorFlow. Weights converted from Pytorch.
- Host: GitHub
- URL: https://github.com/zfturbo/pretrained-vgg-neural-nets-in-tensorflow
- Owner: ZFTurbo
- Created: 2022-02-20T17:36:12.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2022-02-21T13:04:42.000Z (over 3 years ago)
- Last Synced: 2025-01-23T04:42:28.575Z (9 months ago)
- Topics: batch-normalization, pretrained-models, tensorflow, vgg16, vgg19
- Language: Python
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Pretrained VGG neural nets in TensorFlow
Set of VGG neural net models for TensorFlow. Weights converted from [timm](https://github.com/rwightman/pytorch-image-models/blob/master/timm/models/vgg.py) module (Pytorch).## Introduction
Sometimes pretrained nets like VGG useful for segmentation problems. Unfortunately there is only pretrained VGG16 and VGG19 without batchnorm available for tensorflow.
I made converter from Pytorch to VGG which allows to use all family of VGG models with imagenet weights.## Available models
`vgg11`, `vgg11_bn`, `vgg13`, `vgg13_bn`, `vgg16`, `vgg16_bn`, `vgg19`, `vgg19_bn`## Notes
* Converted only feature extraction part (no classification part available)
* Models tested against PyTorch version to give the same result (max diff < 1e-05)
* Code for conversion of model weights available here: [convert_model_weights.py](convert_model_weights.py)## Usage
```python
from vgg_tensorflow import vgg11_bnmodel = vgg11_bn(inp_size=(224, 224, 3), pretrained=True)
```