Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

遇到InvalidArgumentError #2

Open
qxyjyj opened this issue Mar 15, 2018 · 7 comments
Open

遇到InvalidArgumentError #2

qxyjyj opened this issue Mar 15, 2018 · 7 comments

Comments

@qxyjyj
Copy link

qxyjyj commented Mar 15, 2018

您好,在运行代码main.py时,出现如下错误:
InvalidArgumentError (see above for traceback): You must feed a value for placeholder tensor 'Placeholder' with dtype float
[[Node: Placeholder = Placeholderdtype=DT_FLOAT, shape=[], _device="/job:localhost/replica:0/task:0/cpu:0"]]
不知道作者有没有遇见过这个问题?

@Muneeb121
Copy link

Muneeb121 commented Mar 15, 2018

can u please tell me where to feed placeholder....
data_prepare?
or in model?
And How...means give a example of placeholder

@qxyjyj
Copy link
Author

qxyjyj commented Mar 16, 2018

When I run main.py to train model, there's a problem. The problem is:
File "F:\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\client\session.py", line 1052, in _do_call raise type(e)(node_def, op, message)
InvalidArgumentError: You must feed a value for placeholder tensor 'Placeholder' with dtype float [[Node: Placeholder = Placeholderdtype=DT_FLOAT, shape=[],_device="/job:localhost/replica:0/task:0/cpu:0"]]

So I step through each line of code. After running the code (_,summary = sess.run([train_step, merged],feed_dict =feed_dict, in line 123), the program is out of the current function(inference(self,npy_path,test_path,model_index,train_flag=True)). The following code (train_writer.add_summary(summary, i) and saver.save(sess, './ckpt/archi-1', global_step=i + 1))have not been executed. I can't solve this problem. Could you help me?
@Muneeb121 @shartoo

@shartoo
Copy link
Owner

shartoo commented Mar 25, 2018

@qxyjyj @Muneeb121 Sorry ,i lost my dataset, i'll update the project later. 我现在手里没数据了,这个数据集不好下,过段时间再更新下。

@wangyage09
Copy link

@qxyjyj 您好!我运行main.py文件时,遇到了和您一样问题,不知道您的问题解决了没有,想请教您一下

@qxyjyj
Copy link
Author

qxyjyj commented Dec 10, 2018 via email

@qishuaizheng
Copy link

您好,为什么第一个尺寸的模型可以跑通,其他两个尺寸的模型跑不通呀?错误如下:“InvalidArgumentError (see above for traceback): logits and labels must be broadcastable: logits_size=[128,2] labels_size=[32,2]
[[node softmax_cross_entropy_with_logits_sg (defined at H:/自己的软件/代码文献/1/luna16_multi_size_3dcnn-master/new_model.py:267)。” 万分感谢,谢谢。

@qxyjyj
Copy link
Author

qxyjyj commented Mar 28, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants