Created
November 28, 2021 22:16
-
-
Save damanm24/b2ddc11a3e0fa0d6f6880b334f60fb44 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cluster_boxes_data = get_cluster_box_info(frame, box_info) | |
task_batches = [] | |
cluster_boxes_data.sort(key=lambda x : (x[2] - x[0]) * (x[3] - x[1])) | |
# student's code here | |
for i in range(len(cluster_boxes_data)): | |
task = TaskEntity(image_path=frame.path, coord=cluster_boxes_data[i][:4], depth=cluster_boxes_data[i][4]) | |
task_batch = TaskBatch([task], task.img_width, task.img_height, priority=i) | |
task_batches.append(task_batch) | |
return task_batches |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment