Spektral Kalite Kontrolde Doğru Eşikleme Nasıl Kurulur?
Spektral kalite kontrol sistemlerinde başarı, kusuru görmekten çok kusuru üretim değişkenlerinden ayırabilmektir. Gıda, ambalaj, ilaç ve elektronik hatlarında yüzey rengi, parlaklık, baskı tonu, bant genişliği ve ortam ışığı sürekli değişir. Bu nedenle eşikleme, yalnızca yazılım içinde belirlenen sabit bir sayı değil; proses koşullarını, aydınlatmayı ve numune yapısını birlikte değerlendiren bir mühendislik kararı olmalıdır.
Doğru kurgulanmış bir sistemde amaç, “iyi” ve “kötü” ürünleri ezberlemek değil, normal varyasyonların sınırını tanımlayabilmektir. Böylece çizik, ezik, leke, eksik baskı ya da karışım hatası gibi küçük kusurlar, gerçek üretim koşullarında daha kararlı biçimde ayrıştırılabilir.
Spektral kalite kontrolde eşikleme neden kritiktir?
Görüntü işleme tabanlı denetimlerde eşikleme, piksel ya da spektral yanıtı kabul edilebilir bölge ile kusur bölgesi arasında ayıran temel karardır. Ancak üretimde “normal” her zaman tek bir değer değildir. Aynı ürün; farklı parti, farklı yüzey dokusu, farklı parlaklık seviyesi veya farklı çevresel ışık altında değişik görünebilir.
Bu yüzden eşik değerini yalnızca laboratuvar ortamında belirlemek, sahada yanlış ret oranlarını artırabilir. Çok dar bir eşik, iyi ürünleri kusurlu sayabilir; çok geniş bir eşik ise gerçek hataları kaçırabilir. Özellikle spektral kalite kontrol uygulamalarında doğru eşik, ürünün doğal değişkenliğini de kapsayan bir karar bölgesi tanımına dayanmalıdır.
Doğru eşikleme için veri seti nasıl hazırlanmalı?
En sağlıklı yaklaşım, numune setini sadece “iyi” ve “kötü” olarak ayırmak değil; kabul edilebilir proses varyasyonlarını da sisteme öğretmektir. Böylece algoritma, gerçek üretim koşullarında karşılaşacağı dağılımı daha iyi öğrenir.
Veri toplarken dikkat edilmesi gerekenler
- Aynı ürünün farklı yüzey parlaklıklarını ve renk tonlarını dahil edin.
- Üretim hattındaki farklı vardiya ve ışık koşullarını örnekleyin.
- Çizik, leke, ezik, eksik baskı gibi kusurları gerçek görünürlük seviyeleriyle toplayın.
- Ürün geçişleri varsa, her geçişte oluşan karakter değişimini ayrıca kaydedin.
- Numune sayısını artırırken sadece kusuru değil, kusursuz ama değişken ürünleri de dahil edin.
Bu yaklaşım, yazılım tarafında daha tutarlı bir karar sınırı oluşturur. Çünkü model, yalnızca hatayı değil, hatanın çevresindeki normal üretim davranışını da öğrenmiş olur.
Aydınlatma, kamera ve proses geometrisi birlikte düşünülmeli
Birçok projede sorun algoritmadan önce başlar. Yüzeydeki parlama, gölge oluşumu, kamera açısı, çalışma mesafesi ve ürün hizası; kusur algısını doğrudan etkiler. Özellikle değişken renkli veya yarı parlak yüzeylerde yanlış aydınlatma geometrisi, eşikleme performansını ciddi biçimde zayıflatır.
Bu nedenle kamera konumu ve ışık yerleşimi, yazılım ayarı kadar önemli bir tasarım parametresidir. Sistem kurulumunda şu sorulara yanıt verilmelidir:
- Kusur hangi açıdan en net görünür?
- Yansıma ve parlama nasıl bastırılacak?
- Ürün farklı renklerde geldiğinde kontrast korunacak mı?
- Hat hızındaki değişim görüntü kararlılığını etkiliyor mu?
İyi sonuç veren projelerde aydınlatma, kamera ve mekanik yerleşim birbirinden bağımsız değil; tek bir mühendislik bütünü olarak ele alınır.
Sahada iyi çalışan bir spektral kalite kontrol sistemi nasıl kurulur?
Sahada başarılı sistemler genellikle veri toplama aşamasında kazanılır. Sonradan yazılımı zorlamak yerine, proses karakterini baştan modele dahil etmek çok daha güvenilirdir. Uygulamada aşağıdaki sıra faydalı olur:
- Önce ürün ailesini ve kabul edilebilir varyasyonları tanımlayın.
- Ardından uygun aydınlatma geometrisini seçin.
- Kamera konumunu ve görüş alanını üretim toleranslarına göre sabitleyin.
- İyi ürünleri farklı varyasyonlarla birlikte kaydedin.
- Kusur örneklerini gerçek hatta oluştuğu haliyle toplayın.
- Eşikleme kararını, tek bir sayı yerine karar bölgesi olarak değerlendirin.
Pratik saha ipucu: Deneme sırasında sadece en temiz numunelerle başlamak cazip görünse de, bu yaklaşım çoğu zaman sahada yanıltıcı olur. En iyi sonuç, “temiz” ve “sınırda kabul edilebilir” ürünlerin birlikte test edildiği senaryolarda elde edilir. Böylece sistem, gerçek üretim toleranslarını daha doğru öğrenir.
Sonuç: Kusuru değil, varyasyonu yöneten sistemler kurun
Spektral kalite kontrolde doğru eşikleme, küçük kusurları kararlı biçimde ayırmanın temelidir. Ancak bu eşik, tek başına bir yazılım ayarı olarak değil; veri toplama, aydınlatma, kamera yerleşimi ve proses bilgisiyle birlikte tasarlanmalıdır. Değişken ışık ve renk koşullarında güvenilir sonuç almak isteyen üretim hatları için asıl hedef, kusuru zorla görünür kılmak değil, normal varyasyonu doğru modellemektir.
Mot Motion, üretim hatları için yapay zekâ destekli görüntü işleme ve spektral kalite kontrol çözümlerini proses ihtiyacına göre tasarlamaya odaklanır. Doğru eşikleme yaklaşımıyla daha stabil, daha ölçülebilir ve daha sürdürülebilir denetim altyapıları oluşturulabilir.
İletişim: info@motmotion.com | +90 544 977 58 99 | https://www.motmotion.com
English Version
In spectral quality control, success is often not about detecting a defect, but about separating it reliably from normal process variation. On food, packaging, pharmaceutical, and electronics lines, surface color, gloss, print tone, web width, and ambient light can change continuously. For that reason, thresholding should not be treated as a fixed software value, but as an engineering decision that considers process conditions, lighting, and sample structure together.
In a well-designed system, the goal is not to memorize “good” and “bad” products only. The real objective is to define the boundary of acceptable variation. This makes it possible to separate scratches, dents, stains, missing print, or mixing errors more consistently under real production conditions.
Why is thresholding critical in spectral quality control?
In machine vision inspection, thresholding is the core decision that separates acceptable pixel or spectral responses from defect regions. Yet in manufacturing, “normal” is rarely a single value. The same product may appear different due to batch variation, surface texture, gloss level, or environmental lighting.
That is why a threshold defined only in a lab environment may increase false rejects on the shop floor. A threshold that is too narrow may classify good products as defective, while one that is too wide may miss real defects. In spectral quality control applications, the right threshold should be based on a decision zone that includes the natural variability of the product.
How should the dataset be prepared for proper thresholding?
The most robust approach is not to label samples only as “good” and “bad”, but to also teach the system the acceptable process variations. In this way, the algorithm learns the distribution it will encounter in real production conditions.
What to consider during data collection
- Include different surface gloss and color tones of the same product.
- Sample different shift and lighting conditions from the line.
- Collect scratches, stains, dents, and missing print at their real visibility levels.
- If product changeovers exist, record the character changes that appear during each transition.
- As you expand the dataset, include not only defects but also flawless products with natural variation.
This approach creates a more consistent decision boundary on the software side, because the model learns not only the defect itself, but also the normal production behavior around it.
Lighting, camera, and process geometry must be designed together
In many projects, the problem starts before the algorithm does. Reflections, shadows, camera angle, working distance, and product alignment all directly affect defect detection. On colored or semi-gloss surfaces especially, poor lighting geometry can significantly reduce thresholding performance.
For that reason, camera placement and illumination design are just as important as software tuning. During system design, the following questions should be answered:
- From which angle is the defect most visible?
- How will reflection and glare be suppressed?
- Will contrast remain stable across different product colors?
- Does line speed variation affect image stability?
In successful projects, lighting, camera, and mechanical layout are not separate tasks; they are treated as one engineering system.
How do you build a spectral quality control system that works in the field?
Field-proven systems are usually won during the data collection stage. Instead of forcing the software later, it is far more reliable to model process character from the beginning. In practice, the following sequence is useful:
- First define the product family and acceptable variations.
- Then select the proper lighting geometry.
- Fix the camera position and field of view according to production tolerances.
- Record good products with different acceptable variations.
- Collect defect samples as they actually appear on the line.
- Evaluate the threshold as a decision zone rather than a single number.
Practical field tip: Starting testing with only the cleanest samples may seem convenient, but it often leads to misleading results on site. The best outcome is usually achieved when clean products and borderline acceptable products are tested together. This helps the system learn real production tolerances more accurately.
Conclusion: Build systems that manage variation, not just defects
In spectral quality control, proper thresholding is the foundation for consistently separating small defects. However, this threshold should not be viewed as a simple software setting; it must be designed together with data collection, lighting, camera placement, and process knowledge. For production lines that need reliable results under changing light and color conditions, the real goal is not to force defects into visibility, but to model normal variation correctly.
Mot Motion focuses on designing AI-powered machine vision and spectral quality control solutions tailored to process needs. With the right thresholding approach, production lines can achieve a more stable, measurable, and sustainable inspection infrastructure.
Contact: info@motmotion.com | +90 544 977 58 99 | https://www.motmotion.com