PyTorch code for ICLR 2021 paper Unbiased Teacher for Semi-Supervised Object Detection

Overview

Unbiased Teacher for Semi-Supervised Object Detection

License: MIT

This is the PyTorch implementation of our paper:
Unbiased Teacher for Semi-Supervised Object Detection
Yen-Cheng Liu, Chih-Yao Ma, Zijian He, Chia-Wen Kuo, Kan Chen, Peizhao Zhang, Bichen Wu, Zsolt Kira, Peter Vajda
International Conference on Learning Representations (ICLR), 2021

[arXiv] [OpenReview] [Project]

Installation

Prerequisites

  • Linux or macOS with Python ≥ 3.6
  • PyTorch ≥ 1.5 and torchvision that matches the PyTorch installation.

Install PyTorch in Conda env

# create conda env
conda create -n detectron2 python=3.6
# activate the enviorment
conda activate detectron2
# install PyTorch >=1.5 with GPU
conda install pytorch torchvision -c pytorch

Build Detectron2 from Source

Follow the INSTALL.md to install Detectron2.

Dataset download

  1. Download COCO dataset
# download images
wget http://images.cocodataset.org/zips/train2017.zip
wget http://images.cocodataset.org/zips/val2017.zip

# download annotations
wget http://images.cocodataset.org/annotations/annotations_trainval2017.zip
  1. Organize the dataset as following:
unbiased_teacher/
└── datasets/
    └── coco/
        ├── train2017/
        ├── val2017/
        └── annotations/
        	├── instances_train2017.json
        	└── instances_val2017.json

Training

  • Train the Unbiased Teacher under 1% COCO-supervision
python train_net.py \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup1_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16
  • Train the Unbiased Teacher under 2% COCO-supervision
python train_net.py \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup2_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16
  • Train the Unbiased Teacher under 5% COCO-supervision
python train_net.py \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup5_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16
  • Train the Unbiased Teacher under 10% COCO-supervision
python train_net.py \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup10_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16

Resume the training

python train_net.py \
      --resume \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup10_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16 MODEL.WEIGHTS <your weight>.pth

Evaluation

python train_net.py \
      --eval-only \
      --num-gpus 8 \
      --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup10_run1.yaml \
       SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16 MODEL.WEIGHTS <your weight>.pth

Model Zoo

Coming soon

FAQ

  1. Q: Using the lower batch size and fewer GPUs cannot achieve the results presented in the paper?
  • A: We train the model with 32 labeled images + 32 unlabeled images per batch for the results presented in the paper, and using the lower batch size leads to lower accuracy. For example, in the 1% COCO-supervision setting, the model trained with 16 labeled images + 16 unlabeled images achieves 19.9 AP as shown in the following table.
Experiment GPUs Batch size per node Batch size AP
8 GPUs/node; 4 nodes 8 labeled imgs + 8 unlabeled imgs 32 labeled img + 32 unlabeled imgs 20.75
8 GPUs/node; 1 node 16 labeled imgs + 16 unlabeled imgs 16 labeled imgs + 16 unlabeled imgs 19.9

Citing Unbiased Teacher

If you use Unbiased Teacher in your research or wish to refer to the results published in the paper, please use the following BibTeX entry.

@inproceedings{liu2021unbiased,
    title={Unbiased Teacher for Semi-Supervised Object Detection},
    author={Liu, Yen-Cheng and Ma, Chih-Yao and He, Zijian and Kuo, Chia-Wen and Chen, Kan and Zhang, Peizhao and Wu, Bichen and Kira, Zsolt and Vajda, Peter},
    booktitle={Proceedings of the International Conference on Learning Representations (ICLR)},
    year={2021},
}

Also, if you use Detectron2 in your research, please use the following BibTeX entry.

@misc{wu2019detectron2,
  author =       {Yuxin Wu and Alexander Kirillov and Francisco Massa and
                  Wan-Yen Lo and Ross Girshick},
  title =        {Detectron2},
  howpublished = {\url{https://github.com/facebookresearch/detectron2}},
  year =         {2019}
}

License

This project is licensed under MIT License, as found in the LICENSE file.

Comments
  • Parameter modification for smaller batch_size

    Parameter modification for smaller batch_size

    Your work is indeed impressive! but how should I modify my parameters for smaller batch size (8)?
    I tried the default settings to train the coco standard dataset but do not get the same result presented in the paper. Thanks a lot!

    opened by bei181 14
  • self.iter restart from zero when I resume a training

    self.iter restart from zero when I resume a training

    Hi everybody, I tried to run a training on a machine with 4 gpus and I had to stop it before the end. When I tried to resume the training with:

    python train_net.py --resume --num-gpus 4 --config myconfig.yaml MODEL.WEIGHTS model_0039999.pth
    

    It looks load last model:

    [05/17 23:19:48 fvcore.common.checkpoint]: [Checkpointer] Loading from output/v1/model_0039999.pth ...
    [05/17 23:19:50 fvcore.common.checkpoint]: Loading optimizer from output/v1/model_0039999.pth ...
    [05/17 23:19:50 fvcore.common.checkpoint]: Loading scheduler from output/v1/model_0039999.pth ...
    [05/17 23:20:47 d2.utils.events]:  eta: 6 days, 8:27:02  iter: 19  total_loss: 0.4911  loss_cls: 0.1124  loss_box_reg: 0.2631  loss_rpn_cls: 0.04196  loss_rpn_loc: 0.06917  time: 1.5732  data_time: 1.5957  lr: 0.005  max_mem: 9390M
    [05/17 23:21:18 d2.utils.events]:  eta: 6 days, 11:02:18  iter: 39  total_loss: 0.4788  loss_cls: 0.1176  loss_box_reg: 0.2795  loss_rpn_cls: 0.03516  loss_rpn_loc: 0.06627  time: 1.5558  data_time: 0.6720  lr: 0.005  max_mem: 11201M
    

    But then, the iter value looks restarting from zero. Is it normal? Because e.g. the configuration BURN_UP_STEP probably is affected by this. Somebody has the same issue?

    opened by hachreak 5
  • How to perform NMS before generating pseudo labels?

    How to perform NMS before generating pseudo labels?

    Hi! Thanks for your work and I am wondering how the NMS can be performed before generating the pseudo label. I conjecture that it might in the function https://github.com/facebookresearch/unbiased-teacher/blob/ba543ed2b87446c79eaf41f93320de246c8eedc2/ubteacher/engine/trainer.py#L319 or https://github.com/facebookresearch/unbiased-teacher/blob/ba543ed2b87446c79eaf41f93320de246c8eedc2/ubteacher/engine/trainer.py#L354 but I cannot find it. Could you please provide some instructions or is there something I am missing?

    opened by SkeletonOne 5
  • I want to make sure I'm right about what I know

    I want to make sure I'm right about what I know

    Hi, Thanks for your paper and code.

    i want to make sure i'm right about what i know. plz, tell me answer about this questions.

    1. is it right that use 2k iters about all {1,5,10,20}% labels in burn-in stage?
    2. when i use batch size = (label = 12, unlabel = 12), it is batch size = 12(only labeled data) in Burn-in stage. Then, it is batch size = (12, 12)(labeled data, unlabeled data) in Student Model. is it right?
    3. In training log, i can see continuous two AP tables. what diff for two tables?

    Thanks!

    opened by yeonsikch 4
  • Easiest way to use this for supervised object detection as baseline?

    Easiest way to use this for supervised object detection as baseline?

    Say, I wanted to compare using 50% labeled dataset (without unlabeled) only for supervised learning. And 50% labeled + 50% unlabeled for SSL. Is there a way to easily do the first one here?

    opened by sarmientoj24 3
  • using  randon select date get more higher result than using COCO_supervision.txt

    using randon select date get more higher result than using COCO_supervision.txt

    by using the COCO_supervision.txt config when using the 10% coco as the label dataset,the results are reproducible, but when i change to the seting of random select data just as https://github.com/facebookresearch/unbiased-teacher/issues/8#issuecomment-808687654, i get more higher result:AP:36.489, under the 10% coco as the label dataset

    opened by happyxuwork 3
  • Nan appears when training

    Nan appears when training

    i set use the default seting as the github, run python train_net.py --num-gpus 8 --config configs/coco_supervision/faster_rcnn_R_50_FPN_sup10_run1.yaml SOLVER.IMG_PER_BATCH_LABEL 16 SOLVER.IMG_PER_BATCH_UNLABEL 16; but from 19 steps ,The following information appears. 20210326-092159(WeLinkPC) is normal? is any config should altert? Looking forward to your reply!

    opened by happyxuwork 3
  • Splits percentage (Quick question - easy to answer)

    Splits percentage (Quick question - easy to answer)

    I see that you use your own seeds (dataseed). I just want to know how you created this file with the seeds? when you say 1%, do you have 1% of every class?

    I just sample 1% of the whole coco-dataset but the performance drops a lot, so, I am assuming that you get 1% per class so you can train with better results. Am I right?

    opened by fabianfallasmoya 2
  • Supervised Loss for Student

    Supervised Loss for Student

    Hello @ycliu93, Thanks for your work.

    I'd just like to confirm whether the student model actually uses the labelled data as part of training along with the pseudo-labelled data. This is because in the paper the diagram only shows strongly augmented data passed into the student model, but in the code there is a forward pass for the student model that also takes labelled data with both weak and strong augmentations. For your references:

    This shows that weakly augmented unlabelled data is for the teacher branch. Screenshot 2022-03-04 at 00 06 47

    This shows that Lsup is from burn-in, and Lunsup is from the supervision of pseudo-labels. Screenshot 2022-03-04 at 00 07 46

    This shows that student model has a forward pass given the labelled data (in which the forward pass is not for the burn-in) Screenshot 2022-03-04 at 00 05 56

    Thanks very much.

    opened by michaelku1 2
  • How to calculate the Pseudo-label accuracy?

    How to calculate the Pseudo-label accuracy?

    Thanks for your good work. When I tried to measure the accuracy of the pseudo labels, I met some problems and wondered how to calculate the accuracy in detail. Could you please give the implementation details and release the code for the pseudo-label accuracy calculations?

    opened by ASAKARUM 2
  • "batch norm layers are not updated as well" for teacher

    Hello! I keep referencing this work because it's a really good resource for SSL.

    I noticed https://github.com/facebookresearch/unbiased-teacher/blob/226f8c4b7b9c714e52f9bf640da7c75343803c52/ubteacher/engine/trainer.py#L515 it's stated that "batch norm layers are not updated as well" for teacher. Why is this the case? From my understanding, I believe batch statistics are indeed updated even under torch.no_grad().

    Also, have you tried setting the teacher to eval mode?

    opened by Divadi 2
  • How can I use pascal VOC as evalutation? Because the default is

    How can I use pascal VOC as evalutation? Because the default is "COCOeval".

    I use my own dataset which is based on coco dataset. Could I output the evaluation results on pascal VOC result? If so, where should I change? Thanks a lot!!

    opened by bliblioscar 0
  • About verification, the accuracy is 0

    About verification, the accuracy is 0

    Hello, when I execute the verification command, the accuracy is 0. But in the process of training, there are scores in the verification. What's the matter?

    command: python train_net.py --eval-only --num-gpus 8 --config configs/Faster-RCNN/coco-standard/faster_rcnn_R_50_FPN_ut2_sup10_run0.yaml --dist-url tcp://127.0.0.1:50158 MODEL.WEIGHTS output/model_0164999.pth SOLVER.IMG_PER_BATCH_LABEL 8 SOLVER.IMG_PER_BATCH_UNLABEL 8

    outputs:

    [07/25 10:04:27 d2.evaluation.evaluator]: Inference done 27/625. Dataloading: 0.0290 s/iter. Inference: 0.1645 s/iter. Eval: 0.0001 s/iter. Total: 0.1937 s/iter. ETA=0:01:55 [07/25 10:04:32 d2.evaluation.evaluator]: Inference done 50/625. Dataloading: 0.0222 s/iter. Inference: 0.1849 s/iter. Eval: 0.0001 s/iter. Total: 0.2073 s/iter. ETA=0:01:59 [07/25 10:04:37 d2.evaluation.evaluator]: Inference done 75/625. Dataloading: 0.0198 s/iter. Inference: 0.1888 s/iter. Eval: 0.0001 s/iter. Total: 0.2094 s/iter. ETA=0:01:55 [07/25 10:04:42 d2.evaluation.evaluator]: Inference done 97/625. Dataloading: 0.0200 s/iter. Inference: 0.1936 s/iter. Eval: 0.0001 s/iter. Total: 0.2142 s/iter. ETA=0:01:53 [07/25 10:04:47 d2.evaluation.evaluator]: Inference done 123/625. Dataloading: 0.0206 s/iter. Inference: 0.1893 s/iter. Eval: 0.0001 s/iter. Total: 0.2105 s/iter. ETA=0:01:45 [07/25 10:04:52 d2.evaluation.evaluator]: Inference done 150/625. Dataloading: 0.0207 s/iter. Inference: 0.1850 s/iter. Eval: 0.0001 s/iter. Total: 0.2063 s/iter. ETA=0:01:37 [07/25 10:04:57 d2.evaluation.evaluator]: Inference done 178/625. Dataloading: 0.0200 s/iter. Inference: 0.1815 s/iter. Eval: 0.0002 s/iter. Total: 0.2026 s/iter. ETA=0:01:30 [07/25 10:05:02 d2.evaluation.evaluator]: Inference done 202/625. Dataloading: 0.0203 s/iter. Inference: 0.1817 s/iter. Eval: 0.0004 s/iter. Total: 0.2033 s/iter. ETA=0:01:25 [07/25 10:05:08 d2.evaluation.evaluator]: Inference done 229/625. Dataloading: 0.0209 s/iter. Inference: 0.1794 s/iter. Eval: 0.0005 s/iter. Total: 0.2016 s/iter. ETA=0:01:19 [07/25 10:05:13 d2.evaluation.evaluator]: Inference done 251/625. Dataloading: 0.0208 s/iter. Inference: 0.1830 s/iter. Eval: 0.0004 s/iter. Total: 0.2050 s/iter. ETA=0:01:16 [07/25 10:05:18 d2.evaluation.evaluator]: Inference done 276/625. Dataloading: 0.0204 s/iter. Inference: 0.1834 s/iter. Eval: 0.0005 s/iter. Total: 0.2051 s/iter. ETA=0:01:11 [07/25 10:05:23 d2.evaluation.evaluator]: Inference done 299/625. Dataloading: 0.0207 s/iter. Inference: 0.1843 s/iter. Eval: 0.0005 s/iter. Total: 0.2063 s/iter. ETA=0:01:07 [07/25 10:05:28 d2.evaluation.evaluator]: Inference done 326/625. Dataloading: 0.0211 s/iter. Inference: 0.1827 s/iter. Eval: 0.0005 s/iter. Total: 0.2050 s/iter. ETA=0:01:01 [07/25 10:05:33 d2.evaluation.evaluator]: Inference done 350/625. Dataloading: 0.0213 s/iter. Inference: 0.1836 s/iter. Eval: 0.0005 s/iter. Total: 0.2060 s/iter. ETA=0:00:56 [07/25 10:05:39 d2.evaluation.evaluator]: Inference done 374/625. Dataloading: 0.0212 s/iter. Inference: 0.1843 s/iter. Eval: 0.0005 s/iter. Total: 0.2066 s/iter. ETA=0:00:51 [07/25 10:05:44 d2.evaluation.evaluator]: Inference done 398/625. Dataloading: 0.0212 s/iter. Inference: 0.1847 s/iter. Eval: 0.0004 s/iter. Total: 0.2070 s/iter. ETA=0:00:46 [07/25 10:05:49 d2.evaluation.evaluator]: Inference done 425/625. Dataloading: 0.0214 s/iter. Inference: 0.1835 s/iter. Eval: 0.0004 s/iter. Total: 0.2060 s/iter. ETA=0:00:41 [07/25 10:05:54 d2.evaluation.evaluator]: Inference done 455/625. Dataloading: 0.0213 s/iter. Inference: 0.1811 s/iter. Eval: 0.0004 s/iter. Total: 0.2035 s/iter. ETA=0:00:34 [07/25 10:05:59 d2.evaluation.evaluator]: Inference done 485/625. Dataloading: 0.0216 s/iter. Inference: 0.1789 s/iter. Eval: 0.0004 s/iter. Total: 0.2015 s/iter. ETA=0:00:28 [07/25 10:06:04 d2.evaluation.evaluator]: Inference done 509/625. Dataloading: 0.0216 s/iter. Inference: 0.1793 s/iter. Eval: 0.0004 s/iter. Total: 0.2018 s/iter. ETA=0:00:23 [07/25 10:06:09 d2.evaluation.evaluator]: Inference done 529/625. Dataloading: 0.0219 s/iter. Inference: 0.1809 s/iter. Eval: 0.0004 s/iter. Total: 0.2038 s/iter. ETA=0:00:19 [07/25 10:06:14 d2.evaluation.evaluator]: Inference done 554/625. Dataloading: 0.0220 s/iter. Inference: 0.1810 s/iter. Eval: 0.0004 s/iter. Total: 0.2040 s/iter. ETA=0:00:14 [07/25 10:06:20 d2.evaluation.evaluator]: Inference done 577/625. Dataloading: 0.0222 s/iter. Inference: 0.1816 s/iter. Eval: 0.0004 s/iter. Total: 0.2047 s/iter. ETA=0:00:09 [07/25 10:06:25 d2.evaluation.evaluator]: Inference done 606/625. Dataloading: 0.0223 s/iter. Inference: 0.1802 s/iter. Eval: 0.0004 s/iter. Total: 0.2034 s/iter. ETA=0:00:03 [07/25 10:06:27 d2.evaluation.evaluator]: Total inference time: 0:02:05.097037 (0.201769 s / iter per device, on 8 devices) [07/25 10:06:27 d2.evaluation.evaluator]: Total inference pure compute time: 0:01:49 (0.177313 s / iter per device, on 8 devices) [07/25 10:06:33 d2.evaluation.coco_evaluation]: Preparing results for COCO format ... [07/25 10:06:33 d2.evaluation.coco_evaluation]: Saving results to ./output/inference/coco_instances_results.json [07/25 10:06:33 d2.evaluation.coco_evaluation]: Evaluating predictions with unofficial COCO API... Loading and preparing results... DONE (t=0.05s) creating index... index created! [07/25 10:06:34 d2.evaluation.fast_eval_api]: Evaluate annotation type bbox [07/25 10:06:49 d2.evaluation.fast_eval_api]: COCOeval_opt.evaluate() finished in 15.41 seconds. [07/25 10:06:49 d2.evaluation.fast_eval_api]: Accumulating evaluation results... [07/25 10:06:51 d2.evaluation.fast_eval_api]: COCOeval_opt.accumulate() finished in 1.58 seconds. Average Precision (AP) @[ IoU=0.50:0.95 | area= all | maxDets=100 ] = 0.000 Average Precision (AP) @[ IoU=0.50 | area= all | maxDets=100 ] = 0.000 Average Precision (AP) @[ IoU=0.75 | area= all | maxDets=100 ] = 0.000 Average Precision (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = 0.000 Average Precision (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = 0.000 Average Precision (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets= 1 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets= 10 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area= all | maxDets=100 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = 0.000 Average Recall (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.000 [07/25 10:06:51 d2.evaluation.coco_evaluation]: Evaluation results for bbox: | AP | AP50 | AP75 | APs | APm | APl | |:-----:|:------:|:------:|:-----:|:-----:|:-----:| | 0.000 | 0.000 | 0.000 | 0.000 | 0.000 | 0.000 | [07/25 10:06:51 d2.evaluation.coco_evaluation]: Per-category bbox AP: | category | AP | category | AP | category | AP | |:--------------|:------|:-------------|:------|:---------------|:------| | person | 0.000 | bicycle | 0.000 | car | 0.000 | | motorcycle | 0.000 | airplane | 0.000 | bus | 0.000 | | train | 0.000 | truck | 0.000 | boat | 0.000 | | traffic light | 0.000 | fire hydrant | 0.000 | stop sign | 0.000 | | parking meter | 0.000 | bench | 0.000 | bird | 0.000 | | cat | 0.000 | dog | 0.000 | horse | 0.000 | | sheep | 0.000 | cow | 0.000 | elephant | 0.000 | | bear | 0.000 | zebra | 0.000 | giraffe | 0.000 | | backpack | 0.000 | umbrella | 0.000 | handbag | 0.000 | | tie | 0.000 | suitcase | 0.000 | frisbee | 0.000 | | skis | 0.000 | snowboard | 0.000 | sports ball | 0.000 | | kite | 0.000 | baseball bat | 0.000 | baseball glove | 0.000 | | skateboard | 0.000 | surfboard | 0.000 | tennis racket | 0.000 | | bottle | 0.000 | wine glass | 0.000 | cup | 0.000 | | fork | 0.000 | knife | 0.000 | spoon | 0.000 | | bowl | 0.000 | banana | 0.000 | apple | 0.000 | | sandwich | 0.000 | orange | 0.000 | broccoli | 0.000 | | carrot | 0.000 | hot dog | 0.000 | pizza | 0.016 | | donut | 0.000 | cake | 0.000 | chair | 0.000 | | couch | 0.000 | potted plant | 0.000 | bed | 0.000 | | dining table | 0.000 | toilet | 0.000 | tv | 0.000 | | laptop | 0.000 | mouse | 0.000 | remote | 0.000 | | keyboard | 0.000 | cell phone | 0.000 | microwave | 0.000 | | oven | 0.000 | toaster | 0.000 | sink | 0.000 | | refrigerator | 0.000 | book | 0.000 | clock | 0.000 | | vase | 0.000 | scissors | 0.000 | teddy bear | 0.000 | | hair drier | 0.000 | toothbrush | 0.000 | | | [07/25 10:06:52 d2.engine.defaults]: Evaluation results for coco_2017_val in csv format: [07/25 10:06:52 d2.evaluation.testing]: copypaste: Task: bbox [07/25 10:06:52 d2.evaluation.testing]: copypaste: AP,AP50,AP75,APs,APm,APl [07/25 10:06:52 d2.evaluation.testing]: copypaste: 0.0002,0.0003,0.0003,0.0000,0.0000,0.0002

    opened by mary-0830 0
  • Experiments without EMA and focal loss

    Experiments without EMA and focal loss

    Hi Thanks for wonderful repo. I have implemented it on custom dataset.

    I have a question, how to implement the model without EMA and focal loss? A hint will be appreciated.

    opened by Mansoor-at 0
  • Data splits in form of COCO image ids

    Data splits in form of COCO image ids

    Splits as Image ID lists are more stable and reusable than image indices (as image indices may change depending on pre-filtering of the dataset).

    Are image indices sampled after any filtering or before filtering? (e.g. difficult images or crowd images)

    Thanks!

    opened by vadimkantorov 0
  • Random crops enabled?

    Random crops enabled?

    Hi @ycliu93!

    Are random crops enabled as part of augmentation pipeline?

    In other words, is cfg.INPUT.CROP.ENABLED set to True at https://github.com/facebookresearch/unbiased-teacher/blob/ba543ed2b87446c79eaf41f93320de246c8eedc2/ubteacher/data/dataset_mapper.py#L38 ?

    Right now it seems to me that it's disabled by default in detectron2 standard config and is not enabled anywhere else in unbiased-teacher

    Thank you!

    opened by vadimkantorov 2
Hybrid CenterNet - Hybrid-supervised object detection / Weakly semi-supervised object detection

Hybrid-Supervised Object Detection System Object detection system trained by hybrid-supervision/weakly semi-supervision (HSOD/WSSOD): This project is

null 5 Dec 10, 2022
[ICLR 2021 Spotlight Oral] "Undistillable: Making A Nasty Teacher That CANNOT teach students", Haoyu Ma, Tianlong Chen, Ting-Kuei Hu, Chenyu You, Xiaohui Xie, Zhangyang Wang

Undistillable: Making A Nasty Teacher That CANNOT teach students "Undistillable: Making A Nasty Teacher That CANNOT teach students" Haoyu Ma, Tianlong

VITA 71 Dec 28, 2022
CVPR2022 paper "Dense Learning based Semi-Supervised Object Detection"

[CVPR2022] DSL: Dense Learning based Semi-Supervised Object Detection DSL is the first work on Anchor-Free detector for Semi-Supervised Object Detecti

Bhchen 69 Dec 8, 2022
This is an unofficial implementation of the paper “Student-Teacher Feature Pyramid Matching for Unsupervised Anomaly Detection”.

This is an unofficial implementation of the paper “Student-Teacher Feature Pyramid Matching for Unsupervised Anomaly Detection”.

haifeng xia 32 Oct 26, 2022
Official Pytorch implementation of "Unbiased Classification Through Bias-Contrastive and Bias-Balanced Learning (NeurIPS 2021)

Unbiased Classification Through Bias-Contrastive and Bias-Balanced Learning (NeurIPS 2021) Official Pytorch implementation of Unbiased Classification

Youngkyu 17 Jan 1, 2023
Pytorch implementation of the AAAI 2022 paper "Cross-Domain Empirical Risk Minimization for Unbiased Long-tailed Classification"

[AAAI22] Cross-Domain Empirical Risk Minimization for Unbiased Long-tailed Classification We point out the overlooked unbiasedness in long-tailed clas

PatatiPatata 28 Oct 18, 2022
[ICCV 2021] Released code for Causal Attention for Unbiased Visual Recognition

CaaM This repo contains the codes of training our CaaM on NICO/ImageNet9 dataset. Due to my recent limited bandwidth, this codebase is still messy, wh

Wang Tan 66 Dec 31, 2022
Seach Losses of our paper 'Loss Function Discovery for Object Detection via Convergence-Simulation Driven Search', accepted by ICLR 2021.

CSE-Autoloss Designing proper loss functions for vision tasks has been a long-standing research direction to advance the capability of existing models

Peidong Liu(刘沛东) 54 Dec 17, 2022
[CVPR 2021] MiVOS - Mask Propagation module. Reproduced STM (and better) with training code :star2:. Semi-supervised video object segmentation evaluation.

MiVOS (CVPR 2021) - Mask Propagation Ho Kei Cheng, Yu-Wing Tai, Chi-Keung Tang [arXiv] [Paper PDF] [Project Page] [Papers with Code] This repo impleme

Rex Cheng 106 Jan 3, 2023
Semi-Supervised Learning, Object Detection, ICCV2021

End-to-End Semi-Supervised Object Detection with Soft Teacher By Mengde Xu*, Zheng Zhang*, Han Hu, Jianfeng Wang, Lijuan Wang, Fangyun Wei, Xiang Bai,

Microsoft 789 Dec 27, 2022
Instant-Teaching: An End-to-End Semi-Supervised Object Detection Framework

This repo is the official implementation of "Instant-Teaching: An End-to-End Semi-Supervised Object Detection Framework". @inproceedings{zhou2021insta

null 34 Dec 31, 2022
Data-Uncertainty Guided Multi-Phase Learning for Semi-supervised Object Detection

An official implementation of paper Data-Uncertainty Guided Multi-Phase Learning for Semi-supervised Object Detection

null 11 Nov 23, 2022
Group R-CNN for Point-based Weakly Semi-supervised Object Detection (CVPR2022)

Group R-CNN for Point-based Weakly Semi-supervised Object Detection (CVPR2022) By Shilong Zhang*, Zhuoran Yu*, Liyang Liu*, Xinjiang Wang, Aojun Zhou,

Shilong Zhang 129 Dec 24, 2022
Toward Spatially Unbiased Generative Models (ICCV 2021)

Toward Spatially Unbiased Generative Models Implementation of Toward Spatially Unbiased Generative Models (ICCV 2021) Overview Recent image generation

Jooyoung Choi 88 Dec 1, 2022
Simple Tensorflow implementation of Toward Spatially Unbiased Generative Models (ICCV 2021)

Spatial unbiased GANs — Simple TensorFlow Implementation [Paper] : Toward Spatially Unbiased Generative Models (ICCV 2021) Abstract Recent image gener

Junho Kim 16 Apr 15, 2022
Official PyTorch implementation of "ArtFlow: Unbiased Image Style Transfer via Reversible Neural Flows"

ArtFlow Official PyTorch implementation of the paper: ArtFlow: Unbiased Image Style Transfer via Reversible Neural Flows Jie An*, Siyu Huang*, Yibing

null 123 Dec 27, 2022
SSD: A Unified Framework for Self-Supervised Outlier Detection [ICLR 2021]

SSD: A Unified Framework for Self-Supervised Outlier Detection [ICLR 2021] Pdf: https://openreview.net/forum?id=v5gjXpmR8J Code for our ICLR 2021 pape

Princeton INSPIRE Research Group 113 Nov 27, 2022
TF2 implementation of knowledge distillation using the "function matching" hypothesis from the paper Knowledge distillation: A good teacher is patient and consistent by Beyer et al.

FunMatch-Distillation TF2 implementation of knowledge distillation using the "function matching" hypothesis from the paper Knowledge distillation: A g

Sayak Paul 67 Dec 20, 2022
Official pytorch code for SSC-GAN: Semi-Supervised Single-Stage Controllable GANs for Conditional Fine-Grained Image Generation(ICCV 2021)

SSC-GAN_repo Pytorch implementation for 'Semi-Supervised Single-Stage Controllable GANs for Conditional Fine-Grained Image Generation'.PDF SSC-GAN:Sem

tyty 4 Aug 28, 2022