Update handler.py
Browse files- handler.py +2 -2
handler.py
CHANGED
@@ -8,8 +8,8 @@ class EndpointHandler():
|
|
8 |
def __init__(self, path=""):
|
9 |
# load the optimized model
|
10 |
self.device = "cuda:0"
|
11 |
-
self.model = AutoModelForVision2Seq.from_pretrained("
|
12 |
-
self.processor = AutoProcessor.from_pretrained("
|
13 |
|
14 |
def __call__(self, data: dict[str, Any]) -> str:
|
15 |
"""
|
|
|
8 |
def __init__(self, path=""):
|
9 |
# load the optimized model
|
10 |
self.device = "cuda:0"
|
11 |
+
self.model = AutoModelForVision2Seq.from_pretrained("HuggingFaceM4/idefics2-8b").to(self.device)
|
12 |
+
self.processor = AutoProcessor.from_pretrained("HuggingFaceM4/idefics2-8b")
|
13 |
|
14 |
def __call__(self, data: dict[str, Any]) -> str:
|
15 |
"""
|