Update app.py
Browse files
app.py
CHANGED
|
@@ -114,8 +114,7 @@ def pipe_inference(
|
|
| 114 |
return all_outputs
|
| 115 |
|
| 116 |
def resize_image(image, resolution):
|
| 117 |
-
|
| 118 |
-
h, w = image.shape
|
| 119 |
ratio = w/h
|
| 120 |
if ratio > 1 :
|
| 121 |
resized_image = cv2.resize(image, (int(resolution*ratio), resolution), interpolation=cv2.INTER_NEAREST)
|
|
|
|
| 114 |
return all_outputs
|
| 115 |
|
| 116 |
def resize_image(image, resolution):
|
| 117 |
+
h, w = image.shape[:2]
|
|
|
|
| 118 |
ratio = w/h
|
| 119 |
if ratio > 1 :
|
| 120 |
resized_image = cv2.resize(image, (int(resolution*ratio), resolution), interpolation=cv2.INTER_NEAREST)
|