layumi / Seg-Uncertainty

IJCAI2020 & IJCV2021 :city_sunrise: Unsupervised Scene Adaptation with Memory Regularization in vivo
https://arxiv.org/abs/1912.11164
MIT License
386 stars 51 forks source link

How get the vriance visualization #22

Open luckwyy opened 2 years ago

luckwyy commented 2 years ago

Fig 3

layumi commented 2 years ago

Hi @luckywyy , Thanks for your attention on our work. I use the KL distance between the two classifier prediction. Since KL distance is non-negative, I further use log(1+10* KL) to normalise the distance in [0,1]. for visualization only. And then I use the package, matplot, to show the heat map.

The relevant code can be found at https://github.com/layumi/Seg-Uncertainty/blob/master/evaluate_cityscapes.py#L216-L217