Giter Club home page Giter Club logo

m2det's People

Contributors

keng000 avatar kzykmyzw avatar luxedo avatar qijiezhao avatar telechan avatar ximitiejiang avatar yukkyo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

m2det's Issues

about test.py

What should I do if I want to use a VOC data set? Sorry, I am confused here.

compile error with cpu_nms.c

nms/cpu_nms.c: In function ‘__pyx_pf_3nms_7cpu_nms_2cpu_soft_nms’:
nms/cpu_nms.c:3172:33: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
__pyx_t_8 = ((__pyx_v_pos < __pyx_v_N) != 0);
^
nms/cpu_nms.c:3683:33: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
__pyx_t_8 = ((__pyx_v_pos < __pyx_v_N) != 0);
^
nms/cpu_nms.c: In function ‘__Pyx_PyCFunction_FastCall’:
nms/cpu_nms.c:8431:12: error: too many arguments to function ‘(PyObject * ()(PyObject , PyObject * const, Py_ssize_t))meth’
return (
((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL);
^
nms/cpu_nms.c: In function ‘__Pyx__ExceptionSave’:
nms/cpu_nms.c:8892:19: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_type’
*type = tstate->exc_type;
^
nms/cpu_nms.c:8893:20: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_value’
*value = tstate->exc_value;
^
nms/cpu_nms.c:8894:17: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_traceback’
*tb = tstate->exc_traceback;
^
nms/cpu_nms.c: In function ‘__Pyx__ExceptionReset’:
nms/cpu_nms.c:8901:22: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_type’
tmp_type = tstate->exc_type;
^
nms/cpu_nms.c:8902:23: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_value’
tmp_value = tstate->exc_value;
^
nms/cpu_nms.c:8903:20: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_traceback’
tmp_tb = tstate->exc_traceback;
^
nms/cpu_nms.c:8904:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_type’
tstate->exc_type = type;
^
nms/cpu_nms.c:8905:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_value’
tstate->exc_value = value;
^
nms/cpu_nms.c:8906:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_traceback’
tstate->exc_traceback = tb;
^
nms/cpu_nms.c: In function ‘__Pyx__GetException’:
nms/cpu_nms.c:8961:22: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_type’
tmp_type = tstate->exc_type;
^
nms/cpu_nms.c:8962:23: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_value’
tmp_value = tstate->exc_value;
^
nms/cpu_nms.c:8963:20: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_traceback’
tmp_tb = tstate->exc_traceback;
^
nms/cpu_nms.c:8964:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_type’
tstate->exc_type = local_type;
^
nms/cpu_nms.c:8965:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_value’
tstate->exc_value = local_value;
^
nms/cpu_nms.c:8966:11: error: ‘PyThreadState {aka struct _ts}’ has no member named ‘exc_traceback’
tstate->exc_traceback = local_tb;
^
error: command 'gcc' failed with exit status 1

about 2015 test-dev?

可以公开下你们的数据集的选择么是在2017coco数据集还是以前的版本的coco呢,你们的评估服务器是怎么提交的呢?2015 test-dev么

A question about SFAM Module

作者你好,我用你给出的代码复现了论文的结果,非常感谢
但是我注意到config文件中SFAM默认是不使用的,然后我测试了使用SFAM的情况,发现效果没有改进,有些反而变差了,请问是什么原因呢?

try to use MLFPN on exist SSD model, but the mAP did not reach as expected...?

hello, I tried to move MLFPN on exist SSD model which has been proved to reach mAP0.78 on VOC07+12, but when I add MLFPN to this SSD(vgg16, pretrained model from caffe, together with mean/std setting.) the mAP can only reach to 0.57 when i trained 80 epochs with below setting:

  1. 2x1080Ti
  2. 4 imgs per GPU (also tried 8 imgs per GPU but not help to the loss)
  3. lr = [0.002, 0.0002, 0.0002], epoch = [40,80,120]
    i trained the model for 120 epochs but the loss reach stable after 80 epoch, no use for increase from 4 img per GPU to 8 img per GPU(GPU cache has reach to 10G), no use for increase lr to 0.001, currenly the mAP on VOC is 0.57, could you give any suggestion about my training?
    by the way i did not use softnms, but the affect should not be so big...

FFMv1 for resnet-101

In your paper, FFMv1 fuses shallow and deep features.
For resnet-101, if FFMv1 fuses conv4_x and conv5_x, the base feature resolution is 20 x 20.
It is too small for next module.
Could you explain the implementation more detail?

RuntimeError: Error(s) in loading state_dict for ModuleList:

the completed error message:
Loading base network...
Traceback (most recent call last):
File "train.py", line 38, in
init_net(net, cfg, args.resume_net) # init the network with pretrained weights or resumed weights
File "/data/M2Det/utils/core.py", line 39, in init_net
net.init_model(cfg.model.pretrained)
File "/data/M2Det/m2det.py", line 155, in init_model
self.base.load_state_dict(base_weights)
File "/data/ananconda3/envs/pytorch/lib/python3.7/site-packages/torch/nn/modules/module.py", line 769, in load_state_dict
self.class.name, "\n\t".join(error_msgs)))
RuntimeError: Error(s) in loading state_dict for ModuleList:
Missing key(s) in state_dict: "0.weight", "0.bias", "2.weight", "2.bias", "5.weight", "5.bias", "7.weight", "7.bias", "10.weight", "10.bias", "12.weight", "12.bias", "14.weight", "14.bias", "17.weight", "17.bias",......
can anyone help me?

l2norm.py

I note the code not use the L2Norm after Conv4_3, such as SSD. you only directly use the BatchNorm2d after the first feature map.

Speed and accuracy test

I got one question about the test result after a scrutiny of this paper. Did you train these comparison models based on pytorch? If so, have you tuned hyperparameters in accord with official documents?
Thanks

Has anyone use tensorboardX to visualize network structure? Some problem about the process of visualizing.

I want to visualize the M2Det network, using the following code.

from configs.CC import Config
from layers.functions import Detect, PriorBox
from m2det import build_net
from tensorboardX import SummaryWriter
from torch.autograd import Variable
from utils.core import *

cfg = Config.fromfile('configs/m2det512_vgg.py')
net = build_net('test',
                size = cfg.model.input_size,
                config = cfg.model.m2det_config)
dummy_input = torch.rand(13, 3, 512, 512)
with SummaryWriter(comment='M2Det') as w:
   w.add_graph(net, (dummy_input, ))

It would raise the error TypeError: conv2d(): argument 'input' (position 1) must be Tensor, not tuple

but when I change the last line to
w.add_graph(net, dummy_input)

it would raise ValueError: Auto nesting doesn't know how to process an input object of type str. Accepted types: Tensors, or lists/tuples of them

Anyone have the experience to visualize the network structure? Please help me , Thx

About TUM

Thank you for a wonderful paper.
I want to try implementing M2Det. But there are two things I do not know.
TUM has six outputs, how are they handled and entered in the next TUM?
The second one, please tell me more about backbones. What kind of processing is done on backbone? Thanks.

License

Could you add license (e.g., MIT License) for this repository?

about initialization

您好!!

关于新层初始化的代码如下:

def init_model(self, base_model_path):
        if self.backbone == 'vgg16':
            if isinstance(base_model_path, str):
                base_weights = torch.load(base_model_path)
                print_info('Loading base network...')
                self.base.load_state_dict(base_weights)
        elif 'res' in self.backbone:
            pass # pretrained seresnet models are initially loaded when defining them.
        
        def weights_init(m):
            for key in m.state_dict():
                if key.split('.')[-1] == 'weight':
                    if 'conv' in key:
                        init.kaiming_normal_(m.state_dict()[key], mode='fan_out')
                    if 'bn' in key:
                        m.state_dict()[key][...] = 1
                elif key.split('.')[-1] == 'bias':
                    m.state_dict()[key][...] = 0
        
        print_info('Initializing weights for [tums, reduce, up_reduce, leach, loc, conf]...')
        for i in range(self.num_levels):
            getattr(self,'unet{}'.format(i+1)).apply(weights_init)
        self.reduce.apply(weights_init)
        self.up_reduce.apply(weights_init)
        self.leach.apply(weights_init)
        self.loc.apply(weights_init)
        self.conf.apply(weights_init)

对于网络中的self.locself.conf,其形式为:

  (loc): ModuleList(
    (0): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (1): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (2): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (3): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (4): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (5): Conv2d(2048, 24, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
  )
  (conf): ModuleList(
    (0): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (1): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (2): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (3): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (4): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
    (5): Conv2d(2048, 486, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1))
  )

根据code,其key中并无conv.感觉这2个层并没有进行初始化

error with demo.py

(M2Det) xlm@xlm-OptiPlex-9010:~/anaconda3/M2Det$ python demo.py -c=configs/m2det512_vgg.py -m=weights/m2det512_vgg.pth --show

| M2Det Demo Program |

