advaitadasein
commited on
Commit
•
e9fb176
1
Parent(s):
ff92cea
Update handler.py
Browse files- handler.py +2 -2
handler.py
CHANGED
@@ -8,8 +8,8 @@ from io import BytesIO
|
|
8 |
|
9 |
class EndpointHandler():
|
10 |
def __init__(self, path=""):
|
11 |
-
self.processor = Blip2Processor.from_pretrained("Salesforce/blip2-opt-
|
12 |
-
self.model = Blip2ForConditionalGeneration.from_pretrained("Salesforce/blip2-opt-
|
13 |
|
14 |
self.device = "cuda" if torch.cuda.is_available() else "cpu"
|
15 |
self.model.to(self.device)
|
|
|
8 |
|
9 |
class EndpointHandler():
|
10 |
def __init__(self, path=""):
|
11 |
+
self.processor = Blip2Processor.from_pretrained("Salesforce/blip2-opt-2.7b")
|
12 |
+
self.model = Blip2ForConditionalGeneration.from_pretrained("Salesforce/blip2-opt-2.7b")
|
13 |
|
14 |
self.device = "cuda" if torch.cuda.is_available() else "cpu"
|
15 |
self.model.to(self.device)
|