
深度学习
poson
搞过图像处理感觉刚入门做搜索引擎只玩过单机版广告技术做了QueryRewrite目前做推荐算法感觉推荐算法和关键词推荐本质上是一样的爱数学爱计算机爱生活
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
tensorflow 的 hashtable 和index table 读取,求均值向量,缺失值处理
import tensorflow as tf print(tf.__version__) list_arr = [9, 8, 6, 5] value_arr = [0, 1, 2, 3] tf_look_up = tf.constant(list_arr, dtype=tf.int64) tf_value_arr = tf.constant(value_arr, dtype=tf.int64) table = tf.contrib.lookup.HashTable(tf.contrib.lookup.原创 2020-06-07 17:15:45 · 1596 阅读 · 0 评论 -
样本查询embedding向量
import tensorflow as tf #生成10*5的张量 p=tf.Variable(tf.random_normal([10,5])) # 模拟两个样本中的2个稀疏字段的embedding,有4个元素1,3,2,4 b = tf.nn.embedding_lookup(p, [[1, 3],[2,4]]) # b 的维度是2 * 2 * 5 ,batch=2 ,field s...原创 2020-05-03 10:36:26 · 578 阅读 · 0 评论 -
深度学习 tensorflow 三维矩阵乘法(batch 迭代必须搞懂的矩阵乘法,维度增加)
import tensorflow as tf # 2 * 2 * 2 的embedding 矩阵 , 一个batch,每个样本有f个字段,每个字段有k维 # 那么矩阵的大小就是batch * f * k embedding_index = tf.constant([[[0.1,0.2], [0.3,0.2]], ...原创 2020-05-03 09:32:40 · 4176 阅读 · 0 评论