Environment Anomaly Detection using standard machine learning techniques.
The technique uses PCA and KMeans to detect anomaly. The code is based on the paper: Click Here
Blog link: Click Here
detect_anomaly.Anomaly (first_image_path = None, second_image_path = None, block_size = 5, return_diff = False)
Image path of the first image of the particular location
Image path of the second image of the same location
Size of the window that will be used to create eigen space and vector space
- Default: 5 if not set
- Choose it to be an odd number
If you want function to return difference image as well
Image matrix depicting the change.
- Black region showing no change
- White region showing change
Difference image is the absolute difference between two given image.
- import detect_anomaly
- create object using detect_anomaly.Anomaly() and pass required parameters.
- call method of the obect: detect() and store the results.