code: def convert_base(text: str) -> str:
      try:
          return BASE_FREQ_TO_PANDAS_OFFSET[text]
      except KeyError:
          raise GluonTSDataError(
              f'"{text}" is not recognized as a frequency string'
          )
  
imports: from datetime import datetime
  from distutils.util import strtobool
  from types import SimpleNamespace
  from typing import Dict
  import numpy
  from toolz import compose_left
  from gluonts import json
  from gluonts.exceptions import GluonTSDataError
label_desc: Use image node_id 3 for calling a global function with example usage: convert_base(text) and returns: BASE_FREQ_TO_PANDAS_OFFSET