Tensorflow
杨鑫校
学无止境!
展开
-
Tensorflow的MNIST数据集下载脚本(input_data.py)
tensorflow网站上的链接有时候无法访问,有需要的同学可以拿走了#copyright 2015 Google Inc. All Rights Reserved.## Licensed under the Apache License, Version 2.0 (the "License");# you may not use this file except in complia...原创 2018-11-23 21:52:33 · 1404 阅读 · 1 评论 -
Tensorflow变量的保存和恢复
Tensorflow使用tf.train.Saver来进行变量的保存和恢复,当然还可以进行整个模型的保存,以下代码实例展示了如何进行模型和变量的保存#-*- coding=utf-8 -*-import tensorflow as tf# sess = tf.InteractiveSession()weights = tf.Variable(tf.random_normal([78...原创 2018-11-22 16:04:52 · 242 阅读 · 0 评论 -
Tensorflow的hello world =MNIST入门
主题流程是这样的:首先下载数据,mnist自动解析为训练数据和测试数据,每张图解析为784维向量,根据图片中像素加权,通过softMax函数计算图片中数字是0~9中某个数字的概率,使用梯度下降最小化交叉熵,最后根据真实值和预测值评估模型准确度#-*- coding=utf-8 -*-import tensorflow as tfimport input_dataimport oso...原创 2018-11-23 14:39:03 · 247 阅读 · 0 评论