Compute log-likelihood for less samples
Open
@OttoVintola is already working on this.
Since Jun 13, 2026.
enhancement
- Dominant language
- Rust
- Stars
- 8
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
The idea is to only compute the log-likelihood for the samples that fall into the tree instead of over all samples.
In weight.rs we use a function pointer to a PyMC weight function and then call it with
fn log_weight(&self, predictions: &[f64]) -> f64 {
unsafe { (self.func_ptr)(predictions.as_ptr(), predictions.len()) }
}
However, the log likelihood of the samples that are not assigned to the mutated tree during SMC, remain the same from the previous iteration. Thus, they are being computed for no reason again.
According to the PyTensor folks, a solution could be to use a subtensor lift in from PyTensor.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.