Spaces:
Running
on
Zero
Running
on
Zero
Update gradio_utils/utils.py
Browse files- gradio_utils/utils.py +2 -2
gradio_utils/utils.py
CHANGED
@@ -2,7 +2,7 @@ import copy
|
|
2 |
import spaces
|
3 |
import json
|
4 |
import random
|
5 |
-
import collections
|
6 |
import gradio as gr
|
7 |
import numpy as np
|
8 |
import psutil
|
@@ -89,7 +89,7 @@ def plot_results(support_img, query_img, query_w,
|
|
89 |
c = next(color)
|
90 |
elif isinstance(color, str):
|
91 |
c = color
|
92 |
-
elif isinstance(color, collections.Iterable):
|
93 |
c = next(color)
|
94 |
else:
|
95 |
raise ValueError("Color must be a string or an iterable")
|
|
|
2 |
import spaces
|
3 |
import json
|
4 |
import random
|
5 |
+
import collections.abc
|
6 |
import gradio as gr
|
7 |
import numpy as np
|
8 |
import psutil
|
|
|
89 |
c = next(color)
|
90 |
elif isinstance(color, str):
|
91 |
c = color
|
92 |
+
elif isinstance(color, collections.abc.Iterable):
|
93 |
c = next(color)
|
94 |
else:
|
95 |
raise ValueError("Color must be a string or an iterable")
|