(self, img_url)
| 636 | pass |
| 637 | |
| 638 | def __call__(self, img_url): |
| 639 | resp = urllib.urlopen(img_url) |
| 640 | sample = resp.read() |
| 641 | data = np.fromstring(sample, np.uint8) |
| 642 | img = cv2.imdecode(data, cv2.IMREAD_COLOR) |
| 643 | return img |
| 644 | |
| 645 | def __repr__(self): |
| 646 | return self.__class__.__name__ + "()" |