-
Notifications
You must be signed in to change notification settings - Fork 809
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
TypeError: Expected string passed to parameter 'tensor_names' of op 'SaveV2', got ['Variable', 'Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam', 'Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variab #50
Comments
你好 请问您解决这个问题了吗 |
已解决 但我现在不记得具体要改哪了 晚上回去看了告诉您------------------ 原始邮件 ------------------
发件人: "boyong-csy"<[email protected]>
发送时间: 2019年11月3日(星期天) 上午10:52
收件人: "ChenglongChen/tensorflow-DeepFM"<[email protected]>;
抄送: "wylwylwyl"<[email protected]>;"Author"<[email protected]>;
主题: Re: [ChenglongChen/tensorflow-DeepFM] TypeError: Expected stringpassed to parameter 'tensor_names' of op 'SaveV2', got ['Variable','Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam','Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variab (#50)
你好 请问您解决这个问题了吗
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
感谢感谢 我今天跑代码突然就馊了 麻烦您了
…------------------ 原始邮件 ------------------
发件人: "wylwylwyl"<[email protected]>;
发送时间: 2019年11月3日(星期天) 中午11:00
收件人: "ChenglongChen/tensorflow-DeepFM"<[email protected]>;
抄送: "守望者"<[email protected]>; "Comment"<[email protected]>;
主题: Re: [ChenglongChen/tensorflow-DeepFM] TypeError: Expected string passed to parameter 'tensor_names' of op 'SaveV2', got ['Variable', 'Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam', 'Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variab (#50)
已解决 但我现在不记得具体要改哪了 晚上回去看了告诉您------------------ 原始邮件 ------------------
发件人: "boyong-csy"<[email protected]>
发送时间: 2019年11月3日(星期天) 上午10:52
收件人: "ChenglongChen/tensorflow-DeepFM"<[email protected]>;
抄送: "wylwylwyl"<[email protected]>;"Author"<[email protected]>;
主题: Re: [ChenglongChen/tensorflow-DeepFM] TypeError: Expected stringpassed to parameter 'tensor_names' of op 'SaveV2', got ['Variable','Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam','Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variab (#50)
你好 请问您解决这个问题了吗
&mdash;
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
请问您是怎么解决的呀 |
请问各位 :
TypeError: Expected string passed to parameter 'tensor_names' of op 'SaveV2', got ['Variable', 'Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam', 'Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variab
这个错误是为什么?
完整的错误信息是这样:
Traceback (most recent call last):
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\op_def_library.py", line 511, in _apply_op_helper
preferred_dtype=default_dtype)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\ops.py", line 1175, in internal_convert_to_tensor
ret = conversion_func(value, dtype=dtype, name=name, as_ref=as_ref)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\constant_op.py", line 304, in _constant_tensor_conversion_function
return constant(v, dtype=dtype, name=name)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\constant_op.py", line 245, in constant
allow_broadcast=True)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\constant_op.py", line 283, in _constant_impl
allow_broadcast=allow_broadcast))
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\tensor_util.py", line 501, in make_tensor_proto
(dtype, nparray.dtype, values))
TypeError: Incompatible types: <dtype: 'string'> vs. object. Value is ['Variable', 'Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam', 'Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variable_2/Adam_1', 'Variable_3', 'Variable_3/Adam', 'Variable_3/Adam_1', 'Variable_4', 'Variable_4/Adam', 'Variable_4/Adam_1', 'Variable_5', 'Variable_5/Adam', 'Variable_5/Adam_1', 'beta1_power', 'beta2_power', 'bn_0/beta', 'bn_0/beta/Adam', 'bn_0/beta/Adam_1', 'bn_0/gamma', 'bn_0/gamma/Adam', 'bn_0/gamma/Adam_1', 'bn_0/moving_mean', 'bn_0/moving_variance', 'bn_1/beta', 'bn_1/beta/Adam', 'bn_1/beta/Adam_1', 'bn_1/gamma', 'bn_1/gamma/Adam', 'bn_1/gamma/Adam_1', 'bn_1/moving_mean', 'bn_1/moving_variance', 'feature_bias', 'feature_bias/Adam', 'feature_bias/Adam_1', 'feature_embeddings', 'feature_embeddings/Adam', 'feature_embeddings/Adam_1']
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "E:/pycharm project/2/main.py", line 148, in
y_train_dfm, y_test_dfm = _run_base_model_dfm(dfTrain, dfTest, folds, dfm_params)
File "E:/pycharm project/2/main.py", line 68, in _run_base_model_dfm
dfm = DeepFM(**dfm_params)
File "E:\pycharm project\2\DeepFM.py", line 61, in init
self._init_graph()
File "E:\pycharm project\2\DeepFM.py", line 156, in _init_graph
self.saver = tf.train.Saver()
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 832, in init
self.build()
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 844, in build
self._build(self._filename, build_save=True, build_restore=True)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 881, in _build
build_save=build_save, build_restore=build_restore)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 510, in _build_internal
save_tensor = self._AddSaveOps(filename_tensor, saveables)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 210, in _AddSaveOps
save = self.save_op(filename_tensor, saveables)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\training\saver.py", line 124, in save_op
tensors)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\ops\gen_io_ops.py", line 1920, in save_v2
name=name)
File "C:\Program Files\Anaconda3\envs\tensorflow\lib\site-packages\tensorflow\python\framework\op_def_library.py", line 520, in _apply_op_helper
repr(values), type(values).name))
TypeError: Expected string passed to parameter 'tensor_names' of op 'SaveV2', got ['Variable', 'Variable/Adam', 'Variable/Adam_1', 'Variable_1', 'Variable_1/Adam', 'Variable_1/Adam_1', 'Variable_2', 'Variable_2/Adam', 'Variable_2/Adam_1', 'Variable_3', 'Variable_3/Adam', 'Variable_3/Adam_1', 'Variable_4', 'Variable_4/Adam', 'Variable_4/Adam_1', 'Variable_5', 'Variable_5/Adam', 'Variable_5/Adam_1', 'beta1_power', 'beta2_power', 'bn_0/beta', 'bn_0/beta/Adam', 'bn_0/beta/Adam_1', 'bn_0/gamma', 'bn_0/gamma/Adam', 'bn_0/gamma/Adam_1', 'bn_0/moving_mean', 'bn_0/moving_variance', 'bn_1/beta', 'bn_1/beta/Adam', 'bn_1/beta/Adam_1', 'bn_1/gamma', 'bn_1/gamma/Adam', 'bn_1/gamma/Adam_1', 'bn_1/moving_mean', 'bn_1/moving_variance', 'feature_bias', 'feature_bias/Adam', 'feature_bias/Adam_1', 'feature_embeddings', 'feature_embeddings/Adam', 'feature_embeddings/Adam_1'] of type 'list' instead.
Process finished with exit code 1
The text was updated successfully, but these errors were encountered: