Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[ENH] V1 β†’ V2 API Migration - estimation procedures#1604

Merged
PGijsbers merged 262 commits intoopenml:mainopenml/openml-python:mainfrom
EmanAbdelhaleem:estimation-procedures-migEmanAbdelhaleem/openml-python:estimation-procedures-migCopy head branch name to clipboard
Mar 26, 2026
Merged

[ENH] V1 β†’ V2 API Migration - estimation procedures#1604
PGijsbers merged 262 commits intoopenml:mainopenml/openml-python:mainfrom
EmanAbdelhaleem:estimation-procedures-migEmanAbdelhaleem/openml-python:estimation-procedures-migCopy head branch name to clipboard

Conversation

@EmanAbdelhaleem
Copy link
Contributor

@EmanAbdelhaleem EmanAbdelhaleem commented Jan 7, 2026

Fixes #1622
Depends on #1576
Related to: #1575

Details

This PR implements EstimationProcedures resource, and refactor its existing functions

@codecov-commenter
Copy link

codecov-commenter commented Jan 7, 2026

Codecov Report

❌ Patch coverage is 70.58824% with 15 lines in your changes missing coverage. Please review.
βœ… Project coverage is 55.61%. Comparing base (ec3ed63) to head (d2117cf).

Files with missing lines Patch % Lines
...enml/estimation_procedures/estimation_procedure.py 63.15% 7 Missing ⚠️
openml/_api/resources/estimation_procedure.py 76.92% 6 Missing ⚠️
openml/evaluations/functions.py 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1604      +/-   ##
==========================================
+ Coverage   54.71%   55.61%   +0.89%     
==========================================
  Files          61       63       +2     
  Lines        5086     5108      +22     
==========================================
+ Hits         2783     2841      +58     
+ Misses       2303     2267      -36     

β˜” View full report in Codecov by Sentry.
πŸ“’ Have feedback on the report? Share it here.

πŸš€ New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Collaborator

@geetu040 geetu040 left a comment

Choose a reason for hiding this comment

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

This looks great. The implementation is clean and nicely decoupled. The next step should be adding tests, but let's wait until we have a clearer roadmap for that.
Also, please update the PR description to follow this format:

Fixes #...
Depends on #1576
Related to #1575

@geetu040 geetu040 mentioned this pull request Jan 9, 2026
18 tasks
@geetu040 geetu040 self-assigned this Mar 23, 2026
Copy link
Collaborator

@geetu040 geetu040 left a comment

Choose a reason for hiding this comment

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

@EmanAbdelhaleem Thanks for the PR. Nicely done!
I have updated the PR to sync with latest changes in base PR.

@PGijsbers please review/merge.

Copy link
Collaborator

@PGijsbers PGijsbers left a comment

Choose a reason for hiding this comment

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

I had a closer look at the old code. Best I can tell list_estimation_procedures is never called nor is it actually public (or am I wrong?). The PR also keeps some code duplication that existed in the old style. I would refactor it as follows:

  • remove the current list function and rename list_detailed to list. Going forward, the only way to access the estimation procedures is with all their metadata. It seems that besides the retention of metadata, the only difference is in how to assess that the server response is parseable, and I don't think those differences matter (especially since it looks like list_estimation_procedures isn't used).
  • define an EstimationProcedure named tuple which has fields id, name, task_type_id, and type. Make the list function return that instead.
  • in _get_estimation_procedure_list you can convert the named tuples with ._asdict()
  • in list_estimation_procedures just map to the names of the returned values to keep the response identical

This makes sure that at this stage we already reduce duplicate code, and that in the future we easily refactor further to make use of the typed return values instead.

Fetches estimation procedures from the v1 XML API endpoint.
"""

def list(self) -> builtins.list[str]:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you try again? It really shouldn't. If it does and you don't understand why or don't know how to best resolve it, please let us know.

@geetu040 geetu040 requested a review from PGijsbers March 24, 2026 13:36
@geetu040
Copy link
Collaborator

@PGijsbers Thanks for the detailed suggestions. I've applied the changes. This PR is up for review/merge.

Copy link
Collaborator

@PGijsbers PGijsbers left a comment

Choose a reason for hiding this comment

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

Minor cleanup, I'll commit it myself.

openml/estimation_procedures/estimation_procedure.py Outdated Show resolved Hide resolved
@geetu040 geetu040 requested a review from PGijsbers March 25, 2026 14:56
Copy link
Collaborator

@PGijsbers PGijsbers left a comment

Choose a reason for hiding this comment

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

will merge if CI looks good

@PGijsbers PGijsbers merged commit e653ef6 into openml:main Mar 26, 2026
25 of 27 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.

[ENH] V1 β†’ V2 API Migration - estimation procedures

7 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.