automl / Auto-PyTorch

Automatic architecture search and hyperparameter optimization for PyTorch
Apache License 2.0
2.38k stars 289 forks source link

[AssertionError in `fit_pipeline()` when `pipeline_options` is not None #463

Closed PhMueller closed 2 years ago

PhMueller commented 2 years ago

Hi guys,

I was trying out your fantastic tool and found a small bug.

Issue Description

Problem/Solution:

In api/base_task Line 1635-1638

pipeline_options = self.pipeline_options.copy().update(pipeline_options) if pipeline_options is not None \
    else self.pipeline_options.copy()

assert pipeline_options is not None

The update() function returns None.

Replacing it with the following would remove the error:

pipeline_options = {**self.pipeline_option, **pipeline_options} if pipeline_options is not None \
    else self.pipeline_options.copy()

assert pipeline_options is not None

Current workaround:

api.set_pipeline_config(**{'early_stopping': 50})
api.fit_pipeline(...) # do not specify `pipeline_options` here. 

Your Local environment

ravinkohli commented 2 years ago

Hey, thanks for reporting this bug. We'll incorporate this in the next release which should be released very soon.

ravinkohli commented 2 years ago

Hi, we have fixed this issue in the latest release. You can install it using pip install autoPyTorch==0.2.1. I am closing this issue for now.