diff --git a/README.md b/README.md index 86605f2..d114e61 100644 --- a/README.md +++ b/README.md @@ -10,15 +10,15 @@ - **High-Performance Image Processing:** Native, vectorized NumPy operations for lightning-fast HSV conversion and color matching. - **Automatic Background Exclusion:** Intelligently ignores background pixels (configurable in `config.toml`) to ensure they don't interfere with your analysis. - **Grouping Score (Clustering):** A high-performance 9x9 box-sum algorithm that rewards solid "splashes" of color and penalizes thin lines or fragmented noise. -- **Batch Processing & Customizable Export:** Load a folder of images and instantly export `icra_stats.csv` and `icra_settings.json`. Features a dedicated **Weighting Dialog** to customize the impact of each core component. -- **Import/Export Settings:** Save your HSV ranges, exclusion zones, and weighting preferences to a JSON file and reload them later for consistent analysis across different sessions. +- **Batch Processing & Customizable Export:** Load a folder of images and instantly export `icra_stats.csv` and `icra_settings.json`. Features a dedicated **Weighting Dialog** to customize the impact of each core component, outputting precise percentage-based column headers. +- **Import/Export Settings:** Save your HSV ranges, exclusion zones, weighting preferences, and custom overlay colors to a JSON file and reload them later for consistent analysis across different sessions. - **Eyedropper Tool:** Quickly pick target matching colors directly from the image canvas. - **Advanced Selection:** Support for exclusion zones (rectangles and free-draw polygons) overlaid on the image, all dynamically rendered via `QGraphicsView`. - **Modern UI & UX:** - Drag-and-drop support for files and folders. - - Custom dark and light themes with native-feeling borderless titlebars and a categorized menu bar. + - Custom dark and light themes with native-feeling borderless titlebars. + - Context-aware hover tooltips across the cleanly categorized menu bar. - Window size and position persistence between launches. - - Keyboard shortcuts for rapid workflow. - **Configurable:** Uses `config.toml` to drive everything from overlay matching colors to default sliders and application language (`en`/`de`). ## Core Concepts @@ -43,6 +43,9 @@ To ensure accurate statistics, ICRA automatically filters out the image backgrou ### 4. Exclusion Zones Use the **Exclusion Tool** to draw rectangles or polygons over areas you want to ignore. This is essential for focusing your analysis on specific parts of a complex image while ignoring background noise or irrelevant details. +### 5. Configuration (`config.toml`) +The application is highly customizable via `config.toml`. A `config.toml.example` file is included in the repository—simply copy it to `config.toml` to gain fine control over default application sliders, language selection, UI masking colors, and initial background exclusion tolerances. + ## Typical Workflow 1. **Load Data:** Drag and drop a folder or use the `File` menu to load your images. diff --git a/config.toml.example b/config.toml.example new file mode 100644 index 0000000..5f386dd --- /dev/null +++ b/config.toml.example @@ -0,0 +1,34 @@ +# Optional global settings +# language must correspond to a file name in app/lang (e.g. "en", "de"). +language = "en" + +[options] +# Set to true to clear exclusion shapes whenever the image changes in the preview viewer. +reset_exclusions_on_image_change = false + +# Hex color code for the match overlay (e.g. "#ff0000" for Red, "#00ff00" for Green) +# This is the color that paints over pixels that successfully match your HSV ranges. +overlay_color = "#ff0000" + +# Hex color code for the background to be excluded (default #1f2937) +# This is useful for automatically removing flat background colors from UI screenshots +# or web scrapings before the analysis runs. +exclude_bg_color = "#1f2937" + +# Tolerance for background color matching (0-255, default 5) +# A higher value will exclude pixels that are "close" to the hex color above, allowing +# you to bypass slight compression artifacts or noise in the image background. +exclude_bg_tolerance = 5 + +[defaults] +# Override any of the following keys to tweak the initial slider values whenever +# the application starts. +# hue_min, hue_max, sat_min, val_min, val_max accept floating point numbers. +# alpha accepts an integer between 0 and 255. +hue_min = 250.0 +hue_max = 310.0 +sat_min = 15.0 +sat_max = 100.0 +val_min = 15.0 +val_max = 100.0 +alpha = 150