Feature request: Observation intervals

Open
#448 5 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 6 days

@Pratyusha-DS13 is already working on this.

Since Mar 22, 2026.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
30/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Quiet
Tech stack
python

Research direction

No file, test, or entry point is named. Start by reviewing how the current sbi version represents observations and performs inference, then determine the design needed for hypercube or interval observations and define completion as producing plausible parameters consistent with the requested output intervals.

Written by the indexing model from the issue text.

Description

docs enhancement inference

I would find it useful to be able to use sbi to generate all parameters consistent with simulation results within a certain interval; for example a rheobase between two acceptable values and a spike width between two acceptable values for a given neuron model. The best way to do this would be to allow the observation to be defined as a hypercube and identify plausible parameters that generate outputs within this cube.

The two naive approaches I have tried are to train a network to noisily simulate single observations, then randomly sample observations from the desired hypercube to get a set of plausible parameters for each sample and combine the results. This seems like it would introduce excessive noise as the most likely observations are likely to lie on a manifold within the hypercube, and the distributions are indeed broader than using MCMC methods on a toy example. The second approach is to train the network with a simulator that produces random intervals containing the true output but this seems hugely inefficient.

Are there any plans to add this functionality, or is there a simple way to implement it in the current version of sbi?

Dominant language
Python
Stars
894
Forks
306
Avg merge
5d 21h
Merged PRs (30d)
61

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from sbi-dev/sbi

All issues in sbi-dev/sbi

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.