This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| user nginx; | |
| worker_processes auto; | |
| error_log /var/log/nginx/error.log; | |
| pid /run/nginx.pid; | |
| # Load dynamic modules. See /usr/share/doc/nginx/README.dynamic. | |
| include /usr/share/nginx/modules/*.conf; | |
| events { | |
| worker_connections 1024; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ Fade detection """ | |
| class Fade(VisionTask): | |
| def run(self, system): | |
| log.info("Testing for image fade") | |
| log.info(system.image_gray.shape) | |
| mn = np.amin(system.image_gray) | |
| if mn > 30.0: | |
| system.full_caption += system.tools.cv_comms['fade'] | |
| return |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mean_s = np.mean(system.hsv[:,:,2]) | |
| std_s = np.std(system.hsv[:,:,2]) | |
| log.info("Mean and std value %f, %f" % (mean_s, std_s)) | |
| if std_s > 80.0: | |
| system.full_caption += system.tools.cv_comms['new-contrast'] |