docstr: Return the mean accuracy on the given test data and labels.
  
  In multi-label classification, this is the subset accuracy
  which is a harsh metric since you require for each sample that
  each label set be correctly predicted.
  
  This matches the scikit-learn implementation with the differences
  that
  
  * :meth:`dask_ml.metrics.accuracy_score` is used rather than
    :meth:`sklearn.metrics.accuracy_score`.
  * The ``'uniform_average'`` method is used for multioutput results
    rather than ``'variance_weighted'``.
  
  Parameters
  ----------
  X : array-like of shape (n_samples, n_features)
      Test samples.
  
  y : array-like of shape (n_samples,) or (n_samples, n_outputs)
      True labels for X.
  
  sample_weight : array-like of shape (n_samples,), default=None
      Sample weights.
  
  Returns
  -------
  score : float
      Mean accuracy of self.predict(X) wrt. y.
docstr_tok: ["Return","the","mean","accuracy","on","the","given","test","data","and","labels",".","In","multi-label","classification",",","this","is","the","subset","accuracy","which","is","a","harsh","metric","since","you","require","for","each","sample","that","each","label","set","be","correctly","predicted",".","This","matches","the","scikit-learn","implementation","with","the","differences","that","*",":","meth",":","`","dask_ml.metrics.accuracy_score","`","is","used","rather","than",":","meth",":","`","sklearn.metrics.accuracy_score","`",".","*","The","``","'uniform_average","'","``","method","is","used","for","multioutput","results","rather","than","``","'variance_weighted","'","``",".","Parameters","--","--","--","--","--","X",":","array-like","of","shape","(","n_samples",",","n_features",")","Test","samples",".","y",":","array-like","of","shape","(","n_samples",",",")","or","(","n_samples",",","n_outputs",")","True","labels","for","X.","sample_weight",":","array-like","of","shape","(","n_samples",",",")",",","default=None","Sample","weights",".","Returns","--","--","--","-","score",":","float","Mean","accuracy","of","self.predict","(","X",")","wrt",".","y","."]
code: def score(self, X, y, sample_weight=None):
      """
      Return the mean accuracy on the given test data and labels.
  
      In multi-label classification, this is the subset accuracy
      which is a harsh metric since you require for each sample that
      each label set be correctly predicted.
  
      This matches the scikit-learn implementation with the differences
      that
  
      * :meth:`dask_ml.metrics.accuracy_score` is used rather than
        :meth:`sklearn.metrics.accuracy_score`.
      * The ``'uniform_average'`` method is used for multioutput results
        rather than ``'variance_weighted'``.
  
      Parameters
      ----------
      X : array-like of shape (n_samples, n_features)
          Test samples.
  
      y : array-like of shape (n_samples,) or (n_samples, n_outputs)
          True labels for X.
  
      sample_weight : array-like of shape (n_samples,), default=None
          Sample weights.
  
      Returns
      -------
      score : float
          Mean accuracy of self.predict(X) wrt. y.
      """
      from .metrics import r2_score
  
      y_pred = self.predict(X)
      return r2_score(
          y,
          y_pred,
          sample_weight=sample_weight,
          multioutput="uniform_average",
      )
  
file_path: dask-ml/dask_ml/base.py
imports: import sklearn.base
  from .utils import _check_y, check_array, check_X_y
label_desc: Use image node_id 1 for calling the RegressorMixin obj's underlying member method code with example usage: obj.score(X, y, sample_weight) and returns: r2_score