D2 Instance Utility Change
D2 Instance Utility Change

Summary: Adds option for returning indexing of filtered instances. Used in MaskTrackRCNN implementation (D29564369) when computing ground truth and reference instance ids.

Reviewed By: ppwwyyxx, weiyaowang

Differential Revision: D29178584

fbshipit-source-id: 8fe20c3e0258608347b3a2391374cf58fadde85d

facebookresearch/detectron2,facebookresearch/detectron2,facebookresearch/detectron2