| 查看: 864 | 回复: 3 | |||
| 当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖 | |||
LoseInVain新虫 (初入文坛)
|
[交流]
In tensorflow, how to use the placeholder's value before feeding?已有1人参与
|
||
|
在stack overflow里面发了一个问题,现在还没回答比较急,所以这里求助下~~ New to TensorFlow,Now I need to use the value in placeholder before feeding, something like: tensor = tf.placeholder(tf.float32, [None, 3]) Mat_items = tf.Variable(tf.random_normal([10,10])) Mat_users = tf.Variable(tf.random_normal([10,10])) item_index = tensor[:, 0] user_index = tensor[:, 1] rating = tensor[:, 2] Val = Mat_items[item_index, :]-Mat_users[user_index, :] while tensor is a placeholder with N rows 3 cols, first col and second col is the index to Mat_items and Mat_users respectively and Mat_items Mat_users are the Variables needed to be indexed. Running it will absolutely throw an error because item_index, user_index both are Tensor not numeric before feeding. So I wonder whether Tensorflow could realize this demand? Any suggestion will be appreciate! ![]() |
» 猜你喜欢
请问哪里可以有青B申请的本子可以借鉴一下。
已经有4人回复
真诚求助:手里的省社科项目结项要求主持人一篇中文核心,有什么渠道能发核心吗
已经有6人回复
孩子确诊有中度注意力缺陷
已经有14人回复
三甲基碘化亚砜的氧化反应
已经有4人回复
请问下大家为什么这个铃木偶联几乎不反应呢
已经有5人回复
请问有评职称,把科研教学业绩算分排序的高校吗
已经有5人回复
2025冷门绝学什么时候出结果
已经有3人回复
天津工业大学郑柳春团队欢迎化学化工、高分子化学或有机合成方向的博士生和硕士生加入
已经有4人回复
康复大学泰山学者周祺惠团队招收博士研究生
已经有6人回复
AI论文写作工具:是科研加速器还是学术作弊器?
已经有3人回复
LoseInVain
新虫 (初入文坛)
- 应助: 0 (幼儿园)
- 金币: 99.5
- 帖子: 6
- 在线: 11.7小时
- 虫号: 4308259
- 注册: 2015-12-23
- 性别: GG
- 专业: 信息处理方法与技术
3楼2017-06-23 14:12:57














回复此楼