docs: def from_data(data, conv=None, pinf=float('inf'), ninf=float('-inf')):
      """
      Import an interval from a piece of data.
  
      :param data: a list of 4-uples (left, lower, upper, right).
      :param conv: function that is used to convert "lower" and "upper" to bounds, default to identity.
      :param pinf: value used to represent positive infinity.
      :param ninf: value used to represent negative infinity.
      :return: an Interval instance.
      """
      intervals = []
      conv = (lambda v: v) if conv is None else conv
  
      def _convert(bound):
          if bound == pinf:
              return inf
          elif bound == ninf:
              return -inf
          else:
              return conv(bound)
  
      for item in data:
          left, lower, upper, right = item
          intervals.append(AtomicInterval(
              left,
              _convert(lower),
              _convert(upper),
              right
          ))
      return Interval(*intervals)