(bbox)
| 72 | |
| 73 | |
| 74 | def bbox_process(bbox): |
| 75 | x_min = int(bbox[0]) |
| 76 | y_min = int(bbox[1]) |
| 77 | x_max = x_min + int(bbox[2]) |
| 78 | y_max = y_min + int(bbox[3]) |
| 79 | return list(map(int, [x_min, y_min, x_max, y_max])) |
| 80 | |
| 81 | |
| 82 | def prepare_dataset(dataset, splits, output_dir, generate_mask=False): |