The Anchor info:
{'feature_maps': [64, 32, 16, 8, 4, 2], 'min_dim': 512, 'steps': [8, 16, 32, 64, 128, 256], 'min_sizes': [30.72, 76.8, 168.96, 261.12, 353.28, 445.44], 'max_sizes': [76.8, 168.96, 261.12, 353.28, 445.44, 537.6], 'aspect_ratios': [[2, 3], [2, 3], [2, 3], [2, 3], [2, 3], [2, 3]], 'variance': [0.1, 0.2], 'clip': True}
===> Constructing M2Det model
Loading resume network...
===> Finished constructing and loading model
Traceback (most recent call last):
File "demo.py", line 128, in
boxes = allboxes[:,:4]
IndexError: too many indices for array
can help me?

Speed about M2Det and RFBNet

Hi,
Great work!
I have a question about the test speed. As RFBNet reported, they achieve 15ms per image, and SSD get 22ms., while speed of m2det is nearly 30ms. Have you check the speed? Using pytorch 0.4.0+, I cannot get that speed. In your paper, SSD is 43 fps. Is it tested on pytorch 0.4.1 as yours?
Thank you very much!

some wrong i don't know

please help me.
when i go run with steps,but something is wrong
i do pip install opencv-python,tqdm sh make.sh,and put the pth into the file "weights",then I run the py python demo.py -c=configs/m2det512_vgg.py -m=weights/m2det512_vgg.pth --show, I fund the wrong.

(pytorch0.4.1) csy@csy:~/M2Det$ python demo.py -c=configs/m2det512_vgg.py -m=weights/m2det512_vgg.pth --show

| M2Det Demo Program |

The Anchor info:
{'clip': True, 'variance': [0.1, 0.2], 'steps': [8, 16, 32, 64, 128, 256], 'min_dim': 512, 'min_sizes': [30.72, 76.8, 168.96, 261.12, 353.28, 445.44], 'aspect_ratios': [[2, 3], [2, 3], [2, 3], [2, 3], [2, 3], [2, 3]], 'feature_maps': [64, 32, 16, 8, 4, 2], 'max_sizes': [76.8, 168.96, 261.12, 353.28, 445.44, 537.6]}
===> Constructing M2Det model
Loading resume network...
===> Finished constructing and loading model
<class 'm2det.M2Det'>
THCudaCheck FAIL file=/pytorch/aten/src/THC/THCGeneral.cpp line=663 error=11 : invalid argument
Traceback (most recent call last):
File "demo.py", line 113, in
out = net(img)
File "/home/csy/anaconda3/envs/pytorch0.4.1/lib/python3.5/site-packages/torch/nn/modules/module.py", line 477, in call
result = self.forward(*input, **kwargs)
File "/home/csy/M2Det/m2det.py", line 106, in forward
x = self.basek
File "/home/csy/anaconda3/envs/pytorch0.4.1/lib/python3.5/site-packages/torch/nn/modules/module.py", line 477, in call
result = self.forward(*input, **kwargs)
File "/home/csy/anaconda3/envs/pytorch0.4.1/lib/python3.5/site-packages/torch/nn/modules/conv.py", line 301, in forward
self.padding, self.dilation, self.groups)
RuntimeError: cuda runtime error (11) : invalid argument at /pytorch/aten/src/THC/THCGeneral.cpp:663

whether i forgot to modify something in others? I am puzzled or not,please help me

M2Det

when will the code be released? According to your table, the M2Det is better than your CFENet, and higher about two points.Thanks. Or if there are paper about M2Det

test speed extremely slow with pytorch 0.4.1 and 1.0

Tried both pytorch 0.4.1 (cuda9) pytorch 1.0 (cuda10) with m2det. Demo runs fine with downloaded pretrain model. Training (800 config) seems to be fine too, e.g. 4 GPUs are all heavily utilized during training.

However, test speed is around 5s per image (not 5 fps, but 5 seconds per frame! it means many hours to get an evaluaiton score). Look into it closely, it seems GPU has very low utility.

Anyone has seen this issue? Thx.

Env: ubuntu 16.04.6, Nvidia 1080 ti (4 GPUs). Cuda9/cudnn7.2.1 or cuda10/cudnn7.4.1.

512x512 Model

你好,我想问一下,对512的分辨率,TUM的结构是怎么样的?
对于320的分辨率,是用的5个下采样,那么对512,是6个下采样吗?
如果是,那么对于最后两个下采样4→2,2→1,用的还是(k=3, s=2, p=1)的卷积结构么?

TUM

hello, thanks for your paper. In your paper, you have used 8 Tums.I want to ask if this will cause the low fps. After all, there are many Convolution layers.Thanks!

About the loss value?

With this code,about how many epoches I can get the performance in the paper or the weights that the owner release?and how about the value of loss ?such as |Loss_L:0.8395||Loss_C:1.9581| or much lower?

