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

name 'get_model_name_from_path' is not defined #214

Open
jby20180901 opened this issue Aug 27, 2024 · 2 comments
Open

name 'get_model_name_from_path' is not defined #214

jby20180901 opened this issue Aug 27, 2024 · 2 comments

Comments

@jby20180901
Copy link

2024-08-27 16:25:35.109 | ERROR | main:cli_evaluate:216 - Error during evaluation: name 'get_model_name_from_path' is not defined
Traceback (most recent call last):
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/main.py", line 202, in cli_evaluate
results, samples = cli_evaluate_single(args)
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/main.py", line 298, in cli_evaluate_single
results = evaluator.simple_evaluate(
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/utils.py", line 434, in _wrapper
return fn(*args, **kwargs)
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/evaluator.py", line 96, in simple_evaluate
lm = lmms_eval.api.registry.get_model(model).create_from_arg_string(
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/api/model.py", line 92, in create_from_arg_string
return cls(**args, **args2)
File "/home/jiangbaoyang/lmms-eval-main/lmms_eval/models/llava.py", line 92, in init
model_name = model_name if model_name is not None else get_model_name_from_path(pretrained)
NameError: name 'get_model_name_from_path' is not defined
[rank0]:[W827 16:25:35.425639337 ProcessGroupNCCL.cpp:1168] Warning: WARNING: process group has NOT been destroyed before we destruct ProcessGroupNCCL. On normal program exit, the application should call destroy_process_group to ensure that any pending NCCL operations have finished in this process. In rare cases this process can exit before this point and block the progress of another member of the process group. This constraint has always been present, but this warning has only been added since PyTorch 2.4 (function operator())
这是为什么呢

@BrenchCC
Copy link

可以看看你的命令行输入吗,从报错内容看就是你的模型路径出问题,也许是模型名字问题

@Bleking
Copy link

Bleking commented Sep 13, 2024

Hello, I recently had the same error. I do not know your command line but what I can tell you is that you have to use the directory of the model from https://huggingface.co/lmms-lab.

For example, --model_args pretrained lmms-lab/llava-onevision-qwen2-0.5b-si.

I hope it helped you.

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

3 participants