see-- / keras-centernet

A Keras implementation of CenterNet with pre-trained model (unofficial)
MIT License
337 stars 84 forks source link

Using a different backbone network #5

Open gnefihs opened 5 years ago

gnefihs commented 5 years ago

First of all great stuff! I ran your code and it works perfectly for my images.

I'm fairly new to building NNs but I'm thinking of replacing the hourglass network with the new EfficientNet for feature extraction. How should I do that?

Pointing me in a general direction will be extremely useful. Thank you!

EfficientNet paper: https://arxiv.org/abs/1905.11946

see-- commented 5 years ago

Typically, ImageNet models produce 1/32 tensors, if you remove the top. For CenterNet 2D-detection you need three 1/4 tensors. E.g. image: 512, 512, 3 -> hm: 128, 128, 80, reg: 128, 128, 2, wh: 128, 128, 2. You will need a decoder like FPN or DLA to get to 1/4. I think EfficientNet works the same, but I am not familiar with it. The rest can stay the same. Note that I didn't provide training code so you probably won't get far with this repo :)

Use the official one. Define the network and register it here: https://github.com/xingyizhou/CenterNet/blob/master/src/lib/models/model.py#L16. Good luck.

shreejalt commented 5 years ago

Hi, I want to implement this centernet algorithm for pose estimation in YOLOv3. Can you provide me the training code which includes the loss implementation of centernet for human pose estimation, so that I can get the idea that how to amalgamate the regression and classification losses in YOLOv3.

Thank you.