You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The PyMC documentation on the sample_smc function for Sequential Monte Carlo (SMC) doesn't describe the correct format/shape for the start parameter, which specifies the initial values for SMC. As a result, the users are required to figure out the correct format/shape on their own. Additionally, this unit test on the start parameter only tests a single chain - it doesn't consider a scenario with multiple chains.
Originally, I posted a question about the correct format/shape of the start parameter on the PyMC Discourse. @ricardoV94 then spotted that the unit test only covered the case of a single chain, suggesting me to report this issue on GitHub.
To be more concrete, let us consider the following code for Bayesian linear regression using SMC (this code is from my question posted on Discourse):
Here, inside the dictionary init_smc for SMC's initial values, the latent variables (i.e., coefficient0_log__ and coefficient1_log__) are each mapped to a numpy array of shape (num_draws, num_chains). If I used a different shape, such as (num_chains, num_draws), the code would crash. The PyMC documentation doesn't clarify what the correct shape of the numpy array should be.
Idea or request for content:
I would be grateful if someone could update the documentation on the sample_smc function's start parameter and also add a unit test to test the start parameter in the presence of multiple chains.
The text was updated successfully, but these errors were encountered:
Issue with current documentation:
The PyMC documentation on the
sample_smc
function for Sequential Monte Carlo (SMC) doesn't describe the correct format/shape for thestart
parameter, which specifies the initial values for SMC. As a result, the users are required to figure out the correct format/shape on their own. Additionally, this unit test on thestart
parameter only tests a single chain - it doesn't consider a scenario with multiple chains.Originally, I posted a question about the correct format/shape of the start parameter on the PyMC Discourse. @ricardoV94 then spotted that the unit test only covered the case of a single chain, suggesting me to report this issue on GitHub.
To be more concrete, let us consider the following code for Bayesian linear regression using SMC (this code is from my question posted on Discourse):
Here, inside the dictionary
init_smc
for SMC's initial values, the latent variables (i.e.,coefficient0_log__
andcoefficient1_log__
) are each mapped to a numpy array of shape(num_draws, num_chains)
. If I used a different shape, such as(num_chains, num_draws)
, the code would crash. The PyMC documentation doesn't clarify what the correct shape of the numpy array should be.Idea or request for content:
I would be grateful if someone could update the documentation on the
sample_smc
function'sstart
parameter and also add a unit test to test thestart
parameter in the presence of multiple chains.The text was updated successfully, but these errors were encountered: