code: def initializeParams(config: Optional[dict] = None) -> dict:
      """
      Arrange a chefboost configuration
      Args:
          config (dict): initial configuration
      Returns:
          config (dict): final configuration
      """
      if config == None:
          config = {}
  
      algorithm = "ID3"
      enableRandomForest = False
      num_of_trees = 5
      enableMultitasking = False
      enableGBM = False
      epochs = 10
      learning_rate = 1
      max_depth = 5
      enableAdaboost = False
      num_of_weak_classifier = 4
      enableParallelism = True
      num_cores = int(
          multiprocessing.cpu_count() / 2
      )  # allocate half of your total cores
      # num_cores = int((3*multiprocessing.cpu_count())/4) #allocate 3/4 of your total cores
      # num_cores = multiprocessing.cpu_count()
  
      for key, value in config.items():
          if key == "algorithm":
              algorithm = value
          # ---------------------------------
          elif key == "enableRandomForest":
              enableRandomForest = value
          elif key == "num_of_trees":
              num_of_trees = value
          elif key == "enableMultitasking":
              enableMultitasking = value
          # ---------------------------------
          elif key == "enableGBM":
              enableGBM = value
          elif key == "epochs":
              epochs = value
          elif key == "learning_rate":
              learning_rate = value
          elif key == "max_depth":
              max_depth = value
          # ---------------------------------
          elif key == "enableAdaboost":
              enableAdaboost = value
          elif key == "num_of_weak_classifier":
              num_of_weak_classifier = value
          # ---------------------------------
          elif key == "enableParallelism":
              enableParallelism = value
          elif key == "num_cores":
              num_cores = value
  
      config["algorithm"] = algorithm
      config["enableRandomForest"] = enableRandomForest
      config["num_of_trees"] = num_of_trees
      config["enableMultitasking"] = enableMultitasking
      config["enableGBM"] = enableGBM
      config["epochs"] = epochs
      config["learning_rate"] = learning_rate
      config["max_depth"] = max_depth
      config["enableAdaboost"] = enableAdaboost
      config["num_of_weak_classifier"] = num_of_weak_classifier
      config["enableParallelism"] = enableParallelism
      config["num_cores"] = num_cores
  
      return config
  
imports: import pathlib
  import os
  import sys
  from os import path
  from types import ModuleType
  import multiprocessing
  from typing import Optional, Union
  import numpy
  import pandas
  from chefboost import Chefboost
  from chefboost.commons.logger import Logger
  from chefboost.commons.module import load_module
label_desc: Use image node_id 9 for calling a global function with example usage: initializeParams(config) and returns: config