code: def to_json(data: Any) -> str:
      return json.dumps(_converter.unstructure(data), indent=2)
  
file_path: H2O/h2o_hf/helm/src/helm/common/codec.py
imports: import dataclasses
  import json
  import typing
  from typing import Any, Callable, Dict, List, Union, Type, TypeVar
  from helm.benchmark.augmentations.dialect_perturbation import DialectPerturbation
  from helm.benchmark.augmentations.extra_space_perturbation import ExtraSpacePerturbation
  from helm.benchmark.augmentations.filler_words_perturbation import FillerWordsPerturbation
  from helm.benchmark.augmentations.gender_perturbation import GenderPerturbation
  from helm.benchmark.augmentations.misspelling_perturbation import MisspellingPerturbation
  from helm.benchmark.augmentations.person_name_perturbation import PersonNamePerturbation
  from helm.benchmark.augmentations.space_perturbation import SpacePerturbation
  from helm.benchmark.augmentations.synonym_perturbation import SynonymPerturbation
  from helm.benchmark.augmentations.typos_perturbation import TyposPerturbation
  from helm.benchmark.augmentations.perturbation_description import PerturbationDescription
  import cattrs
  from cattrs.gen import make_dict_structure_fn, make_dict_unstructure_fn
label_desc: Use image node_id 3 for calling a global function with example usage: to_json(data) and returns: json