code: def get_encoding(encoding_name: str) -> Encoding:
      if encoding_name in ENCODINGS:
          return ENCODINGS[encoding_name]
  
      with _lock:
          if encoding_name in ENCODINGS:
              return ENCODINGS[encoding_name]
  
          if ENCODING_CONSTRUCTORS is None:
              _find_constructors()
              assert ENCODING_CONSTRUCTORS is not None
  
          if encoding_name not in ENCODING_CONSTRUCTORS:
              raise ValueError(
                  f"Unknown encoding {encoding_name}. Plugins found: {_available_plugin_modules()}"
              )
  
          constructor = ENCODING_CONSTRUCTORS[encoding_name]
          enc = Encoding(**constructor())
          ENCODINGS[encoding_name] = enc
          return enc
  
file_path: tiktoken/tiktoken/registry.py
imports: from __future__ import annotations
  import functools
  import importlib
  import pkgutil
  import threading
  from typing import Any, Callable, Optional, Sequence
  import tiktoken_ext
  from tiktoken.core import Encoding
label_desc: Use image node_id 3 for calling a global function with example usage: get_encoding(encoding_name) and returns: ENCODINGS, enc, ENCODINGS