I have a matrix factorization and I'm wondering how I should initialize its weights and biases.

When getting prediction (recommendation), after computing a dot product and adding bias I want to use sigmoid function on that to get value from 0 to 1.

But when introducing a sigmoid here I also introduce a possibile vanishing/exploding gradient problem. For that I think that weights can be initialized with xavier function. But what aboud biases? Should I just use uniform distribution from (-0.01, 0.01) for example?


1 Answer 1


For matrix factorization I usually see it being initialized by a uniform distribution from [0, 1) like in this (pytorch) or a truncated normal with mean=0.0 and std=1.0 as in this (tensorflow).


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.