Skip to content

Commit c068bad

Browse files
committed
Fix issue with directly instantiating subclass of DJLLargeModel
1 parent b54a0d9 commit c068bad

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/sagemaker/djl_inference/model.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ def __new__(
8585
config_file = uncompressed_model_data + "/config.json"
8686

8787
model_type = json.loads(s3.S3Downloader.read_file(config_file)).get("model_type")
88-
cls_to_create = _determine_engine_for_model_type(model_type)
88+
cls_to_create = cls if cls is not DJLLargeModel else _determine_engine_for_model_type(model_type)
8989
return super(DJLLargeModel, cls).__new__(cls_to_create)
9090

9191
def __init__(

0 commit comments

Comments
 (0)