code: def should_use_cudnn(level, lowest_version=0):
      """Determines if we should use cuDNN.
  
      This function checks ``chainer.config.use_cudnn``,
      ``chainer.backends.cuda.cudnn_enabled``, and the cuDNN version. Note that
      ``cudnn_enabled`` flag is fixed at loading of :mod:`chainer` module.
  
      Args:
          level (str): cuDNN use level. It must be either ``'==always'`` or
              ``'>=auto'``. ``'==always'`` indicates that the ``use_cudnn``
              config must be ``'always'`` to use cuDNN.
          lowest_version (int): Required lowest cuDNN version. It must be
              non-negative.
  
      Returns:
          bool: ``True`` if the caller should use cuDNN.
  
      """
      if _cudnn_version < lowest_version:
          return False
  
      if level not in _SHOULD_USE_CUDNN:
          raise ValueError(
              "invalid cuDNN use level: %s "
              '(must be either of "==always" or ">=auto")' % repr(level)
          )
      flags = _SHOULD_USE_CUDNN[level]
  
      use_cudnn = config.use_cudnn
      if use_cudnn not in flags:
          raise ValueError(
              "invalid use_cudnn configuration: %s "
              '(must be either of "always", "auto", or "never")'
              % repr(use_cudnn)
          )
      return flags[use_cudnn]
  
imports: import binascii
  import functools
  import itertools
  import os
  import threading
  import time
  import typing
  import warnings
  import numpy
  import six
  import chainer
  from chainer import _backend
  from chainer.backends import _cpu
  from chainer.backends import intel64
  from chainer.configuration import config
  from chainer import types
  import chainerx
label_desc: Use image node_id 21 for calling a global function with example usage: should_use_cudnn(level, lowest_version) and returns: flags, False