docs: def get_spherical_bounding_box(lons, lats):
      """
      Given a collection of points find and return the bounding box,
      as a pair of longitudes and a pair of latitudes.
  
      Parameters define longitudes and latitudes of a point collection
      respectively in a form of lists or numpy arrays.
  
      :return:
          A tuple of four items. These items represent western, eastern,
          northern and southern borders of the bounding box respectively.
          Values are floats in decimal degrees.
      :raises ValueError:
          If points collection has the longitudinal extent of more than
          180 degrees (it is impossible to define a single hemisphere
          bound to poles that would contain the whole collection).
      """
      north, south = numpy.max(lats), numpy.min(lats)
      west, east = numpy.min(lons), numpy.max(lons)
      assert (-180 <= west <= 180) and (-180 <= east <= 180), (west, east)
      if get_longitudinal_extent(west, east) < 0:
          # points are lying on both sides of the international date line
          # (meridian 180). the actual west longitude is the lowest positive
          # longitude and east one is the highest negative.
          if hasattr(lons, 'flatten'):
              # fixes test_surface_crossing_international_date_line
              lons = lons.flatten()
          west = min(lon for lon in lons if lon > 0)
          east = max(lon for lon in lons if lon < 0)
          if not all((get_longitudinal_extent(west, lon) >= 0
                      and get_longitudinal_extent(lon, east) >= 0)
                     for lon in lons):
              raise ValueError('points collection has longitudinal extent '
                               'wider than 180 deg')
      return SphericalBB(west, east, north, south)