Class ConcatOp
Provides outgoing messages for Concat(Vector, Vector), given random arguments to the function.
Inherited Members
Namespace: Microsoft.ML.Probabilistic.Factors
Assembly: Microsoft.ML.Probabilistic.dll
Syntax
[FactorMethod(typeof(Vector), "Concat", new Type[]{typeof(Vector), typeof(Vector)})]
[Quality(QualityBand.Stable)]
public static class ConcatOp
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(concat,first,second)). Adding up these values across all factors and variables gives the log-evidence estimate for VMP.
ConcatAverageConditional(VectorGaussian, VectorGaussian, VectorGaussian)
EP message to concat.
Declaration
[SkipIfAllUniform]
public static VectorGaussian ConcatAverageConditional(VectorGaussian first, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[p(concat) sum_(first,second) p(first,second) factor(concat,first,second)]/p(concat).
ConcatAverageConditional(VectorGaussian, Vector, VectorGaussian)
EP message to concat.
Declaration
public static VectorGaussian ConcatAverageConditional(VectorGaussian first, Vector second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[p(concat) sum_(first) p(first) factor(concat,first,second)]/p(concat).
ConcatAverageConditional(Vector, VectorGaussian, VectorGaussian)
EP message to concat.
Declaration
public static VectorGaussian ConcatAverageConditional(Vector first, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[p(concat) sum_(second) p(second) factor(concat,first,second)]/p(concat).
ConcatAverageConditionalInit(VectorGaussian, VectorGaussian)
Declaration
public static VectorGaussian ConcatAverageConditionalInit(VectorGaussian first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
ConcatAverageConditionalInit(VectorGaussian, Vector)
Declaration
public static VectorGaussian ConcatAverageConditionalInit(VectorGaussian first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
ConcatAverageConditionalInit(Vector, VectorGaussian)
Declaration
public static VectorGaussian ConcatAverageConditionalInit(Vector first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
ConcatAverageLogarithm(VectorGaussian, VectorGaussian, VectorGaussian)
VMP message to concat.
Declaration
[SkipIfAllUniform]
public static VectorGaussian ConcatAverageLogarithm(VectorGaussian first, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[sum_(first,second) p(first,second) factor(concat,first,second)].
ConcatAverageLogarithm(VectorGaussian, Vector, VectorGaussian)
VMP message to concat.
Declaration
public static VectorGaussian ConcatAverageLogarithm(VectorGaussian first, Vector second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[sum_(first) p(first) factor(concat,first,second)].
ConcatAverageLogarithm(Vector, VectorGaussian, VectorGaussian)
VMP message to concat.
Declaration
public static VectorGaussian ConcatAverageLogarithm(Vector first, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of concat as the random arguments are varied. The formula is proj[sum_(second) p(second) factor(concat,first,second)].
ConcatAverageLogarithmInit(VectorGaussian, VectorGaussian)
Declaration
public static VectorGaussian ConcatAverageLogarithmInit(VectorGaussian first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
ConcatAverageLogarithmInit(VectorGaussian, Vector)
Declaration
public static VectorGaussian ConcatAverageLogarithmInit(VectorGaussian first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
ConcatAverageLogarithmInit(Vector, VectorGaussian)
Declaration
public static VectorGaussian ConcatAverageLogarithmInit(Vector first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
Remarks
FirstAverageConditional(VectorGaussian, VectorGaussian, VectorGaussian)
EP message to first.
Declaration
public static VectorGaussian FirstAverageConditional(VectorGaussian concat, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of first as the random arguments are varied. The formula is proj[p(first) sum_(concat,second) p(concat,second) factor(concat,first,second)]/p(first).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
FirstAverageConditional(VectorGaussian, Vector, VectorGaussian)
EP message to first.
Declaration
public static VectorGaussian FirstAverageConditional(VectorGaussian concat, Vector second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| Vector | second | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of first as the random arguments are varied. The formula is proj[p(first) sum_(concat) p(concat) factor(concat,first,second)]/p(first).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
FirstAverageConditional(Vector, VectorGaussian)
EP message to first.
Declaration
public static VectorGaussian FirstAverageConditional(Vector concat, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of first conditioned on the given values.
FirstAverageLogarithm(VectorGaussian, VectorGaussian, VectorGaussian)
VMP message to first.
Declaration
public static VectorGaussian FirstAverageLogarithm(VectorGaussian concat, VectorGaussian second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| VectorGaussian | second | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the exponential of the average log-factor value, where the average is over all arguments except first. Because the factor is deterministic, concat is integrated out before taking the logarithm. The formula is exp(sum_(second) p(second) log(sum_concat p(concat) factor(concat,first,second))).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
FirstAverageLogarithm(VectorGaussian, Vector, VectorGaussian)
VMP message to first.
Declaration
public static VectorGaussian FirstAverageLogarithm(VectorGaussian concat, Vector second, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| Vector | second | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of first with concat integrated out. The formula is sum_concat p(concat) factor(concat,first,second).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
FirstAverageLogarithm(Vector, VectorGaussian)
VMP message to first.
Declaration
public static VectorGaussian FirstAverageLogarithm(Vector concat, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of first conditioned on the given values.
LogAverageFactor(VectorGaussian, VectorGaussian)
Evidence message for EP.
Declaration
public static double LogAverageFactor(VectorGaussian concat, VectorGaussian to_concat)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| VectorGaussian | to_concat | Outgoing message to |
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_(concat) p(concat) factor(concat,first,second)).
LogAverageFactor(VectorGaussian, Vector, Vector)
Evidence message for EP.
Declaration
public static double LogAverageFactor(VectorGaussian concat, Vector first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| Vector | first | Constant value for |
| Vector | second | Constant value for |
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_(concat) p(concat) factor(concat,first,second)).
LogAverageFactor(Vector, VectorGaussian, VectorGaussian)
Evidence message for EP.
Declaration
public static double LogAverageFactor(Vector concat, VectorGaussian first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
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_(first,second) p(first,second) factor(concat,first,second)).
LogAverageFactor(Vector, VectorGaussian, Vector)
Evidence message for EP.
Declaration
public static double LogAverageFactor(Vector concat, VectorGaussian first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
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_(first) p(first) factor(concat,first,second)).
LogAverageFactor(Vector, Vector, VectorGaussian)
Evidence message for EP.
Declaration
public static double LogAverageFactor(Vector concat, Vector first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
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_(second) p(second) factor(concat,first,second)).
LogAverageFactor(Vector, Vector, Vector)
Evidence message for EP.
Declaration
public static double LogAverageFactor(Vector concat, Vector first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| Vector | second | Constant value for |
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(concat,first,second)).
LogEvidenceRatio(VectorGaussian)
Evidence message for EP.
Declaration
public static double LogEvidenceRatio(VectorGaussian concat)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
Returns
| Type | Description |
|---|---|
| Double | Logarithm of the factor's contribution the EP model evidence. |
Remarks
The formula for the result is log(sum_(concat) p(concat) factor(concat,first,second) / sum_concat p(concat) messageTo(concat)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.
LogEvidenceRatio(Vector, VectorGaussian, VectorGaussian)
Evidence message for EP.
Declaration
public static double LogEvidenceRatio(Vector concat, VectorGaussian first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| Double | Logarithm of the factor's contribution the EP model evidence. |
Remarks
The formula for the result is log(sum_(first,second) p(first,second) factor(concat,first,second)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.
LogEvidenceRatio(Vector, VectorGaussian, Vector)
Evidence message for EP.
Declaration
public static double LogEvidenceRatio(Vector concat, VectorGaussian first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| Vector | second | Constant value for |
Returns
| Type | Description |
|---|---|
| Double | Logarithm of the factor's contribution the EP model evidence. |
Remarks
The formula for the result is log(sum_(first) p(first) factor(concat,first,second)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.
LogEvidenceRatio(Vector, Vector, VectorGaussian)
Evidence message for EP.
Declaration
public static double LogEvidenceRatio(Vector concat, Vector first, VectorGaussian second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| VectorGaussian | second | Incoming message from |
Returns
| Type | Description |
|---|---|
| Double | Logarithm of the factor's contribution the EP model evidence. |
Remarks
The formula for the result is log(sum_(second) p(second) factor(concat,first,second)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.
LogEvidenceRatio(Vector, Vector, Vector)
Evidence message for EP.
Declaration
public static double LogEvidenceRatio(Vector concat, Vector first, Vector second)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| Vector | second | Constant value for |
Returns
| Type | Description |
|---|---|
| Double | Logarithm of the factor's contribution the EP model evidence. |
Remarks
The formula for the result is log(factor(concat,first,second)). Adding up these values across all factors and variables gives the log-evidence estimate for EP.
SecondAverageConditional(VectorGaussian, VectorGaussian, VectorGaussian)
EP message to second.
Declaration
public static VectorGaussian SecondAverageConditional(VectorGaussian concat, VectorGaussian first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of second as the random arguments are varied. The formula is proj[p(second) sum_(concat,first) p(concat,first) factor(concat,first,second)]/p(second).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
SecondAverageConditional(VectorGaussian, Vector, VectorGaussian)
EP message to second.
Declaration
public static VectorGaussian SecondAverageConditional(VectorGaussian concat, Vector first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| Vector | first | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of second as the random arguments are varied. The formula is proj[p(second) sum_(concat) p(concat) factor(concat,first,second)]/p(second).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
SecondAverageConditional(Vector, VectorGaussian, VectorGaussian)
EP message to second.
Declaration
public static VectorGaussian SecondAverageConditional(Vector concat, VectorGaussian first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is a distribution matching the moments of second as the random arguments are varied. The formula is proj[p(second) sum_(first) p(first) factor(concat,first,second)]/p(second).
SecondAverageConditional(Vector, Vector, VectorGaussian)
EP message to second.
Declaration
public static VectorGaussian SecondAverageConditional(Vector concat, Vector first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of second conditioned on the given values.
SecondAverageLogarithm(VectorGaussian, VectorGaussian, VectorGaussian)
VMP message to second.
Declaration
public static VectorGaussian SecondAverageLogarithm(VectorGaussian concat, VectorGaussian first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the exponential of the average log-factor value, where the average is over all arguments except second. Because the factor is deterministic, concat is integrated out before taking the logarithm. The formula is exp(sum_(first) p(first) log(sum_concat p(concat) factor(concat,first,second))).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
SecondAverageLogarithm(VectorGaussian, Vector, VectorGaussian)
VMP message to second.
Declaration
public static VectorGaussian SecondAverageLogarithm(VectorGaussian concat, Vector first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| VectorGaussian | concat | Incoming message from |
| Vector | first | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of second with concat integrated out. The formula is sum_concat p(concat) factor(concat,first,second).
Exceptions
| Type | Condition |
|---|---|
| ImproperMessageException |
|
SecondAverageLogarithm(Vector, VectorGaussian, VectorGaussian)
VMP message to second.
Declaration
public static VectorGaussian SecondAverageLogarithm(Vector concat, VectorGaussian first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| VectorGaussian | first | Incoming message from |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the exponential of the average log-factor value, where the average is over all arguments except second. The formula is exp(sum_(first) p(first) log(factor(concat,first,second))).
SecondAverageLogarithm(Vector, Vector, VectorGaussian)
VMP message to second.
Declaration
public static VectorGaussian SecondAverageLogarithm(Vector concat, Vector first, VectorGaussian result)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector | concat | Constant value for |
| Vector | first | Constant value for |
| VectorGaussian | result | Modified to contain the outgoing message. |
Returns
| Type | Description |
|---|---|
| VectorGaussian |
|
Remarks
The outgoing message is the factor viewed as a function of second conditioned on the given values.