Update handler.py
Browse files- handler.py +0 -1
handler.py
CHANGED
|
@@ -14,7 +14,6 @@ class EndpointHandler():
|
|
| 14 |
|
| 15 |
|
| 16 |
def predict_image(self, url, prompt):
|
| 17 |
-
url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/transformers/tasks/car.jpg?download=true"
|
| 18 |
image = Image.open(requests.get(url, stream=True).raw)
|
| 19 |
|
| 20 |
inputs = self.processor(text=prompt, images=image, return_tensors="pt").to(self.device, self.torch_dtype)
|
|
|
|
| 14 |
|
| 15 |
|
| 16 |
def predict_image(self, url, prompt):
|
|
|
|
| 17 |
image = Image.open(requests.get(url, stream=True).raw)
|
| 18 |
|
| 19 |
inputs = self.processor(text=prompt, images=image, return_tensors="pt").to(self.device, self.torch_dtype)
|