![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
深度学习
敲代码的洋葱头
v:Yww02240101
展开
-
生成对抗网络GAN&CycleGAN
GAN简介生成对抗网络GAN主要由两部分组成:生成网络和判别网络。每个网络都可以是任何神经网络,比如普通的人工神经网络(artificial neural network,ANN)、卷积神经网络(convolutional neural network,CNN)、循环神经网络(recurrent neural network,RNN)或者长短期记忆(long short term memory,LSTM)网络。判别网络则需要一些全连接层,并且以分类器收尾。生成对抗网络的基本结构图如图所示,对于生成对抗网络原创 2021-06-09 02:36:13 · 3353 阅读 · 0 评论 -
Tensorflow构建单层/多层LSTM网络对MNIST数据集分类
#-*- codeing = utf-8 -*-#@Time :2021/5/20 19:40#@Author :Onion#@File :LSTMMNISTDemo.py#@Software :PyCharmimport tensorflow as tfimport osfrom tensorflow.examples.tutorials.mnist import input_dataos.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'# 获取MNIST数据原创 2021-05-20 21:39:03 · 794 阅读 · 0 评论 -
Tensorflow使用卷积神经网络操作对MNIST数据集进行预测
# 对MNIST数据集做卷积操作#-*- codeing = utf-8 -*-#@Time :2021/5/17 21:10#@Author :Onion#@File :ConMnistDemo.py#@Software :PyCharm# 对MNIST数据集做卷积操作import tensorflow as tf# 导入 MINST 数据集from tensorflow.examples.tutorials.mnist import input_datamnist = inpu原创 2021-05-17 23:47:11 · 392 阅读 · 0 评论 -
Tensorflow(1.15.0)卷积操作
#-*- codeing = utf-8 -*-#@Time :2021/5/17 10:33#@Author :Onion#@File :Convolution.py#@Software :PyCharm# 卷积神经网络Demo# 步骤# 1:定义输入变量# 2:定义卷积核变量# 3:定义卷积操作# 4:运行卷积操作import tensorflow as tftf.compat.v1.disable_eager_execution()tf.compat.v1.disable原创 2021-05-17 11:32:48 · 395 阅读 · 0 评论 -
Tensorflow(1.15.0)利用全连接网络将图片进行分类
#-*- codeing = utf-8 -*-#@Time :2021/5/16 19:02#@Author :Onion#@File :MnistByHidden_Layers.py#@Software :PyCharm# 利用全连接网络将图片进行分类import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_datatf.compat.v1.disable_eager_execution()原创 2021-05-16 23:26:30 · 464 阅读 · 0 评论 -
Tensorflow(1.15.0) 用线性单分逻辑回归分析肿瘤是良性还是恶性的
#-*- codeing = utf-8 -*-#@Time :2021/5/16 12:55#@Author :Onion#@File :Hospital_medical_records.py#@Software :PyCharmimport tensorflow as tfimport matplotlib.pyplot as pltimport numpy as npfrom sklearn.utils import shuffle# generate函数生成模拟数据tf.com原创 2021-05-16 17:45:09 · 189 阅读 · 0 评论 -
Tensorflow交叉熵实验
#-*- codeing = utf-8 -*-#@Time :2021/5/15 17:37#@Author :Onion#@File :CrossentropyDemo.py#@Software :PyCharm# 交叉熵实验import tensorflow as tfimport osos.environ['TF_CPP_MIN_LOG_LEVEL'] = '2'tf.compat.v1.disable_eager_execution()tf.compat.v1.reset_原创 2021-05-15 19:17:47 · 268 阅读 · 0 评论 -
Tensorflow(1.15.0) 识别图中模糊的手写数字
import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data# 获取MNIST数据# tf.disable_v2_behavior()mnist = input_data.read_data_sets("./MNIST_data", one_hot=True)tf.compat.v1.disable_eager_execution()tf.compat.v1.reset_default_grap原创 2021-05-15 11:59:43 · 437 阅读 · 1 评论 -
介绍一个快速确定神经网络模型中各层矩阵维度的方法
介绍一个快速确定神经网络模型中各层矩阵维度的方法深度学习在设计神经网络结构时需要指定每个隐藏层权重矩阵、偏置项的维度,有的时候容易搞混淆,导致运行时产生维度不对的错误,特别是对于隐藏层既深又宽的网络,更容易出错。下面以一个实例来说明怎么简单快速确定每一层各个矩阵的维度。假设需要拟合的函数为:y=f(x)=WX+b。损失函数:J(W,b)其中 X:输入特征,W:权重,b:偏置项正(前)向传播的计算公式a[0]=X,z[i]=w[i]*a[i-1]+b[i] ,a[i]=gi向量化表示A[0]=转载 2021-05-14 18:57:59 · 1398 阅读 · 0 评论