Skip to content

Commit

Permalink
Merge pull request #110 from BlackSamorez/pretrained_fix
Browse files Browse the repository at this point in the history
find_predefined_tensor_parallel_config try-except fix
  • Loading branch information
Andrei Panferov authored Jul 26, 2023
2 parents 31c7097 + f000c03 commit c40153c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = tensor_parallel
version = 1.3.0
version = 1.3.1
author = Andrei Panferov and Yaroslav Lisnyak
author_email = [email protected]
description = Automatically shard your large model between multiple GPUs, works without torch.distributed
Expand Down
4 changes: 2 additions & 2 deletions src/tensor_parallel/pretrained_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ def find_predefined_tensor_parallel_config(
) -> Optional[Config]:
device_ids = check_device_ids(device_ids)

try:
if model_config.model_type in PREDEFINED_CONFIGS:
return PREDEFINED_CONFIGS[model_config.model_type](model_config, device_ids)
except KeyError:
else:
logger.warning(
"Using automatic config: tensor parallel config not provided and no custom config registered for the model"
)
Expand Down

0 comments on commit c40153c

Please sign in to comment.