When all input features in an optimization are categorical/discrete, if only one category is allowed for the categorical features, then it will break. This is because the fixed feature is not included when self.domain.inputs.get_categorical_combinations() is used to generate the choices DataFrame. This results in the subsequent merged DataFrame having a column of NaN's for the fixed feature
This PR will fix this issue by adding in the fixed feature into choices before generating merged.
I have not included a test yet for this because I am not sure on where to place it in the folder. @jduerholt Where is the best place for this?
When all input features in an optimization are categorical/discrete, if only one category is allowed for the categorical features, then it will break. This is because the fixed feature is not included when
self.domain.inputs.get_categorical_combinations()
is used to generate thechoices
DataFrame. This results in the subsequentmerged
DataFrame having a column of NaN's for the fixed featureThis PR will fix this issue by adding in the fixed feature into
choices
before generatingmerged
.I have not included a test yet for this because I am not sure on where to place it in the folder. @jduerholt Where is the best place for this?