Search Results for

    Show / Hide Table of Contents

    Class BooleanNotOp

    Provides outgoing messages for Not(Boolean), given random arguments to the function.

    Inheritance
    Object
    BooleanNotOp
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Object.ReferenceEquals(Object, Object)
    Object.ToString()
    Namespace: Microsoft.ML.Probabilistic.Factors
    Assembly: Microsoft.ML.Probabilistic.dll
    Syntax
    [FactorMethod(typeof(Factor), "Not", new Type[]{})]
    [Quality(QualityBand.Mature)]
    public static class BooleanNotOp

    Methods

    AverageLogFactor()

    Evidence message for VMP.

    Declaration
    public static double AverageLogFactor()
    Returns
    Type Description
    Double

    Zero.

    Remarks

    The formula for the result is log(factor(not,b)). Adding up these values across all factors and variables gives the log-evidence estimate for VMP.

    AverageLogFactor(Boolean, Boolean)

    Evidence message for VMP.

    Declaration
    public static double AverageLogFactor(bool not, bool b)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Boolean b

    Constant value for b.

    Returns
    Type Description
    Double

    Zero.

    Remarks

    The formula for the result is log(factor(not,b)). Adding up these values across all factors and variables gives the log-evidence estimate for VMP.

    BAverageConditional(Bernoulli)

    EP message to b.

    Declaration
    public static Bernoulli BAverageConditional(Bernoulli not)
    Parameters
    Type Name Description
    Bernoulli not

    Incoming message from not. Must be a proper distribution. If uniform, the result will be uniform.

    Returns
    Type Description
    Bernoulli

    The outgoing EP message to the b argument.

    Remarks

    The outgoing message is a distribution matching the moments of b as the random arguments are varied. The formula is proj[p(b) sum_(not) p(not) factor(not,b)]/p(b).

    Exceptions
    Type Condition
    ImproperMessageException

    not is not a proper distribution.

    BAverageConditional(Boolean)

    EP message to b.

    Declaration
    public static Bernoulli BAverageConditional(bool not)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Returns
    Type Description
    Bernoulli

    The outgoing EP message to the b argument.

    Remarks

    The outgoing message is the factor viewed as a function of b conditioned on the given values.

    BAverageLogarithm(Bernoulli)

    VMP message to b.

    Declaration
    public static Bernoulli BAverageLogarithm(Bernoulli not)
    Parameters
    Type Name Description
    Bernoulli not

    Incoming message from not. Must be a proper distribution. If uniform, the result will be uniform.

    Returns
    Type Description
    Bernoulli

    The outgoing VMP message to the b argument.

    Remarks

    The outgoing message is the factor viewed as a function of b with not integrated out. The formula is sum_not p(not) factor(not,b).

    Exceptions
    Type Condition
    ImproperMessageException

    not is not a proper distribution.

    BAverageLogarithm(Boolean)

    VMP message to b.

    Declaration
    public static Bernoulli BAverageLogarithm(bool not)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Returns
    Type Description
    Bernoulli

    The outgoing VMP message to the b argument.

    Remarks

    The outgoing message is the factor viewed as a function of b conditioned on the given values.

    LogAverageFactor(Bernoulli, Bernoulli, Bernoulli)

    Evidence message for EP.

    Declaration
    public static double LogAverageFactor(Bernoulli not, Bernoulli b, Bernoulli to_not)
    Parameters
    Type Name Description
    Bernoulli not

    Incoming message from not.

    Bernoulli b

    Incoming message from b.

    Bernoulli to_not

    Outgoing message to not.

    Returns
    Type Description
    Double

    Logarithm of the factor's average value across the given argument distributions.

    Remarks

    The formula for the result is log(sum_(not,b) p(not,b) factor(not,b)).

    LogAverageFactor(Bernoulli, Boolean)

    Evidence message for EP.

    Declaration
    public static double LogAverageFactor(Bernoulli not, bool b)
    Parameters
    Type Name Description
    Bernoulli not

    Incoming message from not.

    Boolean b

    Constant value for b.

    Returns
    Type Description
    Double

    Logarithm of the factor's average value across the given argument distributions.

    Remarks

    The formula for the result is log(sum_(not) p(not) factor(not,b)).

    LogAverageFactor(Boolean, Bernoulli)

    Evidence message for EP.

    Declaration
    public static double LogAverageFactor(bool not, Bernoulli b)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Bernoulli b

    Incoming message from b.

    Returns
    Type Description
    Double

    Logarithm of the factor's average value across the given argument distributions.

    Remarks

    The formula for the result is log(sum_(b) p(b) factor(not,b)).

    LogAverageFactor(Boolean, Boolean)

    Evidence message for EP.

    Declaration
    public static double LogAverageFactor(bool not, bool b)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Boolean b

    Constant value for b.

    Returns
    Type Description
    Double

    Logarithm of the factor's average value across the given argument distributions.

    Remarks

    The formula for the result is log(factor(not,b)).

    LogEvidenceRatio(Bernoulli)

    Evidence message for EP.

    Declaration
    public static double LogEvidenceRatio(Bernoulli not)
    Parameters
    Type Name Description
    Bernoulli not

    Incoming message from not.

    Returns
    Type Description
    Double

    Logarithm of the factor's contribution the EP model evidence.

    Remarks

    The formula for the result is log(sum_(not) p(not) factor(not,b) / sum_not p(not) messageTo(not)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.

    LogEvidenceRatio(Boolean, Bernoulli)

    Evidence message for EP.

    Declaration
    public static double LogEvidenceRatio(bool not, Bernoulli b)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Bernoulli b

    Incoming message from b.

    Returns
    Type Description
    Double

    Logarithm of the factor's contribution the EP model evidence.

    Remarks

    The formula for the result is log(sum_(b) p(b) factor(not,b)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.

    LogEvidenceRatio(Boolean, Boolean)

    Evidence message for EP.

    Declaration
    public static double LogEvidenceRatio(bool not, bool b)
    Parameters
    Type Name Description
    Boolean not

    Constant value for not.

    Boolean b

    Constant value for b.

    Returns
    Type Description
    Double

    Logarithm of the factor's contribution the EP model evidence.

    Remarks

    The formula for the result is log(factor(not,b)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.

    NotAverageConditional(Bernoulli)

    EP message to not.

    Declaration
    public static Bernoulli NotAverageConditional(Bernoulli b)
    Parameters
    Type Name Description
    Bernoulli b

    Incoming message from b. Must be a proper distribution. If uniform, the result will be uniform.

    Returns
    Type Description
    Bernoulli

    The outgoing EP message to the not argument.

    Remarks

    The outgoing message is a distribution matching the moments of not as the random arguments are varied. The formula is proj[p(not) sum_(b) p(b) factor(not,b)]/p(not).

    Exceptions
    Type Condition
    ImproperMessageException

    b is not a proper distribution.

    NotAverageLogarithm(Bernoulli)

    VMP message to not.

    Declaration
    public static Bernoulli NotAverageLogarithm(Bernoulli b)
    Parameters
    Type Name Description
    Bernoulli b

    Incoming message from b. Must be a proper distribution. If uniform, the result will be uniform.

    Returns
    Type Description
    Bernoulli

    The outgoing VMP message to the not argument.

    Remarks

    The outgoing message is a distribution matching the moments of not as the random arguments are varied. The formula is proj[sum_(b) p(b) factor(not,b)].

    Exceptions
    Type Condition
    ImproperMessageException

    b is not a proper distribution.

    In This Article
    Back to top Copyright © .NET Foundation. All rights reserved.