zzzxxxttt / pytorch_simple_CenterNet_45

A simple pytorch implementation of CenterNet (Objects as Points)
308 stars 63 forks source link

How can we train on our own custom dataset? #7

Closed davidhuangal closed 4 years ago

zzzxxxttt commented 4 years ago

Just modify the datasets/coco.py (or create a new dataset file) and implement the image reading/preprocessing part in __getitem__ function, the output of __getitem__ should follow the same pattern:

        return {'image': img,
            'hmap': hmap, 'w_h_': w_h_, 'regs': regs, 'inds': inds, 'ind_masks': ind_masks,
            'c': center, 's': scale, 'img_id': img_id}
davidhuangal commented 4 years ago

Thank you.