(img, gt, scales)
| 103 | |
| 104 | |
| 105 | def random_scale(img, gt, scales): |
| 106 | scale = random.choice(scales) |
| 107 | sh = int(img.shape[0] * scale) |
| 108 | sw = int(img.shape[1] * scale) |
| 109 | img = cv2.resize(img, (sw, sh), interpolation=cv2.INTER_LINEAR) |
| 110 | gt = cv2.resize(gt, (sw, sh), interpolation=cv2.INTER_NEAREST) |
| 111 | |
| 112 | return img, gt, scale |
| 113 | |
| 114 | |
| 115 | def random_scale_rgbx(img, gt, modal_x, scales): |
nothing calls this directly
no outgoing calls
no test coverage detected