Skip to content

Commit f4dba0c

Browse files
committed
Merge branch '439-specifying-conda-version' into update_email_setup
2 parents e121f79 + c666194 commit f4dba0c

File tree

5 files changed

+24
-13
lines changed

5 files changed

+24
-13
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ jobs:
4848
python-version: ${{ matrix.python-version }}
4949
environment-file: environment.ci.yml
5050
channels: defaults, conda-forge
51+
miniconda-version: "latest"
5152
- name: Install numpy
5253
run: conda install numpy=${{ matrix.numpy-version }}
5354
- name: Check linting

HISTORY.rst

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
History
33
=======
44

5+
0.8.3 (2024-**-**)
6+
------------------
7+
8+
* Fix conda versionning.
9+
* Reduce precision for test in `MapieCalibrator`.
10+
511
0.8.3 (2024-03-01)
612
------------------
713

@@ -13,7 +19,7 @@ History
1319
0.8.2 (2024-01-11)
1420
------------------
1521

16-
* * Resolve issue still present in 0.8.1 by updating pandas.
22+
* Resolve issue still present in 0.8.1 by updating pandas.
1723

1824
0.8.1 (2024-01-11)
1925
------------------

examples/regression/2-advanced-analysis/plot_timeseries_enbpi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@
165165
print(
166166
"Coverage / prediction interval width mean for MapieTimeSeriesRegressor: "
167167
"\nEnbPI without any partial_fit:"
168-
f"{coverage_npfit_enbpi :.3f}, {width_npfit_enbpi:.3f}"
168+
f"{coverage_npfit_enbpi:.3f}, {width_npfit_enbpi:.3f}"
169169
)
170170
print(
171171
"Coverage / prediction interval width mean for MapieTimeSeriesRegressor: "

mapie/calibration.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -97,15 +97,15 @@ class MapieCalibrator(BaseEstimator, ClassifierMixin):
9797
>>> mapie = MapieCalibrator().fit(X_toy, y_toy, random_state=20)
9898
>>> y_calib = mapie.predict_proba(X_toy)
9999
>>> print(y_calib)
100-
[[0.84900723 nan nan]
101-
[0.75432411 nan nan]
102-
[0.62285341 nan nan]
103-
[ nan 0.33333333 nan]
104-
[ nan 0.33333333 nan]
105-
[ nan 0.33333333 nan]
106-
[ nan nan 0.33333002]
107-
[ nan nan 0.54326683]
108-
[ nan nan 0.66666124]]
100+
[[0.84...... nan nan]
101+
[0.75...... nan nan]
102+
[0.62...... nan nan]
103+
[ nan 0.33...... nan]
104+
[ nan 0.33...... nan]
105+
[ nan 0.33...... nan]
106+
[ nan nan 0.33......]
107+
[ nan nan 0.54......]
108+
[ nan nan 0.66......]]
109109
"""
110110

111111
fit_attributes = [

mapie/tests/test_calibration.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,9 @@ def test_correct_results(cv: str) -> None:
314314
pred_ = mapie_cal.predict_proba(X_test)
315315
top_label_ece_ = top_label_ece(y_test, pred_)
316316
np.testing.assert_array_almost_equal(
317-
results[cv]["y_score"], pred_ # type:ignore
317+
np.array(results[cv]["y_score"]),
318+
np.array(pred_),
319+
decimal=2
318320
)
319321
np.testing.assert_allclose( # type:ignore
320322
results[cv]["top_label_ece"],
@@ -345,7 +347,9 @@ def test_correct_results_binary(cv: str) -> None:
345347
top_label_ece_ = top_label_ece(y_binary, pred_)
346348
ece = expected_calibration_error(y_binary, pred_)
347349
np.testing.assert_array_almost_equal(
348-
results_binary[cv]["y_score"], pred_ # type:ignore
350+
np.array(results_binary[cv]["y_score"]),
351+
np.array(pred_),
352+
decimal=2
349353
)
350354
np.testing.assert_allclose( # type:ignore
351355
results_binary[cv]["top_label_ece"],

0 commit comments

Comments
 (0)