This article discusses fully automatic inspection of glass and plastic containers and factors that affect particle detection rate.
Hekla/shutterstock.com
The automated visual inspection (AVI) process in glass containers is a well-established process, but not yet perfect when it comes to free-floating or immobile particles. Inspection of plastic containers also has challenges. This article discusses fully automatic inspection of glass and plastic containers and factors that affect particle detection rate.
AVI as a technical inspection process relies on a contrast difference of a specific particle from its surrounding, under a particular lighting condition, and usually captured by a video camera. Whether it is machine vision or human inspection, if there is no contrast then there is no detection. The smaller a particle, the less contrast it shows, and therefore, the lower the chance of detection. Thus, the first goal in particle inspection is the correct adjustment of light intensity. Light intensity should be high enough to penetrate the container with the liquid, but low enough to provide the best contrast for the smallest particles.
It is necessary to consider the nature of particles and their interaction with light. One may think that a black particle is more detectable than a white one or a transparent one. This assumption is only partly correct and only under ambient lighting conditions. When it comes to machine vision, one is using transmitted light for the inspection scene, and here this impression is wrong. In machine vision, a thin grey metal particle can produce the same contrast as an almost clear plastic particle, and a thin black plastic particle will have a similar contrast to a glass particle of the same size. The differences become larger as the particles become larger, but the limitations of an inspection technique are determined by the boundary samples, which are usually made from the smallest possible detectable size. Considering these limitations, claims of reliable AVI detection of particles with a size of 50, 70, or even up to 100 µm are suspect. Human inspection capabilities have similar limits.
The inspection technique for AVI is simple and effective. The machines rapidly spin the container to create a vortex and then stop it suddenly, which conserves the liquid’s and particles’ motion according to their inertia. The rest of the scene must be stock-still, which can be done by cameras moving along with the machine transport or by a moving mirror system. From a series of pictures and their pixelwise subtraction, the moving reflections within the container area-on the picture-will be visible and create a detection signal. Human inspectors perform the same test by shaking, tilting, and flipping the container in their hands and watching for moving contrast.
In addition to packaging in glass vials and prefilled syringes, more injectable products are being packaged in plastic blow-fill-seal (BFS) vials and ampoules. These containers are usually manufactured in large blocks up to 30 or more directly bonded containers. Even when segregated into blocks of four or five containers, the classical method of AVI, which uses high-speed rotation and abrupt stoppage of single containers, is impossible to use. To test blocks of ampoules that cannot be rotated due to their symmetries, an inspection machine has to copy the human technique by vibration in combination with tilting and swivel motions. Then one observes the scene when the container is still, acquiring the picture series in between the agitations. The rest is identical to the AVI of single round glass vials.
All three scenarios-AVI for singles and blocks and the human inspection technique-have side effects created by moving bubbles, droplets, or light reflections that are mistakenly held for particles, and therefore, false rejects. Apart from reaching the best detection rates, reduction of false rejects is the second major task in setting up an AVI process.
A particle showing sufficient contrast and changing positon within a series of pictures in a perfect liquid is detected as a contamination. But, different particles act differently. Furthermore, clear glass and semitransparent plastic have different transmission and transparency properties. The particle nature, interactions with the liquid, the container material, and the way of agitation must be investigated.
Particles with lower and higher densities compared to the liquid must be treated differently. Material characteristics, such as adhesiveness or particle morphology, in combination with the primary container material, must also be taken into account. Additionally, the container geometry plays an important role in detection probability.
Fibers and flakes, regardless of the material, will or can float on water; therefore, they most likely are found on the surface. The usual camera position detecting these particle types is either tilted downwards from the top or inclined upwards from the side walls. The size of the area of such a surface defines the probability of detection of such particles. In fact, an upright standing container with a diameter of 12 mm is unfavorable for detecting floating particles, whereas a horizontal orientation of such a container magnifies this area to improve the detection rate (see Figure 1).
Figure 1: Horizontal orientation improves detection of floating particles by increasing the area of the liquid's surface. (All figures are courtesy of the author).
The size of an area where a particle can float is directly related to the detection probability, according to the equation:
Dpr = Dphys *Aobs/*Atot
Where Dpr is detection probability, Dphys is probability based on physical factors (size, contrast, visibility), Aobs is area obscured or not inspectable (meniscus fringes); and Atot is total inspection area.
The detection probability of floating particles in upright standing containers is limited or will be accompanied by a larger false reject rate than normal due to bubbles and swirls on the liquid surface.
Representatives of this category are fabric fibers, hair, splinters from metal, or chippings from most low density plastic materials.
Heavier and denser particles from metal abrasion, glass breakage, and all high-density materials tend to submerge or hover sometimes. They need to be detected in the body section of a container agitated by vortex or vibration. Vertical or horizontal positions usually provide the same results because these particle types are moving close to the wall and, therefore, showing good contrast. Detection rates up to 100% down to 150 µm and lower are frequently observed.
The probability of lifting large and heavy particles into the inspection area by a vortex is directly related to the size or weight, respectively. In the vertical detection position, they require a bottom inspection camera. In the horizontal position, they are detectable as easily as the smaller ones provided the agitation amplitude is large enough.
One disadvantage with bottom inspection of glass vials or plastic containers is the view of the camera into the moving water column above (see Figure 2). Refraction of light through the liquid acts like a moving lens systems and creates reflections and moving shadows that can easily lead to false rejects.
Figure 2: A glass container (top) has a positive liquid surface flank, which improves the probability of detecting floating particles. A plastic container (bottom) has a negative liquid surface flank, which creates a large probability of particles trapped at the side wall that cannot be detected.
In any case, the probability of detection of large glass shards on the bottom of a vial is lower than in the horizontal position, and the false reject rate is far higher than in other inspection positions. In horizontal inspection position and in human inspections, quite often a detection rate of 100% is reached.
Particle material can interact with the container material. Plastic particles in BFS processes, for example, are commonly created by the process. Burnt or melted plastic particles may be embedded in the side walls or, if free floating, adhering to the container wall due to Van-der Waals forces. These particles are, thus, quite often immobile and a specific inspection tool is needed. Glass containers have an advantage over plastic containers for AVI; in glass containers, the particles are usually free floating and not showing interaction with the glass walls.
For plastic containers, AVI machines also check for cosmetic defects all over the container surface apart from particle inspection. One can use these specific camera stations for static particle detection. The detection rate directly scales here with the contrast, and therefore with the size.
But there are additional interactions in plastic and in glass. The liquid produces bubbles and droplets when highly agitated, and due to the classification process in AVI, they are mistakenly held for particles when moving within the liquid or when dissolving into the liquid from picture to picture. Some liquids also tend to foam, which is even worse. A major task for every AVI process is to handle bubbles, or remove them or prevent them from being created during the filling and inspection process.
Container geometry can cause difficulties. A black spot on a round vial that is inspected only from two sides (front back side inspection) is missed by one-third of the inspections, which in turn means it requires three cameras to catch it. A block of square-shaped ampoules, which is common in BFS products (not rolling from a table when laid down), requires four cameras to inspect all sides of the wall properly.
Detection rates of static particle defects or cosmetic defects on the outer walls are fairly high and can reach almost 100% even for tiny defects, but they suffer from high false reject rates. These inspection stations require usually a big compromise of inspection sensitivity and false reject rates.
In a probabilistic measurement technique, which AVI represents, detection rates are not only ruled by the probability of grabbing a particle in two different positions in consecutive pictures, it is also a question about how likely a particle is in a position that can be evaluated by the visual inspection tools. Looking at a horizontal glass container, as shown in Figure 2, the water surface tension at the walls creates a shallow valley. That means the probability of a particle floating on an unobscured position that can be evaluated with visual inspection techniques is one.
The interaction between water and plastic, in contrast, creates a negative flank on the edges (see Figure 2), which means that there is a large probability of finding particles trapped on the side wall in an area that cannot be evaluated. Therefore, the detection probability is lower in plastic compared to glass. Overall detection probability is calculated as follows:
Dpro = Dphys*Dpos*Dpr
Where Dpro is overall detection probability, Dphys is probability based on physical factors, Dpos is position probability, and Dpr is detection probability.
In extreme underfilling scenarios of plastic containers, one finds a position probability of zero for any floating particle as shown in Figure 3.
Figure 3: In an underfilled plastic container, the position probability of detecting a floating particle is zero.
Although particle size is used as if it were a definite measure, it isn’t. A sphere can be said to be 150 µm in diameter, for example, but real particles are not spherical. How then should particle size be classified? Is a 100x300x80-µm particle in the class <100 or 100-200 or 200-300 or even 300-400 µm? Knowing that the contrast created by this particle is the main measure for detectability, it is fair to correlate this to the virtual area of this particle visible between the light source and the viewer (camera). In this case, one calculates the equivalent circle diameter, which is the closest to what causes the physical effect, as follows:
de = 1.30 (a b)0.625 / (a + b)0.25
where de is equivalent diameter (mm, inches), a is length of major or minor side (mm, inches), and b is length of minor or major side (mm, inches).
Using a particle with the two larger sides (100 x 300) in this context, results in 180-µm particle size.
A risk assessment should be performed on particles created from the process (either extrinsic or intrinsic); particles arising from external process steps, such as raw materials or pretreatment of containers; and particles arising from human or machine handling. A history of particle and defect findings can become a proper tool when rating the risks associated with particle occurrences.
The overall particle load of a process in conjunction with specific detection rates is often a neglected aspect of risk assessment. The total number of a specific particle in the process is correlated with the detection rate, resulting in the residual risk of delivering contaminated products to the patient. As an example, the process risk of glass breakage in filling of glass vials is rather high due the various handling steps like washing, drying, and sterilization or depyrogenation and the associated possibilities of causing a glass breakage. The particle load in BFS with plastic particles from the process, however, is close to zero with respect to particle findings in the final product. An AVI process may have a detection rate of 90% for glass particles, but the number of contaminated glass vials shipped still is significant. An AVI process may have a detection rate of 65% for plastic particles, but the amount of contaminated plastic containers reaching the patient is still close to zero.
Everyone who inspects product has a certain idea about defects and the related risk. In pharmaceutical products, the finding of a particle causes a higher patient risk than a scratch in a container, and therefore, the rating for particle finding is always critical; the scratch usually gets a minor classification. A vision system can only classify on a logical tool ranking, which could lead to a scenario where the tool used for scratch detection also triggers an alarm when a static particle and no scratch was present. The root cause of the alarm is a particle, but the ranking of the tool is more toward cosmetic defects, and users definitely don’t want a particle classification for each minor scratch. Because the probability of scratches is far higher than that of particles, one can argue for leaving the classification as a “minor defect”. In implementing an AVI, it is therefore necessary to carefully investigate the possible misclassifications and give a rationale for each class to illustrate the reason for choosing this specific level.
Finally, do not overload an AVI system with requests for finding all the tiniest and minimalistic defects, which compromises the effectiveness of the more important tools. This method always leads to an instable detection process, and believe it or not, the more cameras that are added, the more false rejects occur. Every camera that detects defects always adds false rejects, which reduces the overall throughput.
Although these dependencies and cross correlations seem to add a sort of confusion to the task of defining or building the right AVI system, understanding them is the only way to install the right AVI system for a specific production process. A risk-based approach of investigating the particle behaviors in the specific container designs and materials is suggested to obtain the corresponding detection probabilities and associated false reject rates. With the defect library of a pharmaceutical company, one can conduct a risk analysis to identify the ‘real’ risks and remove the sole ‘potential’ risks from the listing. Then one can correlate this with the process risks of certain defects. In the end, the right combination of inspection stations and tools maximizes the detection of higher risk defects and minimizes the false rejects of good product.
Pharmaceutical Technology
Vol. 41, No. 10
Pages: 68–74
When referring to this article, please cite it as H. Prinz, "Automated Visual Particle Inspection," Pharmaceutical Technology 41 (10) 2017.