def validate_frame_number(value):
    """Validates that the provided value is a frame number.

    Frame numbers are strictly positive integers.

    Args:
        value: a value

    Raises:
        :class:`FrameError`: if ``value`` is not a frame number
    """
    if not isinstance(value, numbers.Integral):
        raise FrameError(
            "Frame numbers must be integers; found %s" % type(value)
        )

    if value < 1:
        raise FrameError(
            "Frame numbers must be 1-based integers; found %s" % value
        )
Validates that the provided value is a frame number.

    Frame numbers are strictly positive integers.

    Args:
        value: a value

    Raises:
        :class:`FrameError`: if ``value`` is not a frame number
    
fiftyone/core/frame_utils.py