当前位置:网站首页>Deep learning ----- different methods to realize vgg16

Deep learning ----- different methods to realize vgg16

2022-06-23 08:06:00 Xiaofeilong programmer

This blog is through tensorflow Realization vgg-16 Model , about vgg-16 There are different ways to write models , Include ,sequence Model 、 Class encapsulation 、 Custom function , This blog mainly introduces these three writing methods , The code and diagram are as follows :

 Insert picture description here
The size of this picture is 224x224x3 Picture size of the channel , This code is slightly modified , use 32x32x3 Take the picture of the channel as an example , It is trained under the condition that the convolution kernel and the number of channels are constant vgg-16 Model .

1. tensofflow adopt sequence Realization vgg-16

from tensorflow.keras.datasets import cifar10
import tensorflow as tf
from tensorflow.keras import models,Sequential
from tensorflow.
原网站

版权声明
本文为[Xiaofeilong programmer]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/174/202206230716523647.html