0
0
Computer Visionml~8 mins

Why processing prepares images for analysis in Computer Vision - Why Metrics Matter

Choose your learning style9 modes available
Metrics & Evaluation - Why processing prepares images for analysis
Which metric matters for this concept and WHY

When preparing images for analysis, the key metric to watch is model accuracy. This shows how well the model understands the processed images. Proper image processing helps improve accuracy by making images clearer and more consistent for the model.

Confusion matrix or equivalent visualization (ASCII)
      +---------------------+
      |       Confusion      |
      |       Matrix        |
      +---------+-----------+
      |         | Predicted |
      | Actual  |  Cat | Dog |
      +---------+------+-----+
      | Cat     |  45  |  5  |
      | Dog     |  3   | 47  |
      +---------+------+-----+
    

This matrix shows how well the model classifies images after processing. Better processing usually means fewer mistakes (off-diagonal numbers).

Precision vs Recall tradeoff with concrete examples

Precision means when the model says an image is a cat, how often it is really a cat. Recall means how many of all cat images the model correctly finds.

Good image processing helps both precision and recall by reducing noise and highlighting important features.

Example: If images are blurry, recall might drop because the model misses cats. If images have distracting backgrounds, precision might drop because the model confuses dogs for cats.

What "good" vs "bad" metric values look like for this use case

Good: Accuracy above 90%, precision and recall both above 85%. This means the model correctly identifies most images and makes few mistakes.

Bad: Accuracy below 70%, or precision and recall below 60%. This suggests poor image processing or noisy data causing confusion.

Metrics pitfalls
  • Accuracy paradox: High accuracy can be misleading if classes are unbalanced (e.g., mostly dog images).
  • Data leakage: Using test images in training can falsely boost metrics.
  • Overfitting indicators: Very high training accuracy but low test accuracy means the model memorizes images instead of learning features.
  • Poor preprocessing: Not resizing or normalizing images can confuse the model and lower metrics.
Self-check question

Your image classification model has 98% accuracy but only 12% recall on the cat class. Is it good for production? Why or why not?

Answer: No, it is not good. The model misses most cat images (low recall), even if overall accuracy is high. This means it fails to find many cats, which is a serious problem if cats are important to detect.

Key Result
Proper image processing improves model accuracy by making images clearer and more consistent, leading to better precision and recall.