code: def _upgrade_preprocessing_split(
      preprocessing: PreprocessingConfigDict,
  ) -> PreprocessingConfigDict:
      """Upgrade split related parameters in preprocessing."""
      split_params = {}
  
      force_split = preprocessing.pop(FORCE_SPLIT, None)
      split_probabilities = preprocessing.pop(SPLIT_PROBABILITIES, None)
      stratify = preprocessing.pop(STRATIFY, None)
  
      if split_probabilities is not None:
          split_params[PROBABILITIES] = split_probabilities
          warnings.warn(
              "`preprocessing.split_probabilities` has been replaced by `preprocessing.split.probabilities`, "
              "will be flagged as error in v0.7",
              DeprecationWarning,
          )
  
      if stratify is not None:
          split_params[TYPE] = STRATIFY
          split_params[COLUMN] = stratify
          warnings.warn(
              "`preprocessing.stratify` has been replaced by `preprocessing.split.column` "
              'when setting `preprocessing.split.type` to "stratify", '
              "will be flagged as error in v0.7",
              DeprecationWarning,
          )
  
      if force_split is not None:
          warnings.warn(
              "`preprocessing.force_split` has been replaced by `preprocessing.split.type`, "
              "will be flagged as error in v0.7",
              DeprecationWarning,
          )
  
          if TYPE not in split_params:
              split_params[TYPE] = RANDOM
  
      if split_params:
          preprocessing[SPLIT] = split_params
  
      if AUDIO in preprocessing:
          if "audio_feature" in preprocessing[AUDIO]:
              for k, v in preprocessing[AUDIO]["audio_feature"].items():
                  preprocessing[AUDIO][k] = v
              del preprocessing[AUDIO]["audio_feature"]
          warnings.warn(
              "Parameters specified at the `audio_feature` parameter level have been unnested and should now "
              "be specified at the preprocessing level. Support for `audio_feature` will be removed in v0.7",
              DeprecationWarning,
          )
      return preprocessing
  
imports: import copy
  import logging
  import warnings
  from typing import Any, Callable, Dict, List, Union
  from ludwig.api_annotations import DeveloperAPI
  from ludwig.constants import AUDIO, BIAS, CLASS_WEIGHTS, COLUMN, CONV_BIAS, CONV_USE_BIAS, DECODER, DEFAULT_BIAS, DEFAULT_USE_BIAS, DEFAULTS, ENCODER, EVAL_BATCH_SIZE, EXECUTOR, FORCE_SPLIT, HEIGHT, HYPEROPT, IMAGE, INPUT_FEATURES, LOSS, MISSING_VALUE_STRATEGY, MODEL_ECD, MODEL_GBM, MODEL_TYPE, NAME, NUM_SAMPLES, NUMBER, OUTPUT_FEATURES, PARAMETERS, PREPROCESSING, PROBABILITIES, RANDOM, RAY, SAMPLER, SCHEDULER, SEARCH_ALG, SEQUENCE, SPLIT, SPLIT_PROBABILITIES, STRATIFY, TEXT, TIMESERIES, TRAINER, TRAINING, TYPE, USE_BIAS, WIDTH
  from ludwig.features.feature_registries import get_base_type_registry, get_input_type_registry, get_output_type_registry
  from ludwig.globals import LUDWIG_VERSION
  from ludwig.schema.defaults.gbm import GBMDefaultsConfig
  from ludwig.schema.encoders.utils import get_encoder_cls
  from ludwig.types import FeatureConfigDict, FeatureTypeDefaultsDict, HyperoptConfigDict, ModelConfigDict, PreprocessingConfigDict, TrainerConfigDict, TrainingSetMetadataDict
  from ludwig.utils.metric_utils import TrainerMetric
  from ludwig.utils.misc_utils import get_from_registry, merge_dict
  from ludwig.utils.version_transformation import VersionTransformation, VersionTransformationRegistry
label_desc: Use image node_id 18 for calling a global function with example usage: _upgrade_preprocessing_split(preprocessing) and returns: preprocessing