-
Notifications
You must be signed in to change notification settings - Fork 68
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
SMAC optimizer does not support mixed input space #666
Comments
Hi @ephoris , thanks so much for reporting this. This does indeed look like a bug, though I'm surprised we missed that test case. We'd be happy to accept a PR. Could you please include a test case for it as well? Thanks! |
@motus - fyi |
We should probably replace all instances of |
I know that I wrote a small test following the format of some of the others, seems the bug only applies if you have multiple numeric types. If you add in a I created a test but my fix doesn't seem to work in the pytest infrastructure. I can take a closer look to see what's going on. |
Please at least submit a draft PR for now. Then we can try and help take a look. Thanks! |
Addressing issue discussed in #666 --------- Co-authored-by: Sergiy Matusevych <sergiy.matusevych@gmail.com> Co-authored-by: Brian Kroth <bpkroth@users.noreply.github.com>
Using the SMAC optimizer in conjunction with a mix of different parameter space types will throw an error. Minimum reproducible example is attached.
Results in an error
The SMAC optimizer register function results in a call to
SmacOptimizer._to_configspace_configs
which calls aDataframe.iterrows()
method. As per the pandas documentation onpandas.Dataframe.iterrows
, the iterrows method does not preservedtypes
when consumed (see note 1).Unless I am using the API wrong, the change seems to be a simple fix to the
SmacOptimizer._to_configspace_configs
method to use NamedTuples. I can submit a PR if this issue is real.The text was updated successfully, but these errors were encountered: