|
@@ -13,10 +13,13 @@ class SurrogateType(enum.Enum):
|
|
|
def __call__(self, im, w, h, dtype=np.uint8):
|
|
|
if self is SurrogateType.BLANK:
|
|
|
return self._blank(im, w, h, dtype=dtype)
|
|
|
+
|
|
|
elif self is SurrogateType.IMAGE:
|
|
|
return self._image(im, w, h, dtype=dtype)
|
|
|
+
|
|
|
elif self is SurrogateType.MIDDLE:
|
|
|
return self._middle(im, w, h, dtype=dtype)
|
|
|
+
|
|
|
else:
|
|
|
raise ValueError("Unknown surrogate method: {}".format(self))
|
|
|
|