Skip to content

[DOC] Add example for finding and reinstantiating flows#1636

Open
Akarshkushwaha wants to merge 3 commits intoopenml:mainfrom
Akarshkushwaha:example-reinstantiable-flows
Open

[DOC] Add example for finding and reinstantiating flows#1636
Akarshkushwaha wants to merge 3 commits intoopenml:mainfrom
Akarshkushwaha:example-reinstantiable-flows

Conversation

@Akarshkushwaha
Copy link
Contributor

Metadata

Details

  • What does this PR implement/fix? Explain your changes.
    This PR adds a new example script examples/Advanced/plot_reinstantiable_flows.py that demonstrates:
    1. Listing flows from OpenML.
    2. Filtering for scikit-learn flows.
    3. Reinstantiating flows locally using openml.flows.get_flow(..., reinstantiate=True).
    4. Using the reinstantiated model object.
      This addresses the request in Add the example on downloading reinstantiable flows #1166 (and Finding all runs with flows that can be reinstantiated #1165).
  • Why is this change necessary? What is the problem it solves?
    Users often want to find specific flows (e.g., sklearn ones) and run them locally. This example provides a clear, runnable script to show how to do this efficiently, including how to handle potential version mismatches (strict_version=False).
  • How can I reproduce the issue this PR is solving and its solution?
    Run the new example script:
    python examples/Advanced/plot_reinstantiable_flows.py

@Akarshkushwaha
Copy link
Contributor Author

Hi @PGijsbers @fkiraly , I have implemented the example as discussed in #1165 to resolve #1166.
It filters for newer flows (using offset) to ensure compatibility with the current openml-sklearn extension.

@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.13%. Comparing base (d18ca42) to head (e83d796).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1636      +/-   ##
==========================================
+ Coverage   52.08%   52.13%   +0.04%     
==========================================
  Files          36       36              
  Lines        4360     4360              
==========================================
+ Hits         2271     2273       +2     
+ Misses       2089     2087       -2     

☔ 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.

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 the example on downloading reinstantiable flows

2 participants