class_docstr: Defines the ErrorAnalysisManager for discovering errors in a model.
class_docstr_tok: ["Defines","the","ErrorAnalysisManager","for","discovering","errors","in","a","model","."]
docstr: Save the ErrorAnalysisManager to the given path.
  
  :param path: The directory path to save the ErrorAnalysisManager to.
  :type path: str
docstr_tok: ["Save","the","ErrorAnalysisManager","to","the","given","path",".",":","param","path",":","The","directory","path","to","save","the","ErrorAnalysisManager","to",".",":","type","path",":","str"]
code: def _save(self, path):
      """Save the ErrorAnalysisManager to the given path.
  
      :param path: The directory path to save the ErrorAnalysisManager to.
      :type path: str
      """
      top_dir = Path(path)
      top_dir.mkdir(parents=True, exist_ok=True)
  
      if len(self._ea_config_list) != len(self._ea_report_list):
          raise ConfigAndResultMismatchException(
              "The number of error analysis configs {0} doesn't match the "
              "number of results {1}".format(
                  len(self._ea_config_list), len(self._ea_report_list)
              )
          )
  
      for index in range(0, len(self._ea_report_list)):
          # save the configs
          directory_manager = DirectoryManager(
              parent_directory_path=path
          )
          config_path = (
              directory_manager.create_config_directory()
              / f"config{FileFormats.JSON}"
          )
          ea_config = self._ea_config_list[index]
          with open(config_path, "w") as file:
              json.dump(ea_config, file, default=config_json_converter)
  
          # save the reports
          report_path = (
              directory_manager.create_data_directory()
              / f"report{FileFormats.JSON}"
          )
          ea_report = self._ea_report_list[index]
          with open(report_path, "w") as file:
              json.dump(ea_report, file, default=report_json_converter)
  
imports: import json
  import warnings
  from pathlib import Path
  from typing import Any, List, Optional
  import jsonschema
  import pandas
  from erroranalysis._internal.constants import metric_to_display_name
  from erroranalysis._internal.error_analyzer import ModelAnalyzer
  from erroranalysis._internal.error_report import as_error_report
  from erroranalysis._internal.error_report import json_converter
  from raiutils.exceptions import UserConfigValidationException
  from raiutils.models import ModelTask
  from responsibleai._config.base_config import BaseConfig
  from responsibleai._interfaces import ErrorAnalysisData
  from responsibleai._internal.constants import ErrorAnalysisManagerKeys
  from responsibleai._internal.constants import FileFormats, ListProperties, ManagerNames
  from responsibleai._tools.shared.state_directory_management import DirectoryManager
  from responsibleai.exceptions import ConfigAndResultMismatchException, DuplicateManagerConfigException
  from responsibleai.managers.base_manager import BaseManager
  from responsibleai.utils import _find_features_having_missing_values, _measure_time
label_desc: Use image node_id 10 for calling the ErrorAnalysisManager obj's underlying member method code with example usage: obj._save(path) without return types