code: def fit_add_mfgp_with_dataset(dataset, kernel_type):
      """Fits a GP with the dataset."""
      options = _get_mf_gp_options(dataset.tune_noise)
      options.fidel_kernel_type = kernel_type
      options.domain_kernel_type = kernel_type
      options.domain_use_additive_gp = True
      options.mean_func_type = "median"
      options.domain_matern_nu = 2.5
      options.fidel_matern_nu = 2.5
      options.ml_hp_tune_opt = "direct"
      ret_fit_gp = (
          euclidean_gp.EuclideanMFGPFitter(
              dataset.Z_tr, dataset.X_tr, dataset.Y_tr, options=options
          )
      ).fit_gp()
      assert ret_fit_gp[0] == "fitted_gp"
      return ret_fit_gp[1]
  
imports: from __future__ import division
  from argparse import Namespace
  from copy import deepcopy
  import numpy
  from .None import kernel
  from .unittest_euclidean_gp import fit_se_gp_with_dataset, fit_matern_gp_with_dataset, fit_poly_gp_with_dataset
  from .None import euclidean_gp
  from ..utils.base_test_class import BaseTestClass, execute_tests
  from ..utils.general_utils import compute_average_sq_prediction_error
  from ..utils.option_handler import load_options
label_desc: Use image node_id 13 for calling a global function with example usage: fit_add_mfgp_with_dataset(dataset, kernel_type) and returns: ret_fit_gp