{"action":"created","issue":{"url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/4","repository_url":"https://api.github.com/repos/ooooverflow/BiSeNet","labels_url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/4/comments","events_url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/4/events","html_url":"https://github.com/ooooverflow/BiSeNet/issues/4","id":387635069,"node_id":"MDU6SXNzdWUzODc2MzUwNjk=","number":4,"title":"Wrong label for Seq05VD_f02610_L.png","user":{"login":"hubutui","id":2948593,"node_id":"MDQ6VXNlcjI5NDg1OTM=","avatar_url":"https://avatars2.githubusercontent.com/u/2948593?v=4","gravatar_id":"","url":"https://api.github.com/users/hubutui","html_url":"https://github.com/hubutui","followers_url":"https://api.github.com/users/hubutui/followers","following_url":"https://api.github.com/users/hubutui/following{/other_user}","gists_url":"https://api.github.com/users/hubutui/gists{/gist_id}","starred_url":"https://api.github.com/users/hubutui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hubutui/subscriptions","organizations_url":"https://api.github.com/users/hubutui/orgs","repos_url":"https://api.github.com/users/hubutui/repos","events_url":"https://api.github.com/users/hubutui/events{/privacy}","received_events_url":"https://api.github.com/users/hubutui/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-12-05T08:00:15Z","updated_at":"2018-12-06T09:55:50Z","closed_at":null,"author_association":"NONE","body":"Hi, I convert label from RGB mode to 'P' mode based on `class_dict.csv`, and found there are some points/coord with wrong label, aka its color is out of color defined in `class_dict.csv`. Here is how I convert RGB mode to 'P' mode and check label:\r\n```python\r\nfrom PIL import Image\r\nfrom utils import get_label_info\r\n\r\nlabelinfo = get_label_info(csvfile)\r\npalette = []\r\nfor key in labelinfo:\r\n    for item in labelinfo[key]:\r\n        palette.append(item)\r\n\r\nref_image = Image.new(mode='P', size=(1, 1))\r\nref_image.putpalette(palette)\r\n\r\nimg_rgb = Image.open('rgb_mode.png')\r\nimg_p = img_rgb.quantize(palette=ref_image)\r\n\r\nimg_p_wrong = img_p[img > 31]\r\nimg_rgb_wrong = img_rgb[img > 31]\r\n```\r\nI'm not sure how to deal with this image, currently I simply remove it out of my training/val/testing. After convert RGB mode to 'P' mode, I don't need to use one hot encoding for label anymore. It seems that the one hot encoding & decoding slow down training speed.\r\n\r\nAnd, the code you calculating accuracy seems weird, https://github.com/ooooverflow/BiSeNet/blob/master/utils.py#L103, `pred` & `label` are in shape of `1xCxHxW`, where C is the channels, which is 3 in this case. `pred[:, :, h, w] == label[:, :, h, w]` means one pixel prediction right, not three."},"comment":{"url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/comments/444814745","html_url":"https://github.com/ooooverflow/BiSeNet/issues/4#issuecomment-444814745","issue_url":"https://api.github.com/repos/ooooverflow/BiSeNet/issues/4","id":444814745,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NDgxNDc0NQ==","user":{"login":"hubutui","id":2948593,"node_id":"MDQ6VXNlcjI5NDg1OTM=","avatar_url":"https://avatars2.githubusercontent.com/u/2948593?v=4","gravatar_id":"","url":"https://api.github.com/users/hubutui","html_url":"https://github.com/hubutui","followers_url":"https://api.github.com/users/hubutui/followers","following_url":"https://api.github.com/users/hubutui/following{/other_user}","gists_url":"https://api.github.com/users/hubutui/gists{/gist_id}","starred_url":"https://api.github.com/users/hubutui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hubutui/subscriptions","organizations_url":"https://api.github.com/users/hubutui/orgs","repos_url":"https://api.github.com/users/hubutui/repos","events_url":"https://api.github.com/users/hubutui/events{/privacy}","received_events_url":"https://api.github.com/users/hubutui/received_events","type":"User","site_admin":false},"created_at":"2018-12-06T09:55:50Z","updated_at":"2018-12-06T09:55:50Z","author_association":"NONE","body":"Yeah, maybe convert label mask to palette mode is better. And for calculating mIOU, metrics module from sklearn might helps a lot."}}
{"actor":{"display_login":"hubutui"}}