Coder Social home page Coder Social logo

denseteacher's Introduction

denseteacher's People

Contributors

mohitburkule avatar zrandomize 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

denseteacher's Issues

question about position regression consistency

I found that there is no difference data augmentation related to coordinate transformation in your code, student model and teacher model use the same coordinate transfrom, so the consistency constraint supervision of position prediction may not be enough. Have you done any relevant experiments?

是否提供模型权重

您好!我打算在mmdetection框架下复现dense teacher,请问能提供模型权重做推理精度对齐吗?

需要比较baseline

请问一下如果我想要在当前实验条件下不使用DenseTeacher得到仅使用FCOS训练的baseline,来比较提升效果应该怎么做呢?

编译错误

在安装cvpods的时候,编译一直出错。各种方法都尝试了,还是不行。请问可以提供您的环境信息吗?

An error has been caught in function '_distributed_worker', process 'SpawnProcess-1' (5890), thread 'MainThread' (139632170628928):

when training the model, i am getting an error, this is the log。

2022-10-11 01:04:28 | INFO | runner:89 - EMA model built!
2022-10-11 01:04:28 | INFO | cvpods.checkpoint.checkpoint:111 - Loading checkpoint from detectron2://ImageNetPretrained/MSRA/R-50.pkl
2022-10-11 01:04:28 | ERROR | cvpods.engine.launch:96 - An error has been caught in function '_distributed_worker', process 'SpawnProcess-1' (5890), thread 'MainThread' (139632170628928):
Traceback (most recent call last):

File "", line 1, in
File "/sdb_dir/liuhaolin/anaconda3/envs/denseteacher/lib/python3.8/multiprocessing/spawn.py", line 116, in spawn_main
exitcode = _main(fd, parent_sentinel)
│ │ └ 4
│ └ 20
└ <function _main at 0x7efea4940310>
File "/sdb_dir/liuhaolin/anaconda3/envs/denseteacher/lib/python3.8/multiprocessing/spawn.py", line 129, in _main
return self._bootstrap(parent_sentinel)
│ │ └ 4
│ └ <function BaseProcess._bootstrap at 0x7efea4b16790>

File "/sdb_dir/liuhaolin/anaconda3/envs/denseteacher/lib/python3.8/multiprocessing/process.py", line 315, in _bootstrap
self.run()
│ └ <function BaseProcess.run at 0x7efea4b2bdc0>

File "/sdb_dir/liuhaolin/anaconda3/envs/denseteacher/lib/python3.8/multiprocessing/process.py", line 108, in run
self._target(*self._args, **self._kwargs)
│ │ │ │ │ └ {}
│ │ │ │ └
│ │ │ └ (<function _distributed_worker at 0x7efddc98ac10>, 0, (<function main at 0x7efddc929ca0>, 2, 2, 0, 'tcp://127.0.0.1:50162', (...
│ │ └
│ └ <function _wrap at 0x7efdf474b8b0>

File "/sdb_dir/liuhaolin/anaconda3/envs/denseteacher/lib/python3.8/site-packages/torch/multiprocessing/spawn.py", line 19, in _wrap
fn(i, *args)
│ │ └ (<function main at 0x7efddc929ca0>, 2, 2, 0, 'tcp://127.0.0.1:50162', (Namespace(clearml=False, dir='.', dist_url='tcp://127....
│ └ 0
└ <function _distributed_worker at 0x7efddc98ac10>

File "/home/liuhaolin/DenseTeacher/cvpods/cvpods/engine/launch.py", line 96, in _distributed_worker
main_func(*args)
│ └ (Namespace(clearml=False, dir='.', dist_url='tcp://127.0.0.1:50162', eval_only=False, machine_rank=0, num_gpus=2, num_machine...
└ <function main at 0x7efddc929ca0>

File "/home/liuhaolin/DenseTeacher/cvpods/tools/train_net.py", line 89, in main
runner.resume_or_load(resume=args.resume)
│ │ │ └ False
│ │ └ Namespace(clearml=False, dir='.', dist_url='tcp://127.0.0.1:50162', eval_only=False, machine_rank=0, num_gpus=2, num_machines...
│ └ <function SemiRunner.resume_or_load at 0x7efddc938d30>
└ <runner.SemiRunner object at 0x7efddc8d8fa0>

File "./runner.py", line 167, in resume_or_load
self.start_iter = (self.checkpointer.resume_or_load(
│ │ │ │ └ <function Checkpointer.resume_or_load at 0x7efdf3537c10>
│ │ │ └ <cvpods.checkpoint.checkpoint.DefaultCheckpointer object at 0x7efcad81b160>
│ │ └ <runner.SemiRunner object at 0x7efddc8d8fa0>
│ └ 0
└ <runner.SemiRunner object at 0x7efddc8d8fa0>

File "/home/liuhaolin/DenseTeacher/cvpods/cvpods/checkpoint/checkpoint.py", line 177, in resume_or_load
return self.load(path)
│ │ └ 'detectron2://ImageNetPretrained/MSRA/R-50.pkl'
│ └ <function Checkpointer.load at 0x7efdf35379d0>
└ <cvpods.checkpoint.checkpoint.DefaultCheckpointer object at 0x7efcad81b160>

File "/home/liuhaolin/DenseTeacher/cvpods/cvpods/checkpoint/checkpoint.py", line 112, in load
assert megfile.smart_isfile(path), "Checkpoint {} not found!".format(path)
│ │ │ └ 'detectron2://ImageNetPretrained/MSRA/R-50.pkl'
│ │ └ 'detectron2://ImageNetPretrained/MSRA/R-50.pkl'
│ └ <function smart_isfile at 0x7efdf358e8b0>
└ <module 'megfile' from '/home/liuhaolin/.local/lib/python3.8/site-packages/megfile/init.py'>

File "/home/liuhaolin/.local/lib/python3.8/site-packages/megfile/smart.py", line 100, in smart_isfile
return SmartPath(path).is_file(followlinks=followlinks)
│ │ └ False
│ └ 'detectron2://ImageNetPretrained/MSRA/R-50.pkl'
└ <class 'megfile.smart_path.SmartPath'>
File "/home/liuhaolin/.local/lib/python3.8/site-packages/megfile/smart_path.py", line 14, in smart_method
return getattr(self.pathlike, name)(*args, **kwargs)
│ │ │ │ └ {'followlinks': False}
│ │ │ └ ()
│ │ └ 'is_file'
│ └ Detectron2Path('ImageNetPretrained/MSRA/R-50.pkl')
└ SmartPath('detectron2://ImageNetPretrained/MSRA/R-50.pkl')

TypeError: is_file() got an unexpected keyword argument 'followlinks'

install errors

Thanks for your interesting work!
I have installed cvpods, and import cvpods success, but converted to coco-p10 directory and run "pods_train --dir ." and got error:

AttributeError: 'SemiRunner' object has no attribute 'angular_update'.
image

what can i do for this error!

Impact of batchsize on performance

I noticed that the batchsize dimension is concatenated together when selecting the top 1% learning region, does this cause the batchsize to have a big impact on performance?

Need some help for experiments on other dataset.

I change some configs and use other dataset. The size of my dataset is relatively small. So I reduce the total iterations to 10k.
For test results, the mAP of denseteacher is much lower than corresponding supervised model(relative to the coco dataset). There may be several factors:

  1. The total iterations are too small for model convergence.
  2. The size of dataset is too small.
  3. The strategy of unlabel image sampling affects a lot.

I do not kown which is the main factor. Can you give me some advice? Here are some logs.

  • 2022-10-07 21:39:25.569 | INFO | cvpods.utils.dump.events:write:253 - eta: 0:18:44 iter: 38780/40000 total_loss: 1.656 loss_cls: 0.143 loss_box_reg: 0.181 loss_quality: 0.426 distill_loss_logits: 0.421 distill_loss_quality: 0.412 distill_loss_deltas: 0.141 fore_ground_sum: 171.450 time: 0.8847 data_time: 0.0075 lr: 0.002500 max_mem: 5055M
  • 2022-10-07 21:39:34.673 | INFO | cvpods.utils.dump.events:write:253 - eta: 0:18:35 iter: 38790/40000 total_loss: 1.792 loss_cls: 0.115 loss_box_reg: 0.158 loss_quality: 0.406 distill_loss_logits: 0.600 distill_loss_quality: 0.416 distill_loss_deltas: 0.174 fore_ground_sum: 175.650 time: 0.8847 data_time: 0.0084 lr: 0.002500 max_mem: 5055M
  • 2022-10-07 21:39:44.712 | INFO | cvpods.utils.dump.events:write:253 - eta: 0:18:26 iter: 38800/40000 total_loss: 1.694 loss_cls: 0.121 loss_box_reg: 0.164 loss_quality: 0.413 distill_loss_logits: 0.508 distill_loss_quality: 0.416 distill_loss_deltas: 0.156 fore_ground_sum: 163.533 time: 0.8847 data_time: 0.0119 lr: 0.002500 max_mem: 5055M

Using a different dataset, how to reset NUM_CLASSES?

I am using a new dataset(not coco or voc) and the num_classes is 20 for my dataset instead of 80 for coco. I already changed num_classes in fcos.py. Yet, the config while training still shows that my model num_classes equals 80.
config
fcos
plz help me.

How to Train to Achieve the Result in the Paper

I trained the model on the dataset COCO-Standard 10%, but I couldn' t reach the result of AP=35.11 given in the paper, and my best result is as follows, What's wrong with me?(I used the provided configuration file without any modifications.)

AP AP50 AP75 APs APm APl
34.519 53.205 37.222 19.698 37.772 43.981

How to save the model weight with the best training effect

hello,
In the training process, how to save the Teacher model weight of the corresponding best_AP according to the highest AP value in the test verification set.
The model weight for the iteration that saved the highest AP was not seen in the original code.

Need for Pascal VOC config file

The released code just include coco config. I wonder if you can give the VOC related code, or just the configuration file is also OK.

I tried to use the configuration about VOC given in the paper,setting VOC 2007 train as labeled data & VOC 2012 train as unlabeled data.But I got an unstable training process.

Set trainer as follow:

│ TRAINER │ {'DISTILL': {'GAMMA': 2.0,
│ │ 'RATIO': 0.01,
│ │ 'SUPPRESS': 'linear',
│ │ 'SUP_WEIGHT': 1,
│ │ 'UNSUP_WEIGHT': 1,
│ │ 'WEIGHTS': {'DELTAS': 1.0, 'LOGITS': 2.0, 'QUALITY': 1.0}},
│ │ 'EMA': {'DECAY_FACTOR': 0.9996, 'START_STEPS': 3000, 'UPDATE_STEPS': 1},
│ │ 'NAME': 'SemiRunner',
│ │ 'SSL': {'BURN_IN_STEPS': 5000}}

Is that right?

Could you help me, please

Could not get results in paper

I run coco-p10 without modification and get AP33.11 which is much lower than 35.11 in paper. I want to know the reason.
By the way, when i check the code in runner.py get_distill_loss:
loss_deltas = (iou_loss(
student_deltas[b_mask],
teacher_deltas[b_mask],
box_mode="ltrb",
loss_type='giou',
reduction="none",
) * teacher_quality[b_mask]).mean()
Here why is teacher_quality[b_mask] not teacher_quality[b_mask].sigmoid()? It is supposed to represent probability so why not use sigmoid?

请问一下Dense teacher提出的DPL是否其实只是针对预测的类别分支?

在图1中,有Dense Pseudo-label 和 Pseudo-box Label两个分支,分别计算了Ldpl损失和Lbox损失,所以Ldpl其实就是对应教师模型输出分类分支后的sigmoid所做的吗?整个模型还是用了NMS来生成伪框监督回归分支的损失计算?
3.3 Dense Pseudo-Label
Since the learning region is selected, unsupervised learning for regression branch can be easily achieved.
3.3中关于回归的分支的叙述较少,上面说由于选择了学习区域,因此回归分支的学习更容易实现,这个更容易实现指的是什么呢?
希望作者能够解答一下
感谢

student和teacher不同数据增强的疑问

作者您好,感谢分享优秀的工作,给了我很多启发。

这两天正在仔细看论文域代码,但是产生了疑问,烦请帮忙解答:

student的图片经过强数据增强,和teacher的弱数据增强并不对应——比如student的图片经过RandCrop后只包含图片的一部分,预测出来的dense预测结果肯定也只包含了这一部分,与teacher预测出来的dense预测结果就无法匹配上了。
即使把teacher的dense预测结果按照student做一样的数据增强的变化(比如把结果按照RandCrop后只取一部分),那teacher的预测结果也会比student少了很多,因为对于teacher来说先当于只取了一部分结果,仍然没法对应上。

烦请作者帮忙解惑,在这种增强不同情况下,是如何匹配teacher的伪框和student的预测的。

problem about regression branch

Hi, thank you for your excellent work. Can you share details about how to do unsupervised learning for regression branch?

在用一个新的数据集。如何改变num_classes?

我在用一个遥感数据集,num_classes只有20,但是config设置里num_classes是80,对应coco数据集,请问如何更改。我已经对fcos.py进行了更改,但是不起作用。训练时的config仍然是80。虽然可以训练到model_iter_0200000.pth,但是仍旧因为category_id=56而报错。
fcos

config

Cannot reproduce the results of the paper

Hi, thanks for your excellent work and the open-source.

I am trying to reproduce the results reported in the paper. Currently, I conduct the experiment of 1% COCO. I only obtained 18.5 AP, but the paper reported 19.64. Also, I use the large-scale jitter, setting the scale range to 400-1200. Still, I only obtained 20.7 AP (22.38 in the paper).

|   AP   |  AP50  |  AP75  |  APs  |  APm   |  APl   |
|:------:|:------:|:------:|:-----:|:------:|:------:|
| 20.679 | 35.090 | 21.424 | 9.386 | 22.590 | 28.191 |

I train the model on 8 3090 GPUs, and I pick the highest AP model of the teacher model.

Here is the full log when I use the large-scale jitter log.txt.

where is the code of applying large-scale jittering

Hi,
Thanks for sharing your amazing projects. The paper mentioned that you used the large-scale jittering for augmentation. Could you please tell me where can I find the code of large scale jittering in this projects?

Where is the implementations for selecting pixels with top k% score?

Hi, I read your paper and I think the author suggests a simple and efficient strategy for semi-supervised object detection.
So I'm figuring out your implementation before experiments on my custom dataset and already read the issue(#19 ).

  1. But I could't find the implementation which selects pixels with top k% score for suppressing low scoring predictions.
    Could you let me know which file has the implementation?

  2. And the paper also experimented the three different strategies to deal with hard negative regions, including "suppressing", "ignoring" and "selecting". Do your implementation include those three options? where could I change the option?

Thank you.

coco-p1 training divergent

I tried to reproduce results under coco-p1 configuration, but training divergent after 40k steps and I got only 14% mAP which is far lower than 19.64%. Could you help me, please

Question about unsup loss.

Here, teacher model and student model respectively adopt different data augment methods. And the strong one uses random crop, which will cause the change in object locations. I'm confused how get_distill_loss works while dense feature maps are not corresponding.

student_logits, student_deltas, student_quality = self.model(unsup_strong, get_data=True)
teacher_logits, teacher_deltas, teacher_quality = self.ema_model.model(unsup_weak, is_teacher=True)
loss_logits = QFLv2(

Regression branch loss

你好,代码中求无监督回归loss的时候,loss_deltas = (iou_loss * teacher_quality[b_mask]).mean(),但是teacher_quality有正有负,求出的loss_deltas也会为负,为什么?

Denseteacher in YOLOX and other YOLOseries

Thank you for your work!Have you tried Denseteacher in YoloX?
I want to try to migrate denseteacher to anchor free YOLO like YOLOX , but the effect is not ideal.Do you have any suggestions?

自有数据集

你好,dense teacher支持在自有数据集上训练吗

There is a gap between the self test results and the official in coco dataset

环境配置
2022-09-22 07:46:31.451 | INFO | cvpods.engine.setup:default_setup:137 - Rank of current process: 0. World size: 8
2022-09-22 07:46:33.296 | INFO | cvpods.engine.setup:default_setup:139 - Environment info:


sys.platform linux
Python 3.8.5 (default, Sep 4 2020, 07:30:14) [GCC 7.3.0]
numpy 1.19.2
cvpods 0.1 @/paddle/SSOD/DenseTeacher/cvpods/cvpods
cvpods compiler GCC 8.2
cvpods CUDA compiler 10.1
cvpods arch flags sm_61
cvpods_ENV_MODULE
PyTorch 1.7.1+cu101 @/root/anaconda3/lib/python3.8/site-packages/torch
PyTorch debug build False
CUDA available True
GPU 0,1,2,3,4,5,6,7 Tesla P40
CUDA_HOME /usr/local/cuda
NVCC Cuda compilation tools, release 10.1, V10.1.243
Pillow 8.0.1
torchvision 0.8.2+cu101 @/root/anaconda3/lib/python3.8/site-packages/torchvision
torchvision arch flags sm_35, sm_50, sm_60, sm_70, sm_75
cv2 4.6.0


PyTorch built with:

  • GCC 7.3
  • C++ Version: 201402
  • Intel(R) Math Kernel Library Version 2020.0.0 Product Build 20191122 for Intel(R) 64 architecture applications
  • Intel(R) MKL-DNN v1.6.0 (Git Hash 5ef631a030a6f73131c77892041042805a06064f)
  • OpenMP 201511 (a.k.a. OpenMP 4.5)
  • NNPACK is enabled
  • CPU capability usage: AVX2
  • CUDA Runtime 10.1
  • NVCC architecture flags: -gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75
  • CuDNN 7.6.3
  • Magma 2.5.2
  • Build settings: BLAS=MKL, BUILD_TYPE=Release, CXX_FLAGS= -Wno-deprecated -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -fopenmp -DNDEBUG -DUSE_FBGEMM -DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK -DUSE_XNNPACK -DUSE_VULKAN_WRAPPER -O2 -fPIC -Wno-narrowing -Wall -Wextra -Werror=return-type -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-unused-local-typedefs -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-psabi -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Werror=format -Wno-stringop-overflow, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, USE_CUDA=ON, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=ON, USE_NNPACK=ON, USE_OPENMP=ON,

config,没有改动:
`from cvpods.configs.fcos_config import FCOSConfig

from augmentations import WeakAug,StrongAug
from dataset import PartialCOCO

_config_dict = dict(
DATASETS=dict(
SUPERVISED=[
(PartialCOCO,dict(
percentage=10,
seed=1,
supervised=True,
sup_file='../COCO_Division/COCO_supervision.txt'
)),
],
UNSUPERVISED=[
(PartialCOCO,dict(
percentage=10,
seed=1,
supervised=False,
sup_file='../COCO_Division/COCO_supervision.txt'
)),
],
TEST=("coco_2017_val",),
),
MODEL=dict(
WEIGHTS="/paddle/SSOD/cvpods/cvpods/R-50.pkl",
RESNETS=dict(DEPTH=50),
FCOS=dict(
QUALITY_BRANCH='iou',
CENTERNESS_ON_REG=True,
NORM_REG_TARGETS=True,
NMS_THRESH_TEST=0.6,
BBOX_REG_WEIGHTS=(1.0, 1.0, 1.0, 1.0),
FOCAL_LOSS_GAMMA=2.0,
FOCAL_LOSS_ALPHA=0.25,
IOU_LOSS_TYPE="giou",
CENTER_SAMPLING_RADIUS=1.5,
OBJECT_SIZES_OF_INTEREST=[
[-1, 64],
[64, 128],
[128, 256],
[256, 512],
[512, float("inf")],
],
NORM_SYNC=True,
),
),
DATALOADER=dict(
NUM_WORKERS=4,
),
SOLVER=dict(
LR_SCHEDULER=dict(
MAX_ITER=180000,
STEPS=(179995, ),
WARMUP_ITERS=1000,
WARMUP_FACTOR=1.0 / 1000,
GAMMA=0.1,
),
OPTIMIZER=dict(
BASE_LR=0.01,
),
IMS_PER_BATCH=16,
CHECKPOINT_PERIOD=5000,
CLIP_GRADIENTS=dict(ENABLED=True)
),
TRAINER=dict(
NAME="SemiRunner",
EMA=dict(
DECAY_FACTOR=0.9996,
UPDATE_STEPS=1,
START_STEPS=3000,
FAKE=False
),
SSL=dict(
BURN_IN_STEPS=5000,
),
DISTILL=dict(
RATIO=0.01,
SUP_WEIGHT=1,
UNSUP_WEIGHT=1,
SUPPRESS='linear',
WEIGHTS=dict(
LOGITS=4.,
DELTAS=1.,
QUALITY=1.,
),
GAMMA=2.
),
# WINDOW_SIZE=1,
),
TEST=dict(
EVAL_PERIOD=2000,
),
INPUT=dict(
AUG=dict(
TRAIN_PIPELINES=dict(
SUPERVISED=(WeakAug,dict(short_edge_length=(640, 672, 704, 736, 768, 800), max_size=1333, sample_style="choice")),
UNSUPERVISED=(StrongAug,)
),
TEST_PIPELINES=[
("ResizeShortestEdge",
dict(short_edge_length=800, max_size=1333, sample_style="choice")),
],
)
),
OUTPUT_DIR='outputs',
GLOBAL=dict(
LOG_INTERVAL=10,
)
)

class CustomFCOSConfig(FCOSConfig):
def init(self):
super(CustomFCOSConfig, self).init()
self._register_configuration(_config_dict)

config = CustomFCOSConfig()`
您好我使用您代码原本的config,环境配置
2022-09-22 07:46:31.451 | INFO | cvpods.engine.setup:default_setup:137 - Rank of current process: 0. World size: 8
2022-09-22 07:46:33.296 | INFO | cvpods.engine.setup:default_setup:139 - Environment info:


sys.platform linux
Python 3.8.5 (default, Sep 4 2020, 07:30:14) [GCC 7.3.0]
numpy 1.19.2
cvpods 0.1 @/paddle/SSOD/DenseTeacher/cvpods/cvpods
cvpods compiler GCC 8.2
cvpods CUDA compiler 10.1
cvpods arch flags sm_61
cvpods_ENV_MODULE
PyTorch 1.7.1+cu101 @/root/anaconda3/lib/python3.8/site-packages/torch
PyTorch debug build False
CUDA available True
GPU 0,1,2,3,4,5,6,7 Tesla P40
CUDA_HOME /usr/local/cuda
NVCC Cuda compilation tools, release 10.1, V10.1.243
Pillow 8.0.1
torchvision 0.8.2+cu101 @/root/anaconda3/lib/python3.8/site-packages/torchvision
torchvision arch flags sm_35, sm_50, sm_60, sm_70, sm_75
cv2 4.6.0


PyTorch built with:

  • GCC 7.3
  • C++ Version: 201402
  • Intel(R) Math Kernel Library Version 2020.0.0 Product Build 20191122 for Intel(R) 64 architecture applications
  • Intel(R) MKL-DNN v1.6.0 (Git Hash 5ef631a030a6f73131c77892041042805a06064f)
  • OpenMP 201511 (a.k.a. OpenMP 4.5)
  • NNPACK is enabled
  • CPU capability usage: AVX2
  • CUDA Runtime 10.1
  • NVCC architecture flags: -gencode;arch=compute_37,code=sm_37;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75
  • CuDNN 7.6.3
  • Magma 2.5.2
  • Build settings: BLAS=MKL, BUILD_TYPE=Release, CXX_FLAGS= -Wno-deprecated -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -fopenmp -DNDEBUG -DUSE_FBGEMM -DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK -DUSE_XNNPACK -DUSE_VULKAN_WRAPPER -O2 -fPIC -Wno-narrowing -Wall -Wextra -Werror=return-type -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-unused-local-typedefs -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-psabi -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Werror=format -Wno-stringop-overflow, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, USE_CUDA=ON, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=ON, USE_NNPACK=ON, USE_OPENMP=ON,

config,没有改动:
`from cvpods.configs.fcos_config import FCOSConfig

from augmentations import WeakAug,StrongAug
from dataset import PartialCOCO

_config_dict = dict(
DATASETS=dict(
SUPERVISED=[
(PartialCOCO,dict(
percentage=10,
seed=1,
supervised=True,
sup_file='../COCO_Division/COCO_supervision.txt'
)),
],
UNSUPERVISED=[
(PartialCOCO,dict(
percentage=10,
seed=1,
supervised=False,
sup_file='../COCO_Division/COCO_supervision.txt'
)),
],
TEST=("coco_2017_val",),
),
MODEL=dict(
WEIGHTS="/paddle/SSOD/cvpods/cvpods/R-50.pkl",
RESNETS=dict(DEPTH=50),
FCOS=dict(
QUALITY_BRANCH='iou',
CENTERNESS_ON_REG=True,
NORM_REG_TARGETS=True,
NMS_THRESH_TEST=0.6,
BBOX_REG_WEIGHTS=(1.0, 1.0, 1.0, 1.0),
FOCAL_LOSS_GAMMA=2.0,
FOCAL_LOSS_ALPHA=0.25,
IOU_LOSS_TYPE="giou",
CENTER_SAMPLING_RADIUS=1.5,
OBJECT_SIZES_OF_INTEREST=[
[-1, 64],
[64, 128],
[128, 256],
[256, 512],
[512, float("inf")],
],
NORM_SYNC=True,
),
),
DATALOADER=dict(
NUM_WORKERS=4,
),
SOLVER=dict(
LR_SCHEDULER=dict(
MAX_ITER=180000,
STEPS=(179995, ),
WARMUP_ITERS=1000,
WARMUP_FACTOR=1.0 / 1000,
GAMMA=0.1,
),
OPTIMIZER=dict(
BASE_LR=0.01,
),
IMS_PER_BATCH=16,
CHECKPOINT_PERIOD=5000,
CLIP_GRADIENTS=dict(ENABLED=True)
),
TRAINER=dict(
NAME="SemiRunner",
EMA=dict(
DECAY_FACTOR=0.9996,
UPDATE_STEPS=1,
START_STEPS=3000,
FAKE=False
),
SSL=dict(
BURN_IN_STEPS=5000,
),
DISTILL=dict(
RATIO=0.01,
SUP_WEIGHT=1,
UNSUP_WEIGHT=1,
SUPPRESS='linear',
WEIGHTS=dict(
LOGITS=4.,
DELTAS=1.,
QUALITY=1.,
),
GAMMA=2.
),
# WINDOW_SIZE=1,
),
TEST=dict(
EVAL_PERIOD=2000,
),
INPUT=dict(
AUG=dict(
TRAIN_PIPELINES=dict(
SUPERVISED=(WeakAug,dict(short_edge_length=(640, 672, 704, 736, 768, 800), max_size=1333, sample_style="choice")),
UNSUPERVISED=(StrongAug,)
),
TEST_PIPELINES=[
("ResizeShortestEdge",
dict(short_edge_length=800, max_size=1333, sample_style="choice")),
],
)
),
OUTPUT_DIR='outputs',
GLOBAL=dict(
LOG_INTERVAL=10,
)
)

class CustomFCOSConfig(FCOSConfig):
def init(self):
super(CustomFCOSConfig, self).init()
self._register_configuration(_config_dict)

config = CustomFCOSConfig()`
您好,我在使用您提供的代码训练10%coco数据集,最好结果只有mAP=32.39,对config和代码没有做任何更改,是我的环境配置存在问题吗,使用8张tesla P40训练。除此之外在1%coco上的自测结果也不尽人意,只有mAP=16.2
d589ac3724ca85749344d479716243ae

problem with prediction consistency

Hi, I notice the input of teacher and student model are different (unsup_strong for student and unsup_weak for teacher). And there are some crop and flip operation in data augmentation.
So will there be some problem with the prediction consistency when directly computing the loss with teacher's ans student's predictions (logits, deltas and quality) ? Or is there any extra transform operations to the predictions in this project?

cocoapi does not handle empty results very well

您好,在运行coco-full时遇到以下bug,请问一下您知道是怎么回事吗?
` File "/root/DenseTeacher/cvpods/cvpods/evaluation/coco_evaluation.py", line 152, in evaluate
self._eval_predictions(set(self._tasks))
│ │ │ └ ('bbox', 'segm')
│ │ └ <cvpods.evaluation.coco_evaluation.COCOEvaluator object at 0x7f3b800ad210>
│ └ <function COCOEvaluator._eval_predictions at 0x7f3caa137830>
└ <cvpods.evaluation.coco_evaluation.COCOEvaluator object at 0x7f3b800ad210>

File "/root/DenseTeacher/cvpods/cvpods/evaluation/coco_evaluation.py", line 238, in _eval_predictions
else None # cocoapi does not handle empty results very well`

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.