第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機(jī)立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

我們可以在feed_dict中將tf.variable饋送到tf.placeholder嗎?

我們可以在feed_dict中將tf.variable饋送到tf.placeholder嗎?

回首憶惘然 2021-05-20 18:14:14
我想用張量流做一個簡單的任務(wù)。但是我遇到一個錯誤import numpy as npimport pandas as pdfv = tf.Variable(10.0,name="first_var")sv = tf.Variable(20.0,np.random.randn(),name="second_var")fvp = tf.placeholder("float32",name="first_fvp",shape=[])svp = tf.placeholder("float32",name="second_svp",shape=[])result = tf.Variable(0.0,name="output")result =  np.multiply(fvp,svp)sess = tf.Session()sess.run(tf.global_variables_initializer())print(sess.run(result,feed_dict={fvp:fv,svp:sv}))錯誤=設(shè)置具有序列的數(shù)組元素。在這種情況下,我遇到了錯誤如果我用print(sess.run(result,feed_dict={fvp:5.0,svp:10.0}))我得到50.0的輸出
查看完整描述

1 回答

  • 1 回答
  • 0 關(guān)注
  • 133 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號