code: def enable_librarymode():
      """Request DataLad to operate in library mode.
  
      This function should be executed immediately after importing the `datalad`
      package, when DataLad is not used as an application, or in interactive
      scenarios, but as a utility library inside other applications. Enabling
      this mode will turn off some convenience feature that are irrelevant in
      such use cases (with performance benefits), and alters it messaging
      behavior to better interoperate with 3rd-party front-ends.
  
      Library mode can only be enabled once. Switching it on and off within
      the runtime of a process is not supported.
  
      Example::
  
          >>> import datalad
          >>> datalad.enable_librarymode()
      """
      global __runtime_mode
      __runtime_mode = "library"
      # export into the environment for child processes to inherit
      os.environ["DATALAD_RUNTIME_LIBRARYMODE"] = "1"
  
file_path: datalad/datalad/__init__.py
imports: import atexit
  import os
  from .config import ConfigManager, warn_on_undefined_git_identity
  from datalad.utils import get_encoding_info, get_envvars_info, getpwd
  from .log import lgr
  from .support.sshconnector import SSHManager
  from ._version import get_versions
label_desc: Use image node_id 3 for calling a global function with example usage: enable_librarymode() without return types