Skip to content

[ENH] Add NaiveProbaRegressor using distribution fitter - #1108

Open
patelchaitany wants to merge 2 commits into
sktime:mainfrom
patelchaitany:enh/naive-proba-regressor
Open

[ENH] Add NaiveProbaRegressor using distribution fitter#1108
patelchaitany wants to merge 2 commits into
sktime:mainfrom
patelchaitany:enh/naive-proba-regressor

Conversation

@patelchaitany

@patelchaitany patelchaitany commented Jul 7, 2026

Copy link
Copy Markdown
Member

Adds a naive baseline probabilistic regressor that pools all training target values, fits a single distribution via a configurable distfitter, and broadcasts that distribution at prediction time.

Reference Issues/PRs

#1085

What does this implement/fix? Explain your changes.

Does your contribution introduce a new dependency? If yes, which one?

What should a reviewer concentrate their feedback on?

Did you add any tests for the change?

Any other comments?

PR checklist

For all contributions
  • I've added myself to the list of contributors with any new badges I've earned :-)
    How to: add yourself to the all-contributors file in the skpro root directory (not the CONTRIBUTORS.md). Common badges: code - fixing a bug, or adding code logic. doc - writing or improving documentation or docstrings. bug - reporting or diagnosing a bug (get this plus code if you also fixed the bug in the PR).maintenance - CI, test framework, release.
    See here for full badge reference
  • The PR title starts with either [ENH], [MNT], [DOC], or [BUG]. [BUG] - bugfix, [MNT] - CI, test framework, [ENH] - adding or improving code, [DOC] - writing or improving documentation or docstrings.
For new estimators
  • I've added the estimator to the API reference - in docs/source/api_reference/taskname.rst, follow the pattern.
  • I've added one or more illustrative usage examples to the docstring, in a pydocstyle compliant Examples section.
  • If the estimator relies on a soft dependency, I've set the python_dependencies tag and ensured
    dependency isolation, see the estimator dependencies guide.

Adds a naive baseline probabilistic regressor that pools all training
target values, fits a single distribution via a configurable distfitter,
and broadcasts that distribution at prediction time.
Comment thread skpro/regression/naive.py Outdated

return self

def _predict(self, X):

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is already the default, so it does not need to be copy-pasted

Comment thread skpro/regression/naive.py Outdated
dist = self.distribution_
params = dist.get_params()

broadcast_params = {}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is brittle since it works only for some distributions.

I think there should be a general public API mechanism for this kind of broadcasting.

I believe this exists, by wrapping distributions in the IID class - not sure if there is a more elegant way.
I could imagine, for instance, if the distribution is "parametric" (as per the distribution type tag) that we can do what you are doing below. But, not for all distributions.

@fkiraly fkiraly left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice - see above for a comment on ensuring that broadcasting always works.

We should, in particular, test the EmpiricalFitter, since there the current logic would fail!

@fkiraly fkiraly added enhancement module:distributions&simulation probability distributions and simulators labels Jul 16, 2026
Signed-off-by: Chaitany Patel <patelchaitany93@gmail.com>
@patelchaitany
patelchaitany requested a review from fkiraly July 16, 2026 20:02
@patelchaitany

Copy link
Copy Markdown
Member Author

@fkiraly, Let me know if any more changes needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement module:distributions&simulation probability distributions and simulators

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants