code: def is_notebook():
      """Check if running in a notebook"""
      try:
          from IPython import get_ipython
  
          if (
              "IPKernelApp" not in get_ipython().config
          ):  # pragma: no cover
              raise ImportError("console")
              return False
          if "VSCODE_PID" in os.environ:  # pragma: no cover
              raise ImportError("vscode")
              return False
      except:
          return False
      else:  # pragma: no cover
          return True
  
imports: import hashlib
  import json
  import logging
  import os
  import pandas
  import pandas.util
  import platform
  import random
  import string
  import uuid
  import warnings
  from functools import lru_cache
  from typing import Any
  from collections import UserDict
  from .constants import VERBOSE, CACHE_COERCION_SIZE, TRACE
label_desc: Use image node_id 19 for calling a global function with example usage: is_notebook() and returns: True, False, False, False