This should be more robust, erroring if the weights are indeed zero in a transparent way, and also fixes what I think was the actual problem which was that a small number divided by a large number can be the zero float, so it's better to use an evaluation strategy of x*log(x) which is robust to zero values that may pop up
This should be more robust, erroring if the weights are indeed zero in a transparent way, and also fixes what I think was the actual problem which was that a small number divided by a large number can be the zero float, so it's better to use an evaluation strategy of x*log(x) which is robust to zero values that may pop up