lkevinzc / dance

Codes for "DANCE: A Deep Attentive Contour Model for Efficient Instance Segmentation", WACV2021
67 stars 13 forks source link

about activation function #3

Closed feizhaixiaomimei closed 3 years ago

feizhaixiaomimei commented 3 years ago

Thank you for your great work,I have a question: In the paper,you add a "tanh" activation function to the snake prediction before multiplying it by the object scale.Why do you choose the activation function?

lkevinzc commented 3 years ago

Hi @feizhaixiaomimei thanks for your interest. It is because we hope to match the scales. Since the input coordinates are normalised to be [0, 1], we want the output to be a multiplicative factor on the width/height, so that it does not need to care about the absolute object scales. After tanh, the bounded range [-1, 1] is suitable for such multiplicative factor. Here we assumed the offsets should not be larger than h/w.