So I have a batch of masks (values 0.0/1.0) with dimension (b,h,w) where b is the batch-dim.
For each mask, i need the coordinate of the the bounding box containing all the ones. I thought about using various operators (torch.where/torch.nonzero) but I can’t get it to work in a batched setting.