HRNet / HRNet-Semantic-Segmentation

The OCR approach is rephrased as Segmentation Transformer: https://arxiv.org/abs/1909.11065. This is an official implementation of semantic segmentation for HRNet. https://arxiv.org/abs/1908.07919
Other
3.09k stars 682 forks source link

mIou=0.5 bestIou=0.5 when val #237

Open shantzhou opened 2 years ago

shantzhou commented 2 years ago

the valid miou=0.5 best_iou = 0.5 when I train my own dataset in every epoch

gulraizk94 commented 2 years ago

Follow these steps. Label file should not contain any value greater than classes-1. Classes should be mentioned in config file. you should update "self.label_mapping = {-1: ignore_label, 0: 0, 1: 1}" in the dataset/cityspaces.py

shantzhou commented 2 years ago

I use cocostuff config on my own dataset, the pixel of my label image :  0:background 1:human .   and self.maaping is 「0,1」 config.numclasses:2  but meaniu and bestiou always 0.5

发自我的iPhone

------------------ Original ------------------ From: gulraizk94 @.> Date: Fri,Aug 20,2021 8:25 PM To: HRNet/HRNet-Semantic-Segmentation @.> Cc: Delete @.>, Author @.> Subject: Re: [HRNet/HRNet-Semantic-Segmentation] mIou=0.5 bestIou=0.5 when val (#237)

gulraizk94 commented 2 years ago

Try using cityspaces with same configuration.

shantzhou commented 2 years ago

Okay,I will try it. Thank u very much. best wishes

发自我的iPhone

------------------ Original ------------------ From: gulraizk94 @.> Date: Fri,Aug 20,2021 8:45 PM To: HRNet/HRNet-Semantic-Segmentation @.> Cc: Delete @.>, Author @.> Subject: Re: [HRNet/HRNet-Semantic-Segmentation] mIou=0.5 bestIou=0.5 when val (#237)

shantzhou commented 2 years ago

anchor question: I use cityspaces with same configuration. I set config.TRAIN.BATCH_SIZE_GPU >1, config.TSET.BATCH_SIZE_GPU =1. train is normal, but the validate is error.  the validate only work in  config.TRAIN.BATCH_SIZE_GPU =1. it seems that config.TSET.BATCH_SIZE_GPU doesn't work in validate,  the validate use config.TRAIN.BATCH_SIZE_GPU ?

------------------ 原始邮件 ------------------ 发件人: "HRNet/HRNet-Semantic-Segmentation" @.>; 发送时间: 2021年8月20日(星期五) 晚上8:45 @.>; 抄送: "Shente @.**@.>; 主题: Re: [HRNet/HRNet-Semantic-Segmentation] mIou=0.5 bestIou=0.5 when val (#237)

Try using cityspaces with same configuration.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

shantzhou commented 2 years ago

1.I have found that you use the train_batch_size_gpu in testloader in tools/train.py.  2.you resize image and label in function multi_scale_aug, but multi_scale is false in Test.  It leads to multi_sacle must be ture when test.batch_size_gpu > 1

------------------ 原始邮件 ------------------ 发件人: "HRNet/HRNet-Semantic-Segmentation" @.>; 发送时间: 2021年8月20日(星期五) 晚上8:45 @.>; 抄送: "Shente @.**@.>; 主题: Re: [HRNet/HRNet-Semantic-Segmentation] mIou=0.5 bestIou=0.5 when val (#237)

Try using cityspaces with same configuration.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android.

gulraizk94 commented 2 years ago

If your training is successful, kindly create another issue for validation.

woyaochiputao commented 7 months ago

Follow these steps. Label file should not contain any value greater than classes-1. Classes should be mentioned in config file. you should update "self.label_mapping = {-1: ignore_label, 0: 0, 1: 1}" in the dataset/cityspaces.py

excuse me,I encountered the same problem mentioned above and followed your steps, but the problem still occurred. the valid miou=0.5 best_iou = 0.5 when I train my own dataset in every epoch