{"id":18519808,"url":"https://github.com/lxtgh/decouplesegnets","last_synced_at":"2025-04-07T07:17:30.394Z","repository":{"id":110012115,"uuid":"277441088","full_name":"lxtGH/DecoupleSegNets","owner":"lxtGH","description":"[ECCV-2020]: Improving Semantic Segmentation via Decoupled Body and Edge Supervision","archived":false,"fork":false,"pushed_at":"2022-10-30T09:22:57.000Z","size":520,"stargazers_count":374,"open_issues_count":2,"forks_count":35,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-03-31T06:06:10.925Z","etag":null,"topics":["bdd","camvid","cityscapes","semantic-segmentation"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lxtGH.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-07-06T04:21:17.000Z","updated_at":"2025-03-18T11:46:56.000Z","dependencies_parsed_at":"2023-05-20T16:03:08.628Z","dependency_job_id":null,"html_url":"https://github.com/lxtGH/DecoupleSegNets","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxtGH%2FDecoupleSegNets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxtGH%2FDecoupleSegNets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxtGH%2FDecoupleSegNets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lxtGH%2FDecoupleSegNets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lxtGH","download_url":"https://codeload.github.com/lxtGH/DecoupleSegNets/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247608160,"owners_count":20965953,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bdd","camvid","cityscapes","semantic-segmentation"],"created_at":"2024-11-06T17:17:29.467Z","updated_at":"2025-04-07T07:17:30.373Z","avatar_url":"https://github.com/lxtGH.png","language":"Python","readme":"## (New) Improved Version of DecoupleSegNet for Glass-like object segmentation EBLNet-ICCV-2021 code [link](https://github.com/hehao13/EBLNet) !!\n\n## (New)DecoupleSegNets are also verified to handle the segmentation cases where the boundaries are important for the task. We will release the related code and paper in this repo.\n\n\n## (New) DecoupleSegNets are supported by the [PaddleSeg](https://github.com/PaddlePaddle/PaddleSeg) which has better results !!! Thanks for their work!!!\n\n\n# DecoupleSegNets\nThis repo contains the the implementation of Our ECCV-2020 work: Improving Semantic Segmentation via Decoupled Body and Edge Supervision.\n\nThis is the join work of Peking University, University of Oxford and Sensetime Research. (Much thanks for Sensetimes' GPU server)\n\n\nAny Suggestions/Questions/Pull Requests are welcome.\n\nIt also contains reimplementation of our previous AAAI-2020 work (oral) . \nGFFNet:Gated Fully Fusion for semantic segmentation which also achieves the state-of-the-art results on CityScapes:\n  \n## Decouple SegNets\n![avatar](./fig/teaser.png)\n\n## GFFNet\n![avatar](./fig/gff_model.png)\n\n# DataSet preparation\nDataloaders for Cityscapes, Mapillary, Camvid ,BDD and Kitti are available in [datasets](./datasets). \nDetails of preparing each dataset can be found at [PREPARE_DATASETS.md](https://github.com/lxtGH/DecoupleSegNets/blob/master/DATASETs.md)\n\n## Requirements\n\npytorch \u003e= 1.2.0\napex\nopencv-python\n\n\n# Model Checkpoint\n\n## Pretrained Models\n\nBaidu Pan Link: https://pan.baidu.com/s/1MWzpkI3PwtnEl1LSOyLrLw  4lwf\n\nWider-ResNet-Imagenet Link: https://drive.google.com/file/d/1dGfPvzf4fS0aaSDnw2uahQpnBrUJfRDt/view?usp=sharing\n\n## Trained Models and CKPT\n\nYou can use these ckpts for training decouple models or doing the evaluations for saving both time and computation.\n\nDecoupleSegNet: Baidu Pan Link:\nlink: https://pan.baidu.com/s/191joLpHxSByVKnJu8_w4_Q  password:yg4c\n\n\nGFFNet_Betst: Google Drive:\nlink: https://drive.google.com/file/d/1wPF49PEdYHIvVLIAO5AsiEfc8ZmNkDY5/view?usp=sharing\n\n\n# Training\n\nTo be note that, Our best models(Wider-ResNet-38) are trained on 8 V-100 GPUs with 32GB memory.\n **It is hard to reproduce such best results if you do not have such resources.**\nHowever, our resnet-based methods including fcn, deeplabv3+, pspnet can be trained by 8-1080-TI gpus with batchsize 8.\nOur training contains two steps(Here I give the ):\n\n\n## 1, Train the base model.\n    We found 70-80 epoch is good enough for warm up traning.\n```bash\nsh ./scripts/train/train_cityscapes_ResNet50_deeplab.sh\n```\n\n## 2, Re-Train with our module with lower LR using pretrained models.\n\n\n### For DecoupleSegNets:\n  You can use the pretrained ckpt in previous step.\n  \n```bash\nsh ./scripts/train/train_ciytscapes_W38_decouple.\n\nsh ./scripts/train/train_ciytscapes_ResNet50_deeplab_decouple.sh\n```\n\n# Evaluation\n\n\n## 1, Single-Scale Evaluation\n```bash\nsh ./scripts/evaluate_val/eval_cityscapes_deeplab_r101_decouple.sh \n```\n\n## 2, Multi-Scale Evaluation\n```bash\nsh ./scripts/evaluate_val/eval_cityscapes_deeplab_r101_decouple_ms.sh \n```\n## 3, Evaluate F-score on Segmentation Boundary.(change the path of snapshot)\n```bash\nsh ./scripts/evaluate_boundary_fscore/evaluate_cityscapes_deeplabv3_r101_decouple\n```\n\n# Submission on Cityscapes\n\nYou can submit the results using our checkpoint by running \n\n```bash\nsh ./scripts/submit_tes/submit_cityscapes_WideResNet38_decouple Your_Model_Path Model_Output_Path\n```\n\n# Demo \nHere we give some demo scripts for using our checkpoints.\nYou can change the scripts according to your needs.\n\n```bash\npython ./demo/demo_folder_decouple.py\n```\n\n# Citation\nIf you find this repo is helpful to your research Or our models are useful for your research.\nPlease consider cite our work.\n\n```\n@inproceedings{xiangtl_decouple\n  title     = {Improving Semantic Segmentation via Decoupled Body and Edge Supervision},\n  author    = {Li, Xiangtai and Li, Xia and Zhang, Li and Cheng Guangliang and Shi, Jianping and \n    Lin, Zhouchen and Tong, Yunhai and Tan, Shaohua},\n  booktitle = {ECCV},\n  year = {2020}\n}\n```\n\n```\n@inproceedings{xiangtl_gff\n  title     = {GFF: Gated Fully Fusion for semantic segmentation},\n  author    = {Li, Xiangtai and  Zhao Houlong and Han Lei and Tong Yunhai and Yang Kuiyuan},\n  booktitle = {AAAI},\n  year = {2020}\n}\n```\n\n# Acknowledgement\nThis repo is based on NVIDIA segmentation [repo](https://github.com/NVIDIA/semantic-segmentation). \nWe fully thank their open-sourced code.\n\n\n# License\nMIT License\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flxtgh%2Fdecouplesegnets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flxtgh%2Fdecouplesegnets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flxtgh%2Fdecouplesegnets/lists"}