class_docstr: Class which contains abstract methods for data preprocessing.
class_docstr_tok: ["Class","which","contains","abstract","methods","for","data","preprocessing","."]
docstr: Combines two preprocessor's objects.
  
  Args:
      api_preprocessor: the one from the API
      pipeline_preprocessor: the one from the obtained pipeline
  
  Returns:
      merged preprocessor
docstr_tok: ["Combines","two","preprocessor","'s","objects",".","Args",":","api_preprocessor",":","the","one","from","the","API","pipeline_preprocessor",":","the","one","from","the","obtained","pipeline","Returns",":","merged","preprocessor"]
code: def merge_preprocessors(
      api_preprocessor: "BasePreprocessor",
      pipeline_preprocessor: "BasePreprocessor",
      use_auto_preprocessing: bool,
  ) -> "BasePreprocessor":
      """
      Combines two preprocessor's objects.
  
      Args:
          api_preprocessor: the one from the API
          pipeline_preprocessor: the one from the obtained pipeline
  
      Returns:
          merged preprocessor
      """
      # If was used auto preprocessor
      if use_auto_preprocessing:
          # Take all obligatory data preprocessing from obtained pipelines
          new_data_preprocessor = api_preprocessor
  
      # If was used pipelines preprocessors
      else:
          # Take all obligatory data preprocessing from API
          new_data_preprocessor = api_preprocessor
  
          # Update optional preprocessing (take it from obtained pipeline)
          if not new_data_preprocessor.features_encoders:
              # Store features encoder from obtained pipeline because in API there are no encoding
              new_data_preprocessor.features_encoders = (
                  pipeline_preprocessor.features_encoders
              )
  
          if not new_data_preprocessor.features_imputers:
              # Same with Nan's imputers
              new_data_preprocessor.features_imputers = (
                  pipeline_preprocessor.features_imputers
              )
  
      return new_data_preprocessor
  
imports: from abc import ABC, abstractmethod
  from typing import Dict, Union, TYPE_CHECKING
  import numpy
  from sklearn.preprocessing import LabelEncoder
  from fedot.core.data.data import InputData, OutputData
  from fedot.core.data.multi_modal import MultiModalData
  from fedot.core.operations.evaluation.operation_implementations.data_operations.categorical_encoders import LabelEncodingImplementation, OneHotEncodingImplementation
  from fedot.core.operations.evaluation.operation_implementations.data_operations.sklearn_transformations import ImputationImplementation
  from fedot.preprocessing.categorical import BinaryCategoricalPreprocessor
  from fedot.preprocessing.data_types import TableTypesCorrector
  from fedot.preprocessing.structure import DEFAULT_SOURCE_NAME
  from fedot.utilities.custom_errors import AbstractMethodNotImplementError
label_desc: Use image node_id 14 for calling the BasePreprocessor obj's underlying member method code with example usage: obj.merge_preprocessors(api_preprocessor, pipeline_preprocessor, use_auto_preprocessing) and returns: new_data_preprocessor