Spaces:
Sleeping
Sleeping
minro changes
Browse files
utils.py
CHANGED
|
@@ -168,7 +168,7 @@ def plot_image(image, boxes):
|
|
| 168 |
|
| 169 |
buffer = BytesIO()
|
| 170 |
plt.axis('off')
|
| 171 |
-
plt.savefig(buffer,format='png')
|
| 172 |
visualization = Image.open(buffer)
|
| 173 |
|
| 174 |
return visualization
|
|
|
|
| 168 |
|
| 169 |
buffer = BytesIO()
|
| 170 |
plt.axis('off')
|
| 171 |
+
plt.savefig(buffer,format='png', bbox_inches='tight', pad_inches=0)
|
| 172 |
visualization = Image.open(buffer)
|
| 173 |
|
| 174 |
return visualization
|