
深度学习
我不是狼
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
bert server 搭建
bert server 搭建原创 2022-06-30 10:44:18 · 634 阅读 · 1 评论 -
lossfunction, 损失函数的作用
Loss function L:input:a function, output :how bad it is;L(f) = L(w,b)lossfunction:可以衡量一组参数的好坏。函数的目标是:找到一组使得loss最小的w和b。方法为:gradient descent...原创 2020-04-20 09:29:23 · 865 阅读 · 0 评论 -
TensorFlow中变量初始化函数
tf.constant_initializer : 将变量初始化为常量。eg: >>> import numpy as np >>> import tensorflow as tf >>> value = [0, 1, 2, 3, 4, 5, 6, 7] >>> init = tf.constant_i...原创 2019-03-05 11:44:13 · 444 阅读 · 0 评论 -
TensorFlow 模型持久化
模型保存和还原都是通过TensorFlow的一个API实现的,这个API就是tf.train.saver类 保存模型 eg:import tensorflow as tf#声明两个变量并计算他们的和v1 = tf.Variable(tf.constant(1.0,shape=[1],name="v1"))v2 = tf.Variable(tf.constant(2.0,shape=...转载 2019-03-05 15:35:49 · 261 阅读 · 0 评论 -
DNN或深度学习中常用函数
1、tf.multiply(x,y) 对应元素相乘x: 一个类型为:half, float32, float64, uint8, int8, uint16, int16, int32, int64, complex64, complex128的张量。y: 一个类型跟张量x相同的张量。返回值: x * y element-wise.import tensorflow as tf...原创 2019-03-28 18:43:32 · 339 阅读 · 0 评论 -
TensorFlow decode_csv TextLineDataset 读取数据
1decode_csv读取数据import tensorflow as tf#创建文件队列filenames ['./s0000025_1.csv','./s0000025_2.csv']filename_queue = tf.train.string_input_producer(filenames,shuffle=True)#shuffle=True 文件队列随机读取,默认...原创 2019-04-11 14:36:38 · 1861 阅读 · 0 评论