Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

493 add mondrian cp #504

Merged
merged 86 commits into from
Sep 3, 2024
Merged

493 add mondrian cp #504

merged 86 commits into from
Sep 3, 2024

Conversation

vincentblot28
Copy link
Collaborator

Description

Include Mondrian CP in the MAPIE package as a wrapper of existing mapie estimators.

Fixes #(issue)

Type of change

Please remove options that are irrelevant.

New class

How Has This Been Tested?

I have tested that method worked with eligible mapie estimator and conformity scores and that it returned an error when either the estimator or the conformity score were not eligible.

Checklist

  • I have read the contributing guidelines
  • I have updated the HISTORY.rst and AUTHORS.rst files
  • Linting passes successfully : make lint
  • Typing passes successfully : make type-check
  • Unit tests pass successfully : make tests
  • Coverage is 100% : make coverage
  • Documentation builds successfully : make doc

@vincentblot28 vincentblot28 linked an issue Aug 5, 2024 that may be closed by this pull request
Copy link
Collaborator

@Valentin-Laurent Valentin-Laurent left a comment

Choose a reason for hiding this comment

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

First review round (focused on the fitting part)

mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@thibaultcordier thibaultcordier left a comment

Choose a reason for hiding this comment

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

Thank you for your latest changes. I've just missed a few other typos but I think it's ready for merging.

Will an example / notebook be provided in this PR or in another?

mapie/tests/test_mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
mapie/mondrian.py Show resolved Hide resolved
mapie/tests/test_mondrian.py Outdated Show resolved Hide resolved
plt.hlines(0.9, -1, 21, label="90% coverage", color="black", linestyle="--")
plt.ylabel("Coverage")
plt.legend(loc='upper left', bbox_to_anchor=(1, 1))
plt.show()
Copy link
Collaborator

Choose a reason for hiding this comment

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

You might need to fix fig size before (text is cut off at the moment).

Screenshot 2024-08-26 at 16 33 48

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done

notebooks/mondrian/tutorial_mondrian_regression.ipynb Outdated Show resolved Hide resolved
mapie/mondrian.py Outdated Show resolved Hide resolved
Comment on lines 37 to 40
##############################################################################
# 1. Create the noisy dataset with 10 groups, each of those groups having
# a different level of noise.
# -------------------------------------------------------------------
Copy link
Collaborator

Choose a reason for hiding this comment

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

Not urgent, but if you have the time, the titles are not displayed properly -> you will have to see what's wrong or if it's intentional

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done

@vincentblot28 vincentblot28 merged commit dd39a25 into master Sep 3, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add mondrian CP
5 participants