Skip to content

Commit 7736558

Browse files
FIX: temporary warning users that optimize_beta is not working (#596)
1 parent 9cbaad8 commit 7736558

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

HISTORY.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ History
1111
* Fix issue 548 to correct labels generated in tutorial
1212
* Fix issue 547 to fix wrong warning
1313
* Fix issue 480 (correct display of mathematical equations in generated notebooks)
14+
* Temporary solution waiting for issue 588 to be fixed (optimize_beta not working)
1415
* Remove several irrelevant user warnings
1516
* Limit max sklearn version allowed at MAPIE installation
1617
* Refactor MapieRegressor, EnsembleRegressor, and MapieQuantileRegressor, to prepare for the release of v1.0.0

mapie/conformity_scores/regression.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import logging
12
from abc import ABCMeta, abstractmethod
23
from typing import Tuple
34

@@ -217,6 +218,13 @@ def _beta_optimize(
217218
Array of betas minimizing the differences
218219
``(1-alpha+beta)-quantile - beta-quantile``.
219220
"""
221+
# Using logging.warning instead of warnings.warn to avoid warnings during tests
222+
logging.warning(
223+
"The option to optimize beta (minimize interval width) is not working and "
224+
"needs to be fixed. See more details in "
225+
"https://github.com/scikit-learn-contrib/MAPIE/issues/588"
226+
)
227+
220228
beta_np = np.full(
221229
shape=(len(lower_bounds), len(alpha_np)),
222230
fill_value=np.nan,

0 commit comments

Comments
 (0)