automl / automl/auto-sklearn

[Question] Rebuilding Auto Sklearn pipelines with the parameter dictionary returned by .cv_results_

Open
#1,663 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
8.1k
Forks
1.3k
PR merge metrics
No merged PRs in 30d

Description

### Is there a way to rebuild an auto sklearn pipeline after I have imported the params dictionary from the ._cv_results_ into a csv file?

My objective is to get the feature importance of every pipeline auto-sklearn tries. I know some models do not support feature importance so I have used permutation importance for them instead. I did get feature importance for the best pipeline ranked first in the leaderboard but I want to get the importance for every combination of hyperparameter it tries.

What I currently have is this csv file.

![image](https://user-images.githubusercontent.com/57257840/233001443-dd6b6c81-a38e-4b13-b313-b6c34e3e1f1d.png)

So, I'm looking for a method to rebuild the pipeline using these dictionaries.

I'd like to mention one more thing. Is there a direct way while training the AutoSklearnClassifier to access all the pipelines it tried with every hyperparameter combination to achieve my goal? I have looked into the documentation but I have failed to find anything accurate that would help me in this task. The [documentation](https://automl.github.io/auto-sklearn/master/api.html#autosklearn.classification.AutoSklearnClassifier.show_models) here lists a function `.show_models()` but the models it shows does not match the models shown in the `.leaderboard()`.

Am I missing some working of auto-sklearn?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.