StevenLiuWen / ano_pred_cvpr2018

Official implementation of Paper Future Frame Prediction for Anomaly Detection -- A New Baseline, CVPR 2018
435 stars 126 forks source link

the last activation function of the generator #7

Closed wsz912 closed 6 years ago

wsz912 commented 6 years ago

Hi, Dr. Liu Wen. I have a problem about the last activation function of the generator. Why dose the last activation function in your code choose tanh rather than Relu? To my knowledge, the original U-net chose ReLu as the last activation function. I'm confused about this change. Could you give me some explanations about this problem? Thanks in advance.

StevenLiuWen commented 6 years ago

Since we have normalized the image color space to [-1, 1], so that we use tanh. In many image generation tasks, such as GAN, image-to image translation, cyclegan, next frame prediction and so on, they usually normalize the image color space to [-1, 1] and we just follow them.