Skip to content

Bug with LinearSVC training  #154

@prabhant

Description

@prabhant

This bug makes sense because LinearSVC does not support probabilities by default I think
reference here: https://stackoverflow.com/questions/47312432/attributeerrorlinearsvc-object-has-no-attribute-predict-proba

Traceback (most recent call last):
  File "/home/singhp/metalearning_experiments/gama/gama-warm-pretraining.py", line 35, in <module>
    probability_predictions = automl.predict_proba(X_test)
  File "/home/singhp/metalearning_experiments/gama/gama/GamaClassifier.py", line 94, in predict_proba
    return self._predict_proba(x)
  File "/home/singhp/metalearning_experiments/gama/gama/GamaClassifier.py", line 75, in _predict_proba
    return self.model.predict_proba(x)  # type: ignore
  File "/home/singhp/miniconda3/envs/imbalance/lib/python3.9/site-packages/sklearn/utils/metaestimators.py", line 114, in __get__
    getattr(delegate, self.attribute_name)
AttributeError: 'LinearSVC' object has no attribute 'predict_proba'

Maybe an IF Condition if GAMA outputs linear SVC can be inserted with extra arguments.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions