Update _utils.py
This commit is contained in:
parent
c4e1bd9b52
commit
08afb5001e
1 changed files with 4 additions and 1 deletions
|
|
@ -256,7 +256,10 @@ for model_name in model_architectures:
|
|||
config_filepath = f"transformers.models.{model_name}.configuration_{model_name}"
|
||||
model_filepath = f"transformers.models.{model_name}.modeling_{model_name}"
|
||||
config_filename = f"{model_name.title().replace('_','')}Config" # qwen3 arch folder is qwen3_moe but config is Qwen3Config. Need to remove underscore(_) for now
|
||||
exec(f"from {config_filepath} import {config_filename}", globals())
|
||||
try:
|
||||
exec(f"from {config_filepath} import {config_filename}", globals())
|
||||
except:
|
||||
continue
|
||||
|
||||
try:
|
||||
config = inspect.getsource(eval(config_filename))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue