code: def get_retry_from_headers_or_default(headers, retry_count):
      try:
          return (
              int(headers["retry-after"][0])
              if "retry-after" in headers
              else 2 ** min(MAX_RETRY_MULTIPLIER, retry_count)
          )
      except Exception:
          return min(
              2 ** min(MAX_RETRY_MULTIPLIER, retry_count),
              MAX_RETRY_TIME,
          )
  
file_path: neptune-client/src/neptune/common/backends/utils.py
imports: import itertools
  import logging
  import os
  import time
  import requests
  from bravado.exception import BravadoConnectionError, BravadoTimeoutError, HTTPBadGateway, HTTPClientError, HTTPForbidden, HTTPGatewayTimeout, HTTPInternalServerError, HTTPRequestTimeout, HTTPServiceUnavailable, HTTPTooManyRequests, HTTPUnauthorized
  from bravado_core.util import RecursiveCallException
  from requests.exceptions import ChunkedEncodingError
  from urllib3.exceptions import NewConnectionError
  from neptune.common.envs import NEPTUNE_RETRIES_TIMEOUT_ENV
  from neptune.common.exceptions import ClientHttpError, Forbidden, NeptuneAuthTokenExpired, NeptuneConnectionLostException, NeptuneInvalidApiTokenException, Unauthorized
label_desc: Use image node_id 1 for calling a global function with example usage: get_retry_from_headers_or_default(headers, retry_count) and returns: unknown, min