mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-26 09:40:20 +01:00
Fix path on models.py
This commit is contained in:
parent
a777c058af
commit
9c2e7c0fab
@ -56,7 +56,7 @@ def find_model_type(model_name):
|
|||||||
elif any((k in model_name_lower for k in ['gpt4chan', 'gpt-4chan'])):
|
elif any((k in model_name_lower for k in ['gpt4chan', 'gpt-4chan'])):
|
||||||
return 'gpt4chan'
|
return 'gpt4chan'
|
||||||
else:
|
else:
|
||||||
config = AutoConfig.from_pretrained(f"{shared.args.model_dir}/{model_name}")
|
config = AutoConfig.from_pretrained(Path(f'{shared.args.model_dir}/{model_name}'))
|
||||||
# Not a "catch all", but fairly accurate
|
# Not a "catch all", but fairly accurate
|
||||||
if config.to_dict().get("is_encoder_decoder", False):
|
if config.to_dict().get("is_encoder_decoder", False):
|
||||||
return 'HF_seq2seq'
|
return 'HF_seq2seq'
|
||||||
|
Loading…
Reference in New Issue
Block a user