Submitted by Constant-Cranberry29 t3_ywu5zb in deeplearning
Constant-Cranberry29 OP t1_iwo6ukg wrote
Reply to comment by Hamster729 in How to normalize data which contain positive and negative numbers into 0 and 1 by Constant-Cranberry29
>Okay. So, as I understand, your labels are usually either zero (before normalization), or negative, and, very rarely, they are positive.
>
>With the abs, it's easy for the model to reproduce the "baseline" level, because it's still zero after normalization, and as long as the last Dense produces a large negative number, sigmoid turns that number into zero.
>
>I think it would work even better if, instead of abs, you set all positive labels to zero, then normalize. (After normalization, the "baseline" level will become 1, also easy to reproduce).
>
>In both cases, will work for data points that originally had negative or zero labels, but it won't work for data points with originally positive labels.
>
>You have a problem without normalization, because the "baseline" level no longer 0 or 1 and your model needs to converge on that number. I think it would get there eventually, but you'll need more training, and probably learning rate decay (replace the constant learning rate with a tf.keras.optimizers.schedules.LearningRateSchedule object, and play with its settings.)
>
>The question is, do you want, and do you expect to be able to, reproduce positive labels? Or are they just random noise? If you don't need to reproduce them, just set them to zero. If they are valid and you need to reproduce them, do more training.
I have try using tf.keras.optimizers.schedules.LearningRateSchedule object, it still doesn't work
Viewing a single comment thread. View all comments