vasgaowei / pytorch_MELM

The pytorch implementation of the Min-Entropy Latent Model for Weakly Supervised Object Detection
104 stars 19 forks source link

Pretrained Weight gives worse performance #25

Open yoyoleeisstrong opened 3 years ago

yoyoleeisstrong commented 3 years ago

I tried very hard to implement MELM. I reinstalled my CUDA and Pytorch, and solved tons of bugs since this code could never work out on Pytorch 1.0 even I read the tutorial and issues many times. Finally, this github code was successfully executed on Pytorch 0.4.0. However, the pretrained weight gave a really worse performance. Since this repository borrows a lot of codes from another Fast-RCNN repository, it's really hard to understand the code. If someone ever successfully reproduced the mAP 0.45 on VOC data, I'll appreciate it if you would like to share some experience. If the author can make this code easier to understand, I'll appreciate it deeply too.

vasgaowei commented 3 years ago

The number of Region Proposals used in training can affect the detection performance. So you may try adjust the number of proposals. It can be done by modifying the code in network.py as in issue #20

yoyoleeisstrong commented 3 years ago

The current runnable version is highly dependent on PyTorch 0.4.0, but many files need to be compiled by the FFI library. But in the later version of PyTorch, this FFI library has been removed, is there an alternative to compile the following files: RoiPooling RoiRingpooling RoIAlign NMS

This four modules relies on FFI that was deprecated in pytorch 1.0 and later.

vasgaowei commented 3 years ago

I will write a README.md file for pytorch1.0 branch later. The operations you mentioned RoiRingpooling, RoIAlign, NMS are moved to ops folder. And before importing these modules, you should complie the files first by running the following code:

  • cd lib

  • bash make_cuda.sh

Type in bash make.sh won't compile the corresponding files in pytorch1.0 branch. I will delete maks.sh file in pytorch1.0 branch and make a statement in README.md file.