Source code for airtest.aircv.error

#!/usr/bin/env python
# -*- coding: utf-8 -*-

"""
Declaration:
    Define all BaseError Classes used in aircv.
"""


[docs]class BaseError(Exception): """Base class for exceptions in this module.""" def __init__(self, message=""): self.message = message def __repr__(self): return repr(self.message)
[docs]class FileNotExistError(BaseError): """Image does not exist."""
[docs]class TemplateInputError(BaseError): """Resolution input is not right."""
[docs]class NoSIFTModuleError(BaseError): """Resolution input is not right."""
[docs]class NoSiftMatchPointError(BaseError): """Exception raised for errors 0 sift points found in the input images."""
[docs]class SiftResultCheckError(BaseError): """Exception raised for errors 0 sift points found in the input images."""
[docs]class HomographyError(BaseError): """In homography, find no mask, should kill points which is duplicate."""
[docs]class NoModuleError(BaseError): """Resolution input is not right."""
[docs]class NoMatchPointError(BaseError): """Exception raised for errors 0 keypoint found in the input images."""
[docs]class MatchResultCheckError(BaseError): """Exception raised for errors 0 keypoint found in the input images."""