Hi KFrank,
Thanks again for your reply. Yes, I actually verified that problem is coming from the log and yes s was becoming 1.
I was already using a sigmoid function for s. So yes, in my model there exist a layer that ensures that it is in the range [0,1] and s is a learnable parameter. However, I was applying the log separately, after the sigmoid. I did not know that there exist a LogSigmoid. Now i am using it and it works just fine.
Thank you very much for your help !
Best,
Berkay