docs: def _choose_unit(value, unit=None, asciimode=None):
      """
      Finds a good unit to print seconds in
  
      Args:
          value (float): measured value in seconds
          unit (str): if specified, overrides heuristic decision
          asciimode (bool): if True, forces ascii for microseconds
  
      Returns:
          tuple[(str, float)]: suffix, mag:
              string suffix and conversion factor
  
      Example:
          >>> assert _choose_unit(1.1, unit=None)[0] == 's'
          >>> assert _choose_unit(1e-2, unit=None)[0] == 'ms'
          >>> assert _choose_unit(1e-4, unit=None, asciimode=True)[0] == 'us'
          >>> assert _choose_unit(1.1, unit='ns')[0] == 'ns'
      """
      from collections import OrderedDict
      micro = _trychar('µs', 'us', asciimode)
      units = OrderedDict([
          ('s', ('s', 1e0)),
          ('ms', ('ms', 1e-3)),
          ('us', (micro, 1e-6)),
          ('ns', ('ns', 1e-9)),
      ])
      if unit is None:
          for suffix, mag in units.values():  # pragma: nobranch
              if value > mag:
                  break
      else:
          suffix, mag = units[unit]
      return suffix, mag