基于keras框架的Vgg深度学习神经网络衣服多标签分类识别系统

第一步:准备数据

6种衣服组合数据:'black_jeans', 'blue_dress', 'blue_jeans', 'blue_shirt', 'red_dress', 'red_shirt',总共有2167张图片,每个文件夹单独放一种动物

第二步:搭建模型

本文选择vgg,其网络结构如下:

参考代码如下:

python 复制代码
class SmallerVGGNet:
	@staticmethod
	def build(width, height, depth, classes, finalAct="softmax"):
		# initialize the model along with the input shape to be
		# "channels last" and the channels dimension itself
		model = Sequential()
		inputShape = (height, width, depth)
		chanDim = -1

		# if we are using "channels first", update the input shape
		# and channels dimension
		if K.image_data_format() == "channels_first":
			inputShape = (depth, height, width)
			chanDim = 1

		# CONV => RELU => POOL
		model.add(Conv2D(32, (3, 3), padding="same",
			input_shape=inputShape))
		model.add(Activation("relu"))
		model.add(BatchNormalization(axis=chanDim))
		model.add(MaxPooling2D(pool_size=(3, 3)))
		model.add(Dropout(0.25))

		# (CONV => RELU) * 2 => POOL
		model.add(Conv2D(64, (3, 3), padding="same"))
		model.add(Activation("relu"))
		model.add(BatchNormalization(axis=chanDim))
		model.add(Conv2D(64, (3, 3), padding="same"))
		model.add(Activation("relu"))
		model.add(BatchNormalization(axis=chanDim))
		model.add(MaxPooling2D(pool_size=(2, 2)))
		model.add(Dropout(0.25))

		# (CONV => RELU) * 2 => POOL
		model.add(Conv2D(128, (3, 3), padding="same"))
		model.add(Activation("relu"))
		model.add(BatchNormalization(axis=chanDim))
		model.add(Conv2D(128, (3, 3), padding="same"))
		model.add(Activation("relu"))
		model.add(BatchNormalization(axis=chanDim))
		model.add(MaxPooling2D(pool_size=(2, 2)))
		model.add(Dropout(0.25))

		# first (and only) set of FC => RELU layers
		model.add(Flatten())
		model.add(Dense(1024))
		model.add(Activation("relu"))
		model.add(BatchNormalization())
		model.add(Dropout(0.5))

		# softmax classifier
		model.add(Dense(classes))
		model.add(Activation(finalAct))

		# return the constructed network architecture
		return model

第三步:统计正确率

第四步:搭建GUI界面

第五步:整个工程的内容

有训练代码和训练好的模型以及训练过程,提供数据,提供GUI界面代码

项目完整文件下载请见演示与介绍视频的简介处给出:➷➷➷

https://www.bilibili.com/video/BV1pJBrYdEvS/

相关推荐
逄逄不是胖胖15 分钟前
《动手学深度学习》-56门控循环单元GRU
人工智能·深度学习·gru
轻览月15 分钟前
【DL】循环神经网络
人工智能·rnn·深度学习
轻览月38 分钟前
【DL】复杂卷积神经网络Ⅱ
人工智能·神经网络·cnn
赵药师1 小时前
YOLO训练水面漂浮垃圾数据集FLOW_IMG数据集
人工智能·深度学习·yolo
roman_日积跬步-终至千里1 小时前
【计算机视觉-作业1】图像分类:两层神经网络进一步提高分类精度
神经网络·计算机视觉·分类
gsgbgxp1 小时前
通过tailscale配置ssh远程实现wsl系统VSCode编程
vscode·深度学习·ubuntu·ssh
LaughingZhu2 小时前
Product Hunt 每日热榜 | 2026-01-28
数据库·经验分享·神经网络·搜索引擎·chatgpt
爱吃鱼的两包盐2 小时前
轻量化网络简介
人工智能·深度学习
HansenPole8252 小时前
深度学习基础知识
人工智能·深度学习
机器学习之心2 小时前
TCN-Transformer-LSTM组合模型回归+SHAP分析+新数据预测+多输出!深度学习可解释分析MATLAB代码
深度学习·lstm·transformer·shap分析·tcn-transformer