Downloads · 30 days
9
16% of all-time downloads
keras/vgg_11_imagenet
vgg_11_imagenet is a image classification model from keras. Use it when you need a label for an image. It is set up for keras-hub. The card lists the license as apache-2.0.
The VGG model is a type of convolutional neural network (CNN) architecture designed for image recognition and classification tasks. Developed by the Visual Geometry Group at the University of Oxford, it was introduced…
Downloads · 30 days
9
16% of all-time downloads
All-time downloads
56
Public
Repo size
1.1 GB
Likes
0
Public
Click a slice to open those files.
.h5568 MB · 100%
From the Hugging Face model README
The VGG model is a type of convolutional neural network (CNN) architecture designed for image recognition and classification tasks. Developed by the Visual Geometry Group at the University of Oxford, it was introduced in the paper titled "Very Deep Convolutional Networks for Large-Scale Image Recognition" by Karen Simonyan and Andrew Zisserman in 2014. This model is supported in both KerasCV and KerasHub. KerasCV will no longer be actively developed, so please try to use KerasHub.
Keras and KerasHub can be installed with:
pip install -U -q keras-Hub
pip install -U -q keras>=3
Jax, TensorFlow, and Torch come preinstalled in Kaggle Notebooks. For instructions on installing them in another environment see the Keras Getting Started page.
The following model checkpoints are provided by the Keras team. Weights have been ported from https://huggingface.co/timm.
| Preset Name | Parameters | Description |
|---|---|---|
| vgg_11_imagenet | 9.22M | 11-layer VGG model pre-trained on the ImageNet 1k dataset at a 224x224 resolution. |
| vgg_13_imagenet | 9.40M | 13-layer VGG model pre-trained on the ImageNet 1k dataset at a 224x224 resolution. |
| vgg_16_imagenet | 14.71M | 16-layer VGG model pre-trained on the ImageNet 1k dataset at a 224x224 resolution. |
| vgg_19_imagenet | 20.02M | 19-layer VGG model pre-trained on the ImageNet 1k dataset at a 224x224 resolution. |
input_data = np.ones(shape=(2, 224, 224, 3))
# Pretrained backbone
model = keras_hub.models.VGGBackbone.from_preset("vgg_11_imagenet")
model(input_data)
# Randomly initialized backbone with a custom config
model = keras_hub.models.VGGBackbone(
stackwise_num_repeats=[2, 3, 3, 2],
stackwise_num_filters=[64, 128, 256, 512],
)
model(input_data)
# Use VGG for image classification task
model = keras_hub.models.ImageClassifier.from_preset("vgg_11_imagenet")
# User Timm presets directly from HuggingFace
model = keras_hub.models.ImageClassifier.from_preset('hf://timm/vgg11.tv_in1k')
input_data = np.ones(shape=(2, 224, 224, 3))
# Pretrained backbone
model = keras_hub.models.VGGBackbone.from_preset("hf://keras/vgg_11_imagenet")
model(input_data)
# Randomly initialized backbone with a custom config
model = keras_hub.models.VGGBackbone(
stackwise_num_repeats=[2, 3, 3, 2],
stackwise_num_filters=[64, 128, 256, 512],
)
model(input_data)
# Use VGG for image classification task
model = keras_hub.models.ImageClassifier.from_preset("hf://keras/vgg_11_imagenet")
# User Timm presets directly from HuggingFace
model = keras_hub.models.ImageClassifier.from_preset('hf://timm/vgg11.tv_in1k')