class_docstr: Base class for scoring.
  
  Subclass and implement an ``on_*`` method before using.
class_docstr_tok: ["Base","class","for","scoring",".","Subclass","and","implement","an","``","on_","*","``","method","before","using","."]
code: def __init__(
      self,
      scoring,
      lower_is_better=True,
      on_train=False,
      name=None,
      target_extractor=to_numpy,
      use_caching=True,
  ):
      self.scoring = scoring
      self.lower_is_better = lower_is_better
      self.on_train = on_train
      self.name = name
      self.target_extractor = target_extractor
      self.use_caching = use_caching
  
imports: from contextlib import contextmanager
  from contextlib import suppress
  from functools import partial
  import warnings
  import numpy
  import sklearn
  from sklearn.metrics import make_scorer, check_scoring
  from skorch.callbacks import Callback
  from skorch.dataset import unpack_data
  from sklearn.metrics._scorer import _BaseScorer
  from skorch.utils import data_from_dataset
  from skorch.utils import is_skorch_dataset
  from skorch.utils import to_numpy
  from skorch.utils import check_indexing
  from skorch.utils import to_device
label_desc: Use image node_id 1 to create a new ScoringBase object from inherited base classes: Callback with example: obj = ScoringBase(scoring, lower_is_better, on_train, name, target_extractor, use_caching)