About the structure of TUM

It seems that the TUM structure you used is different from the paper.

I read class TUM() in your code, and I draw the structure of TUM:
My draw of TUM

I don't know whether my draw is right. If it is not, is the structure in the code same as that in the paper? If it's right, why the structure is changed like that?

how can i get the pretrained weights file 'vgg16_reducedfc.pth'?

Hello, i am trying to train the M2Det on custom dataset, but when i was trying to train the net, it said could not fould the file 'weights/vgg16_reducedfc.pth'.

I read the code and found that the net use vgg16 as backbone, and I tried to use the pretrained weights downloaded from pytorch.org but seemed not work, so could you give some suggestion as to get the pretrained weights of vgg16_reducedfc?

error with train.py

command:
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 python train.py -c=configs/m2det512_vgg.py --ngpu 8 -t True

raceback (most recent call last):
File "train.py", line 88, in
loss_l, loss_c = criterion(out, priors, targets)
File "/home/xxx/anaconda2/envs/M2Det/lib/python3.6/site-packages/torch/nn/modules/module.py", line 489, in call
result = self.forward(*input, **kwargs)
File "/data2/xxx/Object_Detection/M2Det/layers/modules/multibox_loss.py", line 106, in forward
conf_p = conf_data[(pos_idx+neg_idx).gt(0)].view(-1,self.num_classes)
RuntimeError: CUDA out of memory. Tried to allocate 3.80 GiB (GPU 0; 11.92 GiB total capacity; 8.33 GiB already allocated; 2.69 GiB free; 502.63 MiB cached)

Accuracy on voc2007 datasets

My training uses the voc2007 dataset, which only gets about 72.5% of mAP. The backbone network used for training uses vgg16_reducedfc.pth downloaded online. What is the reason? Is it because I didn't pre-train at IMAGENet2012? Looking forward to your reply

dynamic module does not define module export function (PyInit_cpu_nms)

File "/home/vidana/OurCode/M2Det/utils/nms_wrapper.py", line 9, in
from .nms.cpu_nms import cpu_nms, cpu_soft_nms
ImportError: dynamic module does not define module export function (PyInit_cpu_nms)

when i run the code , i got an error ,could anyone tell me how to solve it? thank you very much

custom classes

Hi! Tell me please, how can I train your model on my data set with a different number of classes?
I created a dataset the same as the directory structure of the dasset PASCAL_VOC.
Then, I changed the path to the dataset and the number of classes in the configuration file.
num_classes = 1

But, i get an error:

/opt/conda/conda-bld/pytorch-nightly_1551849226410/work/aten/src/THC/THCTensorScatterGather.cu:97: void THCudaTensor_gatherKernel(TensorInfo<Real, IndexType>, TensorInfo<Real, IndexType>, TensorInfo<long, IndexType>, int, IndexType) [with IndexType = unsigned int, Real = float, Dims = 2]: block: [273,0,0], thread: [353,0,0] Assertion indexValue >= 0 && indexValue < src.sizes[dim] failed.
/opt/conda/conda-bld/pytorch-nightly_1551849226410/work/aten/src/THC/THCTensorScatterGather.cu:97: void THCudaTensor_gatherKernel(TensorInfo<Real, IndexType>, TensorInfo<Real, IndexType>, TensorInfo<long, IndexType>, int, IndexType) [with IndexType = unsigned int, Real = float, Dims = 2]: block: [271,0,0], thread: [225,0,0] Assertion indexValue >= 0 && indexValue < src.sizes[dim] failed.
/opt/conda/conda-bld/pytorch-nightly_1551849226410/work/aten/src/THC/THCTensorScatterGather.cu:97: void THCudaTensor_gatherKernel(TensorInfo<Real, IndexType>, TensorInfo<Real, IndexType>, TensorInfo<long, IndexType>, int, IndexType) [with IndexType = unsigned int, Real = float, Dims = 2]: block: [204,0,0], thread: [147,0,0] Assertion indexValue >= 0 && indexValue < src.sizes[dim] failed.
nightly_1551849226410/work/aten/src/THC/THCTensorScatterGather.cu:97: void THCudaTensor_gatherKernel(TensorInfo<Real, IndexType>, TensorInfo<Real, IndexType>, TensorInfo<long, IndexType>, int, IndexType) [with IndexType = unsigned int, Real = float, Dims = 2]: block: [31,0,0], thread: [61,0,0] Assertion indexValue >= 0 && indexValue < src.sizes[dim] failed.
Traceback (most recent call last):
File "train.py", line 104, in
loss_l, loss_c = criterion(out, priors, targets)
File "/home/maksim/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 491, in call
result = self.forward(*input, **kwargs)
File "/mnt/data/code/object_detection/M2Det/layers/modules/multibox_loss.py", line 95, in forward
loss_c[pos.view(-1,1)] = 0 # filter out pos boxes for now
RuntimeError: copy_if failed to synchronize: device-side assert triggered

