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

split DSSM model got error #356

Open
ucas010 opened this issue Mar 27, 2023 · 5 comments
Open

split DSSM model got error #356

ucas010 opened this issue Mar 27, 2023 · 5 comments

Comments

@ucas010
Copy link

ucas010 commented Mar 27, 2023

hi,dear 大佬
from the issue I tried the split script
but got the bug bellow:

python  ../easy_rec/python/tools/split_model_pai.py --model_dir ../conf/dssm/_ckpt/export/final/  --user_model_dir ../conf/dssm/userModel/ --item_model_dir ../conf/dssm/itemModel/
Traceback (most recent call last):
  File "../easy_rec/python/tools/split_model_pai.py", line 276, in <module>
    tf.app.run()
  File "python3.7/site-packages/tensorflow_core/python/platform/app.py", line 40, in run
    _run(main=main, argv=argv, flags_parser=_parse_flags_tolerate_undef)
  File /python3.7/site-packages/absl/app.py", line 312, in run
    _run_main(main, args)
  File "/python3.7/site-packages/absl/app.py", line 258, in _run_main
    sys.exit(main(argv))
  File "../easy_rec/python/tools/split_model_pai.py", line 263, in main
    part_dir=FLAGS.user_model_dir)
  File "../easy_rec/python/tools/split_model_pai.py", line 203, in export
    saver = tf_saver.Saver()
  File "/python3.7/site-packages/tensorflow_core/python/training/saver.py", line 828, in __init__
    self.build()
  File "/python3.7/site-packages/tensorflow_core/python/training/saver.py", line 840, in build
    self._build(self._filename, build_save=True, build_restore=True)
  File "/python3.7/site-packages/tensorflow_core/python/training/saver.py", line 865, in _build
    raise ValueError("No variables to save")
ValueError: No variables to save

could u pls help me ?
thx

@yunkchen
Copy link
Collaborator

/conf/dssm/_ckpt/export/final/ 目录下确认模型导出正确么?

@ucas010
Copy link
Author

ucas010 commented Mar 28, 2023

python -m easy_rec.python.train_eval这个就是包括导出模型了吧,不用再python -m easy_rec.python.export了吧。
检查如下,
drwxr-xr-x 4 root root 59 3月 27 18:54 1679914493
这个文件夹下面

-rw-r--r-- 1 root root 204K 3月  27 18:54 saved_model.pb
drwxr-xr-x 2 root root   66 3月  27 18:54 variables
drwxr-xr-x 2 root root   29 3月  27 18:54 assets

@ucas010
Copy link
Author

ucas010 commented Mar 28, 2023

ml-1m数据集AUC=0.72这个正常么?

@wwxxzz
Copy link
Collaborator

wwxxzz commented Mar 29, 2023

ml-1m数据集AUC=0.72这个正常么?

是正常的,可以尝试通过调参提升指标或者使用真实业务数据。

@poson
Copy link
Collaborator

poson commented Jun 12, 2023

python -m easy_rec.python.train_eval

python -m easy_rec.python.train_eval 这个是训练和评估,没有导出模型呀

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

4 participants