class_docstr: Class implements wrapper for sklearn components for feature extraction,
  feature selection, classification, regression etc.
  
  Args:
      model_class: string with full name of sklearn model to use, e.g. ``sklearn.linear_model:LogisticRegression``
      save_path: save path for model, e.g. full name ``model_path/model.pkl``             or prefix ``model_path/model`` (still model will be saved to ``model_path/model.pkl``)
      load_path: load path for model, e.g. full name ``model_path/model.pkl``             or prefix ``model_path/model`` (still model will be loaded from ``model_path/model.pkl``)
      infer_method: string name of class method to use for infering model,             e.g. ``predict``, ``predict_proba``, ``predict_log_proba``, ``transform``
      ensure_list_output: whether to ensure that output for each sample is iterable (but not string)
      kwargs: dictionary with parameters for the sklearn model
  
  Attributes:
      model: sklearn model instance
      model_class: string with full name of sklearn model to use, e.g. ``sklearn.linear_model:LogisticRegression``
      model_params: dictionary with parameters for the sklearn model without pipe parameters
      pipe_params: dictionary with parameters for pipe: ``in``, ``out``, ``fit_on``, ``main``, ``name``
      save_path: save path for model, e.g. full name ``model_path/model.pkl``             or prefix ``model_path/model`` (still model will be saved to ``model_path/model.pkl``)
      load_path: load path for model, e.g. full name ``model_path/model.pkl``             or prefix ``model_path/model`` (still model will be loaded from ``model_path/model.pkl``)
      infer_method: string name of class method to use for infering model,             e.g. ``predict``, ``predict_proba``, ``predict_log_proba``, ``transform``
      ensure_list_output: whether to ensure that output for each sample is iterable (but not string)
docstr: Initialize ``self.model`` as some sklearn model from scratch with given in ``self.model_params`` parameters.
  
  Returns:
      None
docstr_tok: ["Initialize","``","self.model","``","as","some","sklearn","model","from","scratch","with","given","in","``","self.model_params","``","parameters",".","Returns",":","None"]
code: def init_from_scratch(self) -> None:
      """
      Initialize ``self.model`` as some sklearn model from scratch with given in ``self.model_params`` parameters.
  
      Returns:
          None
      """
      log.debug(
          "Initializing model {} from scratch".format(self.model_class)
      )
      model_function = cls_from_str(self.model_class)
  
      if model_function is None:
          raise ConfigError(
              "Model with {} model_class was not found.".format(
                  self.model_class
              )
          )
  
      given_params = {}
      if self.model_params:
          available_params = self.get_function_params(model_function)
          for param_name in self.model_params.keys():
              if param_name in available_params:
                  try:
                      given_params[param_name] = cls_from_str(
                          self.model_params[param_name]
                      )
                  except (AttributeError, ValueError, ConfigError):
                      given_params[param_name] = self.model_params[
                          param_name
                      ]
  
      self.model = model_function(**given_params)
      return
  
imports: import inspect
  import pickle
  from logging import getLogger
  from pathlib import Path
  from typing import List, Tuple, Union, Callable
  import numpy
  from scipy.sparse import issparse, csr_matrix
  from scipy.sparse import spmatrix
  from scipy.sparse import vstack, hstack
  from deeppavlov.core.common.errors import ConfigError
  from deeppavlov.core.common.registry import register, cls_from_str
  from deeppavlov.core.models.estimator import Estimator
label_desc: Use image node_id 4 for calling the SklearnComponent obj's underlying member method code with example usage: obj.init_from_scratch() without return types