I would be grateful for any help

Upsample in TUMs

Hello,
Sorry for bothering you,but i want to know more detals about TUMs in your paper . you have written that it composed of encoder and decoder, how do you achieve “upsample”? Does it make up of convTranspose and Blinear?

about some details

@qijiezhao HI
非常感觉您的code,非常清晰易懂.
现有几个问题:

  1. 本文提供的训练好的模型应该是没有SFAM模块的吧??另外在configs文件夹中的多个参数文件中,都将sfam设为False.为什么这样设计??

  2. 网络中的"Norm模块"貌似没有参数初始化??另外,为什么要单独对40尺度的特征图进行一个norm操作??

  3. 在TUM模块中,在layers模块中,前4个卷积操作都是kernel_size=(3, 3), stride=(2, 2), padding=(1, 1),为什么第5个卷积是kernel_size=(3, 3), stride=(1, 1).为什么这么设计??

if not i == self.scales - 3:
    self.layers.add_module('{}'.format(len(self.layers)),BasicConv(self.planes, self.planes, 3, 2, 1))
 else:
    self.layers.add_module('{}'.format(len(self.layers)), BasicConv(self.planes, self.planes, 3, 1, 0))
  1. 测试时,直接把原始图片resize到一个固定尺寸,这样改变了原始图片的长宽比,也改变了图片内object的长宽比.对结果是否有影响??

  2. 从code中,貌似并未看到multi-scale evaluation??

  3. paper中指出:The FFMv2 fuses the base feature and the largest output feature map of the previous Tum.从code来看"the largest output feature map of the previous Tum"其实指的就是"尺度最大的那个特征",即40*40的特征.是这样吗??

感谢!!

No module name‘addict’

author, thanks for you code with our‘s build

now ,test this model was ’demo.py' ,ModelNotError: No module named ‘addict’

some error with train.py

Traceback (most recent call last):
File "train.py", line 99, in
loss.backward()
File "/media/dat1/users/master/2019/wuyi/anaconda3/envs/M2Det/lib/python3.6/site-packages/torch/tensor.py", line 102, in backward
torch.autograd.backward(self, gradient, retain_graph, create_graph)
File "/media/dat1/users/master/2019/wuyi/anaconda3/envs/M2Det/lib/python3.6/site-packages/torch/autograd/init.py", line 90, in backward
allow_unreachable=True) # allow_unreachable flag
RuntimeError: element 0 of tensors does not require grad and does not have a grad_fn

I am very confused, can you help me solve it?

about SFAM

HI

自己的一个模型A,训练,测试都没问题.最终在FDDB上能到98.9的结果.
然后,模仿M2Det,尝试加入SFAM模块(即SENet中的**),得到模型B

但是在训练模型B时,loss从一开始到最终都完全不下降(迭代了400个epoch)

2个模型除了在模型B中加入SFAM模块外,其它毫无差异.SFAM模块的代码也会M2Det的完全一致.
自己的一些超参数设置:

  单GPU(1080TI)
  底层VGG16
  batch_size = 16,图片训练尺寸 = 320
  迭代400个epoches,
  初始学习率0.001,后期下降2次,前6个epoch使用了warm up策略.
  新层初始化用的xavier_uniform
  SFAM模块:compress_ratio设置为8,输入维度256/512,输出32/64.不像M2Det是2048那么大.

想问下,在加入SFAM模块后,在训练时,有什么要注意的吗?为什么仅仅加了一个SFAM模块,自己的loss就完全不下降??
麻烦了!

cpu version compile

is the env without CUDA/CUDNN tested?
when building the with cpu version, raise Error:
<The nvcc binary could not be located in your $PATH. Either add it to your path, or set $CUDAHOME>

Reproduce of vgg16_m2det320

I tried to reproduce the result of vgg16_m2det320 twice,
the first time I used the setting in the paper:

lr = [0.002, 0.0002, 0.00002, 0.00002]
COCO = [6, 90, 120, 150]

the second time I used your new setting:

lr = [0.004, 0.002, 0.0004, 0.00004, 0.000004]
COCO = [90, 110, 130, 150, 160]

But both time I got mAP of 22.2, I don't know why.

_gt_roidb.pkl

I am a newcomer, I want to know how _gt_roidb.pkl came.
Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.