bnmf-algs
|
Structure to hold the parameters for the Allocation Model [5]. More...
#include <alloc_model_params.hpp>
Public Member Functions | |
Params (Scalar a, Scalar b, const std::vector< Scalar > &alpha, const std::vector< Scalar > &beta) | |
Construct Params manually with the given distribution parameters. More... | |
Params (const shape< 3 > &tensor_shape) | |
Construct Params with the default distribution parameters according to the given tensor shape. More... | |
Params ()=default | |
Public Attributes | |
Scalar | a |
Shape parameter of Gamma distribution. More... | |
Scalar | b |
Rate parameter of Gamma distribution. More... | |
std::vector< Scalar > | alpha |
Parameter vector of Dirichlet prior for matrix \(W_{x \times y}\) of size \(x\). More... | |
std::vector< Scalar > | beta |
Parameter vector of Dirichlet prior for matrix \(H_{z \times y}\) of size \(z\). More... | |
Structure to hold the parameters for the Allocation Model [5].
According to the Allocation Model,
\[ L_j \sim \mathcal{G}(a, b) \qquad W_{:k} \sim \mathcal{D}(\alpha) \qquad H_{:j} \sim \mathcal{D}(\beta) \]
and \(S_{ijk} \sim \mathcal{PO}(W_{ik}H_{kj}L_j)\).
Scalar | Type of the parameters. Common choices are double and float, but integer-like types can also be used. |
|
inline |
Construct Params manually with the given distribution parameters.
a | Shape parameter of Gamma distribution. |
b | Rate parameter of Gamma distribution. |
alpha | Parameter vector of Dirichlet prior for matrix \(W_{x \times y}\) of size \(x\). |
beta | Parameter vector of Dirichlet prior for matrix \(H_{z \times y}\) of size \(z\). |
|
inlineexplicit |
Construct Params with the default distribution parameters according to the given tensor shape.
Default distribution parameters are
\begin{eqnarray*} \mbox{a} &=& 1 \\ \mbox{b} &=& 10 \\ \mbox{alpha} &=& \begin{matrix} (1 & 1 & \dots & 1) \end{matrix} \\ \mbox{beta} &=& \begin{matrix} (1 & 1 & \dots & 1) \end{matrix} \end{eqnarray*}
tensor_shape | Shape of tensor \(S_{x \times y \times z}\). |
|
default |
Scalar bnmf_algs::alloc_model::Params< Scalar >::a |
Shape parameter of Gamma distribution.
std::vector<Scalar> bnmf_algs::alloc_model::Params< Scalar >::alpha |
Parameter vector of Dirichlet prior for matrix \(W_{x \times y}\) of size \(x\).
Scalar bnmf_algs::alloc_model::Params< Scalar >::b |
Rate parameter of Gamma distribution.
std::vector<Scalar> bnmf_algs::alloc_model::Params< Scalar >::beta |
Parameter vector of Dirichlet prior for matrix \(H_{z \times y}\) of size \(z\).