Skip to content

For log(p), one question #116

Description

@yifeipet

Hello Dr. Balle,

I am not as experienced as you. I have a question regarding your method. I don't know whether the below situation is possible.
p = CDF (y + 0.5) - CDF (y-0.5)
Is it possible to get p = 0 in the probability matrix?
So log(p) can gives '-inf'.
tf.reduce_sum(log(p)) = nan

How do you suggest solving this issue?

Can I add a very small number, such as 1e-6, to avoid this issue? For example, I calculate log(p+ 1e-6) instead of log(p).

Thank you! Hope to get your invaluable suggestion.

Best Regards,
Yifei

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions