hellochick / ICNet-tensorflow

TensorFlow-based implementation of "ICNet for Real-Time Semantic Segmentation on High-Resolution Images".
406 stars 153 forks source link

Bug in image_reader.py? #106

Closed eldercrow closed 5 years ago

eldercrow commented 5 years ago

In utils/image_reader.py:88:

label = label - ignore_label # Needs to be subtracted and later added due to 0 padding.

But there's no code that adds back the subtracted ignore_label. Is this intended or a bug?

hellochick commented 5 years ago

That is definitely a bug, thank you. I will fix it soon.

LinRui9531 commented 5 years ago

In utils/image_reader.py:88:

label = label - ignore_label # Needs to be subtracted and later added due to 0 padding.

But there's no code that adds back the subtracted ignore_label. Is this intended or a bug?

Would u tell me yours cityscapes dataset path? or the type of self.image_list and self.label_list? when i run python train.py., i found that in util/image_reader.py , the value returned by from_tensor_slices is null.

dataset = tf.data.Dataset.from_tensor_slices((self.image_list, self.label_list)) dataset = dataset.map(lambda x, y: _parse_function(x, y, cfg.IMG_MEAN), num_parallel_calls=cfg.N_WORKERS)