code: def extension_context(extension_name='cpu', **kw):
      
      from nnabla import logger
      logger.warn(
          'Deprecated API. Use `nnabla.ext_util.get_extension_context(ext_name, **kw)`.')
      from nnabla.ext_utils import get_extension_context
      return get_extension_context(extension_name, **kw)
docs: Get the context of the specified extension.
  
      All extension's module must provide `context(**kw)` function.
  
      Args:
          extension_name (str) : Module path relative to `nnabla_ext`.
          kw (dict) : Additional keyword arguments for context function in a extension module.
  
      Returns:
          :class:`nnabla.Context`: The current extension context.
  
      Note:
          Deprecated. Use :function:`nnabla.ext_utils.get_extension_context` instead.
  
      Example:
  
          .. code-block:: python
  
              ctx = extension_context('cuda.cudnn', device_id=0)
              nn.set_default_context(ctx)