Find_MAP when optimizing a Potential

Dlogp gives you the gradient of the p parameter with respect to the model joint probability conditioned on all the unobserved parameters and observed data. Samples is unobserved but a value must be provided by the user (or algorithm).

That’s the whole point no? find_map or nuts get to the posterior by iteratively proposing different values of samples and p. For p you can get gradient information (conditioned on data and all other paramerers) to guide your search more cleverly. For samples you cannot because it’s a discrete parameter.