jakeret / tf_unet

Generic U-Net Tensorflow implementation for image segmentation
GNU General Public License v3.0
1.9k stars 748 forks source link

how to deal distance_weight? d1(x) and d2(x) #257

Open lucy3589 opened 5 years ago

lucy3589 commented 5 years ago

The separation border is computed using morphological operations. The weight map is then computed as w(x) = wc(x) + w0 · exp −(d1(x) + d2(x))2 2σ2 ! (2) where wc : Ω ! R is the weight map to balance the class frequencies, d1 : Ω ! R denotes the distance to the border of the nearest cell and d2 : Ω ! R the distance to the border of the second nearest cell. In our experiments we set w0 = 10 and σ ≈ 5 pixels.