- class miml.classifier.mi.apr_classifier.APRClassifier#
Bases:
object
Approach is to construct an APR by starting with a single positive instance and “growing” the APR by expanding it to cover additional positive instances. We call it the “iterated discrimination” algorithm, and it has three basic procedures: -Grow. An algorithm for growing an APR with “tight” bounds along a specified set of features. -Discriminate. An algorithm for choosing a set of discriminating features by analyzing an APR. -Expand. An algorithm for expanding the bounds of an APR to improve its generalization ability.
Attributes#
- classifier
Classifier used from mil library
References#
Thomas G. Dietterich, Richard H. Lathrop, Tomas Lozano-Perez “Solving the multiple instance problem with axis-parallel rectangles” 1997 Model implementation rosasalberto/mil Matlab implementation DMJTax/mil
- fit(x_train: ndarray, y_train: ndarray) None #
Fit the classifier to the training data.
Parameters#
- x_trainndarray of shape (n_bags, n_instances, n_features)
Features values of bags in the training set.
- y_trainndarray (n_bags, n_instances, n_labels)
Labels of bags in the training set.