上一页 1 ··· 4 5 6 7 8 9 下一页
摘要: 一、卷积神经网络应用于MNIST数据集分类 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets('MNIST_data' 阅读全文
posted @ 2018-09-03 19:16 python坚持者 阅读(1594) 评论(0) 推荐(0) 编辑
摘要: 一、即时执行模式 import tensorflow as tfimport tensorflow.contrib.eager as tfetfe.enable_eager_execution() a = tf.constant(12)counter = 0while not tf.equal(a, 阅读全文
posted @ 2018-09-01 22:10 python坚持者 阅读(2717) 评论(0) 推荐(0) 编辑
摘要: 一、tensorboard网络结构 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data #载入数据集mnist = input_data.read_data_sets("MNIST_dat 阅读全文
posted @ 2018-09-01 15:21 python坚持者 阅读(285) 评论(0) 推荐(0) 编辑
摘要: 一、优化器 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data #载入数据集mnist = input_data.read_data_sets("MNIST_data",one_hot=T 阅读全文
posted @ 2018-09-01 13:08 python坚持者 阅读(436) 评论(0) 推荐(0) 编辑
摘要: tf.nn.sparse_softmax_cross_entropy_with_logits() #交叉熵计算代码 一、交叉熵 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data #载入数 阅读全文
posted @ 2018-09-01 13:04 python坚持者 阅读(864) 评论(0) 推荐(0) 编辑
摘要: 一、MNIST数据集分类简单版本 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_data #载入数据集mnist = input_data.read_data_sets("MNIST_data 阅读全文
posted @ 2018-09-01 12:38 python坚持者 阅读(650) 评论(0) 推荐(0) 编辑
摘要: 一、读取MNIST数据 import tensorflow as tffrom tensorflow.examples.tutorials.mnist import input_datamnist = input_data.read_data_sets("MNIST_data", one_hot = 阅读全文
posted @ 2018-08-30 22:22 python坚持者 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 1、TensorFlow中矩阵量的存在形式常用的有三种,或者说相应的python类有三种,具体如下: 2) tf.Variable() #是变量,表示神经网络中可变化的量,(可以通过trainable=False设置成不可变),可在运行中赋值,可以通过constant进行初始化,或者以其他方法进行初 阅读全文
posted @ 2018-08-29 19:02 python坚持者 阅读(152) 评论(0) 推荐(0) 编辑
摘要: tf.rank() 1、rank(input, name=None) #第一个input表示输入数据,第二个参数name表示 2、reduce_sum(input, axis=None,keep_dims=False,name=None,reduction_indices=None) #对张量中的所 阅读全文
posted @ 2018-08-28 21:01 python坚持者 阅读(213) 评论(0) 推荐(0) 编辑
摘要: import tensorflow as tfimport numpy as npBATCH_SIZE = 8seed = 23455 rng = np.random.RandomState(seed)X = rng.rand(32,2)Y = [[int(x0 + x1 < 1)] for (x0 阅读全文
posted @ 2018-08-27 19:00 python坚持者 阅读(192) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 下一页