-
Notifications
You must be signed in to change notification settings - Fork 2
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
有bug,找不到生成的tokenizer_config.json文件 #1
Comments
你用的是什么系统?如果是windows,可能是反斜杠导致的,不同系统的反斜杠可能会导致路径问题,\tokenizer_config.json'这个斜杠的方向和其它不一样,可以自己改改。
…------------------ 原始邮件 ------------------
发件人: "haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference" ***@***.***>;
发送时间: 2024年4月12日(星期五) 上午6:47
***@***.***>;
***@***.***>;
主题: [haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference] 有bug,找不到生成的tokenizer_config.json文件 (Issue #1)
FileNotFoundError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_9052/2870374046.py in
31 best_step = global_step
32 model.save_pretrained(save_dir)
---> 33 tokenizer.save_pretrained(save_dir)
34
35 loss.backward() # 反向传播计算梯度
c:\Users\86199\anaconda3\lib\site-packages\paddlenlp\transformers\tokenizer_utils_base.py in save_pretrained(self, save_directory, filename_prefix, **kwargs)
1708 tokenizer_config["tokenizer_class"] = tokenizer_class
1709
-> 1710 with io.open(tokenizer_config_file, "w", encoding="utf-8") as f:
1711 f.write(json.dumps(tokenizer_config, ensure_ascii=False))
1712 logger.info(f"tokenizer config file saved in {tokenizer_config_file}")
FileNotFoundError: [Errno 2] No such file or directory: 'model/2024-04-11/lr=1e-05-epochs=10-wp=0.1-wd=0.01\tokenizer_config.json'
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
这是来自QQ邮箱的假期自动回复邮件。
您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。
|
@haolian123 非常感谢作者大大百忙之中抽出时间解答了我的问题,确实是文件路径的格式问题,目前正在学习nip方向,感觉内容很丰富,所以下载学习学习。再次感谢您 |
尊敬的项目作者
您好,经过您的提示,我成功运行了代码,由于自己才疏学浅,还是有些疑问的地方。成功跑完ModelTraining后得到训练模型,运行了weibocomment.py得到了目标用户的微博文本,再继续运行哪个部分通过模型对目标用户的文本进行情感分析和抑郁预测呢。麻烦您有时间的话回复一下,万分感激!
天知道?
***@***.***
…------------------ 原始邮件 ------------------
发件人: "haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference" ***@***.***>;
发送时间: 2024年4月14日(星期天) 晚上8:08
***@***.***>;
***@***.******@***.***>;
主题: Re: [haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference] 有bug,找不到生成的tokenizer_config.json文件 (Issue #1)
你用的是什么系统?如果是windows,可能是反斜杠导致的,不同系统的反斜杠可能会导致路径问题,\tokenizer_config.json'这个斜杠的方向和其它不一样,可以自己改改。
------------------ 原始邮件 ------------------
发件人:"haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference"***@***.***>;
发送时间: 2024年4月12日(星期五) 上午6:47
***@***.***>;
***@***.***>;
主题: [haolian123/Sentence-level-sentiment-analysis-and-depression-risk-inference] 有bug,找不到生成的tokenizer_config.json文件 (Issue #1)
FileNotFoundError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_9052/2870374046.py in
31 best_step = global_step
32 model.save_pretrained(save_dir)
---> 33 tokenizer.save_pretrained(save_dir)
34
35 loss.backward()# 反向传播计算梯度
c:\Users\86199\anaconda3\lib\site-packages\paddlenlp\transformers\tokenizer_utils_base.py in save_pretrained(self, save_directory, filename_prefix, **kwargs)
1708 tokenizer_config["tokenizer_class"] = tokenizer_class
1709
-> 1710 with io.open(tokenizer_config_file, "w", encoding="utf-8") as f:
1711 f.write(json.dumps(tokenizer_config, ensure_ascii=False))
1712 logger.info(f"tokenizer config file saved in {tokenizer_config_file}")
FileNotFoundError: [Errno 2] No such file or directory: 'model/2024-04-11/lr=1e-05-epochs=10-wp=0.1-wd=0.01\tokenizer_config.json'
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
|
FileNotFoundError Traceback (most recent call last)
~\AppData\Local\Temp/ipykernel_9052/2870374046.py in
31 best_step = global_step
32 model.save_pretrained(save_dir)
---> 33 tokenizer.save_pretrained(save_dir)
34
35 loss.backward() # 反向传播计算梯度
c:\Users\86199\anaconda3\lib\site-packages\paddlenlp\transformers\tokenizer_utils_base.py in save_pretrained(self, save_directory, filename_prefix, **kwargs)
1708 tokenizer_config["tokenizer_class"] = tokenizer_class
1709
-> 1710 with io.open(tokenizer_config_file, "w", encoding="utf-8") as f:
1711 f.write(json.dumps(tokenizer_config, ensure_ascii=False))
1712 logger.info(f"tokenizer config file saved in {tokenizer_config_file}")
FileNotFoundError: [Errno 2] No such file or directory: 'model/2024-04-11/lr=1e-05-epochs=10-wp=0.1-wd=0.01\tokenizer_config.json'
The text was updated successfully, but these errors were encountered: