Giter Site home page Giter Site logo

mkang315 / rcs-yolo Goto Github PK

View Code? Open in Web Editor NEW
62.0 4.0 10.0 258.62 MB

Official implementation of "RCS-YOLO: A Fast and High-Accuracy Object Detector for Brain Tumor Detection".

License: GNU General Public License v3.0

Python 99.47% Shell 0.38% Dockerfile 0.15%
brain-tumor-detection computer-vision convolutional-neural-networks deep-learning deep-neural-networks medical-image-analysis object-detection reparameterization yolo br35h-brain-tumor-detection-2020 panet repvgg-model shufflenet vovnet repconv-model medical-image-computing medical-image-dataset medical-image-detection medical-image-processing

rcs-yolo's Introduction

Official RCS-YOLO

This is the source code for the paper titled "RCS-YOLO: A Fast and High-Accuracy Object Detector for Brain Tumor Detection" published in the Proceedings of the 26th International Conference on Medical Image Computing and Computer Assisted Intervention (MICCAI 2023), of which I am the first author. The paper is available to download from Springer or arXiv.

Model

The model configuration (i.e., network construction) file is rcs-yolo.yaml (2 heads) or rcs3-yolo.yaml (3 heads) in the directory ./cfg/training/. The RepVGG/RepConv ShuffleNet based One-Shot Aggregation (RCS-OSA) module file is rcsosa.py in the directory ./models/, which is the unique module we proposed.

Recommended dependencies:

Python <= 3.8
Torch <= 1.7.1
CUDA <= 11.1

Training

The hyperparameter setting file is hyp_training.yaml in the directory ./data/.

Single GPU training
python train.py --workers 8 --device 0 --batch-size 32 --data data/br35h.yaml --img 640 640 --cfg cfg/training/rcs-yolo.yaml --weights '' --name rcs-yolo --hyp data/hyp_training.yaml
Multiple GPU training
python -m torch.distributed.launch --nproc_per_node 4 --master_port 9527 train.py --workers 8 --device 0,1,2,3 --sync-bn --batch-size 128 --data data/br35h.yaml --img 640 640 --cfg cfg/training/rcs-yolo.yaml --weights '' --name rcs-yolo --hyp data/hyp_training.yaml

Testing

The model weights we pretrained on the brain tumor detection was saved as best.pt in the directory ./runs/train/exp/weights/.

python test.py --data data/br35h.yaml --img 640 --batch 32 --conf 0.001 --iou 0.65 --device 0 --weights runs/train/exp/weights/best.pt --name val

Evaluation

We trained and evaluated RCS-YOLO on the dataset Br35H :: Brain Tumor Detection 2020. The .txt format annotations in the folder dataset-Br35H are coverted from original json format. We used 500 images of which in the ’traindata’ folder were selected as the training set, while the other 201 images in the ’valdata’ folder as the testing set.

The screenshots of evaluation results were saved in the directory ./runs/val/.

Ablation Study

The files train_repvgg-csp.py and https://test_repvgg-csp.py are used for an ablation study of the comparison network repvgg-csp.yaml in the directory ./cfg/ablation/.

Suggested Citation

Please cite our paper if you use code from this repository:

Plain Text

  • Springer Reference Style
    Kang, M., Ting, C.-M., Ting, F.F., Phan, R.C.-W.: RCS-YOLO: a fast and high-accuracy object detector for brain tumor detection. In: Greenspan, H., et al. (eds.) MICCAI 2023. LNCS, vol. 14223, 600–610. Springer, Cham (2023). https://doi.org/10.1007/978-3-031-43901-8_57
    NOTE: MICCAI conference proceedings are part of the book series LNCS in which Springer's format for bibliographical references is strictly enforced. This is important, for instance, when citing previous MICCAI proceedings. LNCS stands for Lecture Notes in Computer Science.

  • Nature Reference Style
    Kang, M., Ting, C.-M., Ting, F. F. & Phan, R. C.-W. RCS-YOLO: a fast and high-accuracy object detector for brain tumor detection. In Medical Image Computing and Computer-Assisted Intervention – MICCAI 2023: 26th International Conference, Vancouver, Canada, October 8–12, 2023, Proceedings, Part IV (eds. Greenspan, H. et al.) 600–610 (Springer, 2023).

  • IEEE Reference Style
    M. Kang, C.-M. Ting, F. F. Ting, and R. C.-W. Phan, "Rcs-yolo: A fast and high-accuracy object detector for brain tumor detection," in Proc. Int. Conf. Med. Image Comput. Comput. Assist. Interv. (MICCAI), Vancouver, BC, Canada, Oct. 8–12, 2023, 600–610.
    NOTE: City of Conf., Abbrev. State, Country, Month & day(s) are optional.

  • Elsevier Reference Style
    M. Kang, C.-M. Ting, F.F. Ting, R.C.-W. Phan, RCS-YOLO: a fast and high-accuracy object detector for brain tumor detection, in: H. Greenspan, A. Madabhushi, P. Mousavi, S. Salcudean, J. Duncan, T. Syeda-Mahmood, et al. (Eds.), Proceedings of the 26th International Conference on Medical Image Computing and Computer Assisted Intervention (MICCAI), 8–12 October 2023, Vancouver, BC, Canada, Springer, Cham, 2023, pp. 600–610.
    NOTE: Day(s) Month Year, City, Abbrev. State, Country of Conference, Publiser, and Place of Publication are optional.

BibTeX Format

\begin{thebibliography}{1}
\bibitem{Kang23Rcsyolo} Kang, M., Ting, C.-M., Ting, F.F., Phan, R.C.-W.: RCS-YOLO: a fast and high-accuracy object detector for brain tumor detection. In: Greenspan, H., et al. (eds.) MICCAI 2023. LNCS, vol. 14223, 600--610. Springer, Cham (2023). {\UrlFont https://doi.org/10.1007/978-3-031-43901-8\_57}
\end{thebibliography}
@inproceedings{Kang23Rcsyolo,
  author = "Kang, Ming and Ting, Chee-Ming and Ting, Fung Fung and Phan, Rapha{\"e}l C.-W.",
  title = "RCS-YOLO: a fast and high-accuracy object detector for brain tumor detection",
  editor = "Greenspan, Hayit and et al.",
  booktitle = "Medical Image Computing and Computer-Assisted Intervention – MICCAI 2023: 26th International Conference, Vancouver, Canada, October 8--12, 2023, Proceedings, Part ?",
  series = "Lecture Notes in Computer Science (LNCS)",
  volume = "14223",
  pages = "600--610",
  publisher = "Springer",
  address = "Cham",
  year = "2023",
  doi= "10.1007/978-3-031-43901-8_57",
  url = "https://doi.org/10.1007/978-3-031-43901-8_57"
}
@inproceedings{Kang23Rcsyolo,
  author = "Ming Kang and Chee-Ming Ting and Fung Fung Ting and Rapha{\"e}l C.-W. Phan",
  title = "Rcs-yolo: A fast and high-accuracy object detector for brain tumor detection",
  booktitle = "Proc. Int. Conf. Med. Image Comput. Comput. Assist. Interv. (MICCAI)",
  address = "Vancouver, BC, Canada, Oct. 8--12",
  pages = "600--610",
  year = "2023",
}

NOTE: Please remove some optional BibTeX fields, for example, series, volume, address, url and so on, while the LaTeX compiler produces an error. Author names may be manually modified if not automatically abbreviated by the compiler under the control of the .bst file if applicable which defines bibliography/reference style. Kang23Rcsyolo could be b1, bib1, or ref1 when references appear in numbered style in which they are cited. The quotation mark pair "" in the field could be replaced by the brace {}.

License

RCS-YOLO is released under the GNU General Public License v3.0. Please see the LICENSE file for more information.

Copyright Notice

Many utility codes of our project base on the codes of YOLOv7, RepVGG, ShuffleNet, and VoVNetV2 repositories.

rcs-yolo's People

Contributors

mkang315 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

Watchers

 avatar  avatar  avatar  avatar

rcs-yolo's Issues

A videographic Demonstration on how to execute the code

Hello,
I have executed the code many times but I still can't figure out where I am going wrong. When I run train.py it creates runs/exp/weights, but there are no best.pt and las.pt files in that. Please help me on how to execute the code from scratch

请问RCS-OSA模块替换YOLOv5中的C3模块是否可以提升检测速度?

首先非常感谢您的工作!在您的论文中提到在RCS-YOLO、RepVGG-CSP的消融实验,想请问一下是否是在相同的位置采用BottleneckCSPC、RCS-OSA两个模块进行实验对比?如果是我认为的这样,BottleneckCSPC仅比C3模块多一个conv1x1,那在YOLOv5中,采用RCS-OSA替换C3模块应该也可以提升模型的检测性能。请问您是否做过RCS-OSA有效性的验证实验?该模块是否能提升检测速度?

Missing Model Weights for Reproduction

Thanks to the authors for the interesting work and for sharing your code.

I'd love to reproduce the results presented at MICCAI23. However, I couldn't find best.pt following the link from your documentation:

The model weights we pretrained on the brain tumor detection was saved as best.pt in the directory ./runs/train/exp/weights/.

Can you point me to the correct folder for the trained weights?

Thx!

The model cannot complete the detection.

Hello, I encountered the issue shown in the image below while reproducing your work. I used the data you provided, but it seems that the model cannot complete the training properly. What could be the reason for this?
4dbb8091babaa5fcb68e3d1eb5ecda9

pt转trt后为什么速度提升不大?

pt模型下,在YOLOv5中加了rcsosa模块后比原始yolov5精度高、速度快;
但转成tensorrt后,速度比原始yolov5慢很多,请问是什么原因?

The result of training is very poor.

According to the requirements in the paper, under the conditions of batch_size = 8 and epochs = 150, the result trained in the train.py file is very poor. There is no default training weight file in the train.py file. I don't know if this is the reason why my training result is very unsatisfactory. Could the author please answer me?
微信图片_20240506135833
微信图片_20240506135905

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.