53 double log_conditional_density_V(
double v)
const;
63 std::random_device rd;
66 mutable std::mt19937 gen;
77 static constexpr double proposal_std = 0.5;
91 const double tau_power_sigma = std::pow(
params.tau,
params.sigma);
185 int size_old_cj)
const override;
200 int ci,
int cj)
const override;
Abstract interface for Bayesian nonparametric processes.
Manages distance matrices and cluster allocations for points.
Definition Data.hpp:26
int get_accepted_U() const
Gets the number of accepted U updates for monitoring convergence.
Definition NGGP.hpp:231
double get_U() const
Gets the current value of the latent variable U.
Definition NGGP.hpp:225
NGGP(Data &d, Params &p)
Constructor for the Normalized Generalized Gamma Process.
Definition NGGP.hpp:113
double prior_ratio_split(int ci, int cj) const override
Computes the prior ratio for a split operation in an NGGP-based split-merge MCMC algorithm.
Definition NGGP.cpp:72
double gibbs_prior_new_cluster() const override
Computes the log prior probability of assigning a data point to a new cluster.
Definition NGGP.cpp:59
void update_params() override
Updates the NGGP parameters by updating the latent variable U.
Definition NGGP.hpp:212
double prior_ratio_merge(int size_old_ci, int size_old_cj) const override
Computes the prior ratio for a merge operation in an NGGP-based split-merge MCMC algorithm.
Definition NGGP.cpp:97
double gibbs_prior_existing_cluster(int cls_idx, int obs_idx=0) const override
Computes the log prior probability of assigning a data point to an existing cluster.
Definition NGGP.cpp:16
double prior_ratio_shuffle(int size_old_ci, int size_old_cj, int ci, int cj) const override
Computes the prior ratio for a shuffle operation in an NGGP-based split-merge MCMC algorithm.
Definition NGGP.cpp:120
Eigen::VectorXd gibbs_prior_existing_clusters(int obs_idx) const override
Computes the log prior probabilities of assigning a data point to every existing cluster....
Definition NGGP.cpp:34
Process(Data &d, Params &p)
Constructor initializing process with data and parameters.
Definition Process.hpp:75
Params & params
Reference to the parameters object containing process hyperparameters.
Definition Process.hpp:49
Structure containing all parameters needed for the NGGP (Normalized Generalized Gamma Process) and DP...
Definition Params.hpp:35