# KSG AOI image anomaly detection [![pdm-managed](https://img.shields.io/endpoint?url=https%3A%2F%2Fcdn.jsdelivr.net%2Fgh%2Fpdm-project%2F.github%2Fbadge.json)](https://pdm-project.org) [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff) ## General ### Lib structure by Susanne - configs: - ``config.py``: reduced version of original config to work as a small test example - ``config_for_test.py``: special parameters for test environment, minimal working example - main program: - ``main.py``: loads GUI and background worker to observe changes in folder directory - GUI: - ``window_manager.py`` - ``gui_ai_on_off.py`` - Logic: - ``monitor.py``: worker logic to observe changes in the relevant folders - function ``monitor_folder`` - ``preparation.py``: main logic to process data ``class Preparation``, namely: - copy (backup) of found data to this app's saving directory (``config.py -- STORING_PATH``) - method ``copy_ngt_and_checkimg`` - colourisation of images (only the first) (yellow) - method ``change_image_to_yellow`` - fuse the different RGB layers to one image and save it - method ``create_rgb_images_and_patches``