(self, labels, indexes, cost=None, examples=None)
return self
Updating repository with queried information.

        The elements in the parameters should be one-to-one correspondence.

        Parameters
        ----------
        labels: {list, numpy.ndarray}
            Labels to be updated.

        indexes: {list, numpy.ndarray, IndexCollection}
            Indexes of selected instances.

        cost: array-like or object, optional (default=None)
            cost corresponds to the query.

        examples: array-like or object, optional (default=None)
            examples to be updated.
Updating repository with queried information.
Updating repository with queried information .
def update_query(self, labels, indexes, cost=None, examples=None):
        """Updating repository with queried information.

        The elements in the parameters should be one-to-one correspondence.

        Parameters
        ----------
        labels: {list, numpy.ndarray}
            Labels to be updated.

        indexes: {list, numpy.ndarray, IndexCollection}
            Indexes of selected instances.

        cost: array-like or object, optional (default=None)
            cost corresponds to the query.

        examples: array-like or object, optional (default=None)
            examples to be updated.
        """
        if not check_one_to_one_correspondence(labels, indexes, cost, examples):
            raise ValueError("Different length of parameters found. "
                             "They should have the same length and is one-to-one correspondence.")
        labels, indexes, cost, examples = unpack(labels, indexes, cost, examples)
        if not isinstance(indexes, (list, np.ndarray, BaseCollection)):
            self.add(label=labels, select_index=indexes, cost=cost, example=examples)
        else:
            for i in range(len(indexes)):
                self.add(label=labels[i], select_index=indexes[i], cost=cost[i] if cost is not None else None,
                         example=examples[i] if examples is not None else None)
        self.num_of_queries += 1
        self._update_query_history(labels, indexes, cost)
        return self
def update_query ( self , labels , indexes , cost = None , examples = None ) : if not check_one_to_one_correspondence ( labels , indexes , cost , examples ) : raise ValueError ( "Different length of parameters found. " "They should have the same length and is one-to-one correspondence." ) labels , indexes , cost , examples = unpack ( labels , indexes , cost , examples ) if not isinstance ( indexes , ( list , np . ndarray , BaseCollection ) ) : self . add ( label = labels , select_index = indexes , cost = cost , example = examples ) else : for i in range ( len ( indexes ) ) : self . add ( label = labels [ i ] , select_index = indexes [ i ] , cost = cost [ i ] if cost is not None else None , example = examples [ i ] if examples is not None else None ) self . num_of_queries += 1 self . _update_query_history ( labels , indexes , cost ) return self