Skip to content

Commit

Permalink
Merge pull request #191 from neurodata/interface_base_appendage
Browse files Browse the repository at this point in the history
Append 'Base' to Classification{Decider, ProgressiveLearner} class names
  • Loading branch information
jdey4 authored Sep 18, 2020
2 parents e7853ac + 25f1497 commit eea0685
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions proglearn/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ def is_fitted(self):
pass


class ClassificationDecider(BaseDecider):
class BaseClassificationDecider(BaseDecider):
"""
A class for a decider which inherits from the base decider
but adds the functionality of estimating posteriors.
Expand Down Expand Up @@ -219,7 +219,7 @@ def predict(self, X, task_id):
pass


class ClassificationProgressiveLearner(BaseProgressiveLearner):
class BaseClassificationProgressiveLearner(BaseProgressiveLearner):
"""
A class for a progressive learner which inherits from the base progressive learner
but adds the functionality of estimating posteriors for a given task_id.
Expand Down
4 changes: 2 additions & 2 deletions proglearn/deciders.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
'''
import numpy as np

from .base import ClassificationDecider
from .base import BaseClassificationDecider

from sklearn.neighbors import KNeighborsRegressor
from sklearn.linear_model import Ridge
Expand All @@ -18,7 +18,7 @@
from sklearn.utils.multiclass import type_of_target


class SimpleArgmaxAverage(ClassificationDecider):
class SimpleArgmaxAverage(BaseClassificationDecider):
"""
Doc string here.
"""
Expand Down
6 changes: 3 additions & 3 deletions proglearn/progressive_learner.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
Corresponding Email: levinewill@icloud.com
'''
import numpy as np
from .base import ClassificationDecider, ClassificationProgressiveLearner
from .base import BaseClassificationDecider, BaseClassificationProgressiveLearner

class ProgressiveLearner(ClassificationProgressiveLearner):
class ProgressiveLearner(BaseClassificationProgressiveLearner):
"""
A class for progressive learning in the classification setting.
Expand Down Expand Up @@ -667,7 +667,7 @@ def predict(self, X, task_id, transformer_ids=None):

def predict_proba(self, X, task_id, transformer_ids=None):
decider = self.task_id_to_decider[task_id]
if isinstance(decider, ClassificationDecider):
if isinstance(decider, BaseClassificationDecider):
return self.task_id_to_decider[task_id].predict_proba(
X, transformer_ids=transformer_ids
)
Expand Down

0 comments on commit eea0685

Please sign in to comment.