当前位置: 首页 > news >正文

网站界面设计和ios移动界面设计的区别北京百度竞价托管公司

网站界面设计和ios移动界面设计的区别,北京百度竞价托管公司,专门做网页的软件,电商网站建设与运营哦神经网络分类MNIST数据集 目录 神经网络分类MNIST数据集 1 一 、问题背景 1 1.1 神经网络简介 1 前馈神经网络模型: 1 1.2 MINST 数据说明 4 1.3 TensorFlow基本概念 5 二 、实现说明 5 2.1 构建神经网络模型 5 为输入输出分配占位符 5 搭建分层的神经网络 6 处理预…

神经网络分类MNIST数据集
目录
神经网络分类MNIST数据集 1
一 、问题背景 1
1.1 神经网络简介 1
前馈神经网络模型: 1
1.2 MINST 数据说明 4
1.3 TensorFlow基本概念 5
二 、实现说明 5
2.1 构建神经网络模型 5

为输入输出分配占位符 5
搭建分层的神经网络 6
处理预测结果 8
2.2 运行模型 9
三 、程序测试 9
3.1 运行说明 10
3.2 运行输出 10
四 、实验总结 11
2.2运行模型
首先调用 tf.global_variables_initializer() 初始化模型的参数,Session提供了Operation执行和Tensor求值的环境
其中:
模型训练分批次,每一批用100个样本训练神经网络模型,每一批都在上一批的基础上对网络模型 的参数进行调整。
mnist.train.next_batch :返回的是一组元组,元组的第一个元素图片像素阵列,第二个元素为 one-hot 格式的预测标签。
:在一个Session 里面计算张量的值,执行定义的所有必要的操作来产生这个计算这个张量需要的输入,然后通过这些输入产生这个张量。
feed_dict 作用是给使用 placeholder 创建出来的张量赋值,上述我们使用 定义
的占位符包括输入 x 、输出 y 和Dropout 层保留比例 keep_prob 。
三 、程序测试
3.1运行说明
因为实验代码所需要的TensorFlow版本为1.4.0,而现在TensorFlow的版本已经上升到了2.x,一些以前
提供的数据集、函数已经被删除,故直接运行会报错,报错内容为找不到 包。
我们可以使用一些Online运行环境,如 Google Colab (https://colab.research.google.com/)。使用云计算来运行我们的程序,将TensorFlow降级至1.4.0,而不修改本地 Python 的配置。
将TensorFlow降级的方法如下:在文件首行加入以下代码,然后再 import tensorflow 。
执行程序后会首先出现以下输出,本文转载自http://www.biyezuopin.vip/onews.asp?id=16721程序其他部分无需修改即可以正常运行,运行结果与预期一致。
3.2运行输出
运行输出如下:可以看到随着测试规模的增加,训练和测试的准确率也不断地在上升。
step 0, training accuracy 0.07, test accuracy 0.1024
step 50, training accuracy 0.91, test accuracy 0.8892
3 step 100, training accuracy 0.95, test accuracy 0.9325
4 step 150, training accuracy 0.94, test accuracy 0.9405
5 step 200, training accuracy 0.95, test accuracy 0.9468
6 step 250, training accuracy 0.96, test accuracy 0.9518
7 step 300, training accuracy 0.94, test accuracy 0.9543
8 step 350, training accuracy 0.97, test accuracy 0.9645
9 step 400, training accuracy 0.94, test accuracy 0.9588
10 step 450, training accuracy 0.95, test accuracy 0.9655
11
12 step 500, training accuracy 1, test accuracy 0.9608
test accuracy 0.9586
尝试修改部分参数,观察输出变化情况。
提高Adam下降算法的学习率:将学习率从 提高到 、
可以看到随着学习率的提高,测试正确率有明显的提高,但耗时随之上升。
step 0, training accuracy 0.08, test accuracy 0.1123
step 50, training accuracy 0.94, test accuracy 0.913
step 100, training accuracy 0.9, test accuracy 0.9283
4 step 150, training accuracy 0.95, test accuracy 0.9442
5 step 200, training accuracy 0.91, test accuracy 0.9413
6 step 250, training accuracy 0.94, test accuracy 0.954
7 step 300, training accuracy 0.93, test accuracy 0.9513
8 step 350, training accuracy 0.99, test accuracy 0.9598
9 step 400, training accuracy 0.97, test accuracy 0.9609
10 step 450, training accuracy 0.94, test accuracy 0.9584
11 step 500, training accuracy 0.96, test accuracy 0.9609
12 test accuracy 0.9651
当学习率提高到 时,过高的学习率容易跳过最优值,预测效果反而下降。
step 0, training accuracy 0.07, test accuracy 0.0877
step 50, training accuracy 0.89, test accuracy 0.9095
3 step 100, training accuracy 0.94, test accuracy 0.9233
4 step 150, training accuracy 0.91, test accuracy 0.9267
5 step 200, training accuracy 0.89, test accuracy 0.882
6 step 250, training accuracy 0.96, test accuracy 0.9383
7 step 300, training accuracy 0.92, test accuracy 0.9426
8 step 350, training accuracy 0.96, test accuracy 0.9384
9 step 400, training accuracy 0.95, test accuracy 0.9524
10 step 450, training accuracy 0.93, test accuracy 0.9504
11 step 500, training accuracy 0.95, test accuracy 0.9563
12 test accuracy 0.9469
增加/减少神经网络隐层
经测试,网络层数(3,4,5)对模型效果的影响不明显。而层次相同的神经网络中节点数目多的 表现出性能更优。
四 、实验总结
通过本次实验,我们深入理解了前馈神经网络模型,通过示例代码,研究MINST数据集训练神经网络的过程。第一次了解 TensorFlow,学习了TensorFlow的基本概念和用法,掌握了如何运用
TensorFlow来构建一个神经网络模型。
 

http://www.hrbkazy.com/news/24621.html

相关文章:

  • 营销网站建设上海专业的seo公司
  • 海南网站备案整站优化排名
  • 建大型门户网站百度热搜榜排名昨日
  • 动态网站制作教稿外贸建站推广哪家好
  • angular做门户网站爱站工具
  • 哈尔滨建设厅官方网站广东seo加盟
  • python 做网站 套件百度搜索引擎的使用方法
  • 2023石家庄疫情二次爆发灯塔seo
  • 做金融类网站宁德市医院
  • 政府网站建设经验材料范文seo技术是干什么的
  • 内容相同的 网站2022最新引流推广平台
  • 北京建设高端网站西安网络优化哪家好
  • wordpress添加+下载长沙网站优化推广
  • 建设局局长有实权吗贵阳关键词优化平台
  • 网站网页设计设计方案谷歌网页版入口在线
  • 电子商务网站建设课设网站互联网推广是什么
  • 做西班牙语网站日本比分预测最新分析
  • 聊城做网站的地方对网站进行seo优化
  • 淄博做网站多少钱灰色词快速排名方法
  • 最大的做网站公司营销网站建设门户
  • 中国建设银行个人卡信息网站网店推广的作用
  • 做网站卖广告位赚钱吗排名优化系统
  • 网络公司要求做网站工商网监厦门关键词优化seo
  • 怎么描述网站主页做的好网站优化推广平台
  • 外贸b2b平台有哪些平台安卓优化大师下载
  • 电子商务有限公司经营范围有哪些长春做网络优化的公司
  • 如何查看网站抓取频率淘宝店铺怎么推广
  • 做网站如何网站考虑优化汕头seo计费管理
  • 鲅鱼圈做网站网工资页多少钱一个月公司怎么做网站推广
  • 域名对网站排名的影响百度seo培训要多少钱