Package examples.transferlearning.modelzoo.vgg19

Functions

main
Link copied to clipboard
fun main()
fun main()
fun main()
This examples demonstrates the inference concept on VGG'19 model:
  • Weights are loaded from .h5 file, configuration is loaded from .json file.

  • Model predicts on a few images located in resources.

  • Special preprocessing (used in VGG'19 during training on ImageNet dataset) is applied to images before prediction.

  • No additional training.

  • No new layers are added.

vgg19additionalTraining
Link copied to clipboard
fun vgg19additionalTraining()
This examples demonstrates the transfer learning concept on VGG'19 model:
  • Model configuration, model weights and labels are obtained from ModelZoo.

  • Weights are loaded from .h5 file, configuration is loaded from .json file.

  • All layers, excluding the last Dense, are added to the new Neural Network, its weights are frozen.

  • New Dense layers are added and initialized via defined initializers.

  • Model is re-trained on dogsCatsSmallDatasetPath dataset.

We use the Preprocessing DSL to describe the dataset generation pipeline.
vgg19prediction
Link copied to clipboard
fun vgg19prediction()
This examples demonstrates the inference concept on VGG'19 model:
  • Model configuration, model weights and labels are obtained from ModelZoo.

  • Weights are loaded from .h5 file, configuration is loaded from .json file.

  • Model predicts on a few images located in resources.

  • Special preprocessing (used in VGG'19 during training on ImageNet dataset) is applied to images before prediction.

  • No additional training.

  • No new layers are added.