code: def test_data_config(
      dataset_type, features, excluded_columns, predicted_label
  ):
      # facets in input dataset
      s3_data_input_path = "s3://path/to/input.csv"
      s3_output_path = "s3://path/to/output"
      label_name = "Label"
      headers = ["Label", "F1", "F2", "F3", "F4", "Predicted Label"]
      segment_config = [
          SegmentationConfig(
              name_or_index="F1",
              segments=[[0]],
              config_name="c1",
              display_aliases=["a1"],
          )
      ]
  
      data_config = DataConfig(
          s3_data_input_path=s3_data_input_path,
          s3_output_path=s3_output_path,
          features=features,
          label=label_name,
          headers=headers,
          dataset_type=dataset_type,
          excluded_columns=excluded_columns,
          predicted_label=predicted_label,
          segmentation_config=segment_config,
      )
  
      expected_config = {
          "dataset_type": dataset_type,
          "headers": headers,
          "label": "Label",
          "segment_config": [
              {
                  "config_name": "c1",
                  "display_aliases": ["a1"],
                  "name_or_index": "F1",
                  "segments": [[0]],
              }
          ],
      }
      if features:
          expected_config["features"] = features
      if excluded_columns:
          expected_config["excluded_columns"] = excluded_columns
      if predicted_label:
          expected_config["predicted_label"] = predicted_label
  
      assert expected_config == data_config.get_config()
      assert s3_data_input_path == data_config.s3_data_input_path
      assert s3_output_path == data_config.s3_output_path
      assert "None" == data_config.s3_compression_type
      assert "FullyReplicated" == data_config.s3_data_distribution_type
  
imports: from __future__ import absolute_import, print_function
  import copy
  import pytest
  from mock import MagicMock, Mock, patch
  from sagemaker import Processor, image_uris
  from sagemaker.clarify import BiasConfig, DataConfig, ModelConfig, ModelPredictedLabelConfig, PDPConfig, SageMakerClarifyProcessor, SHAPConfig, TextConfig, ImageConfig, _AnalysisConfigGenerator, DatasetType, ProcessingOutputHandler, SegmentationConfig
label_desc: Use image node_id 2 for calling a global function with example usage: test_data_config(dataset_type, features, excluded_columns, predicted_label) without return types