I don’t quite understand the last sentence, but the previous error is raised if no bboxes are detected and they are thus None. My guess is that the code you are using isn’t properly guarding against this case and thus fails.