Automated Approach for Product Sizes Measurement on the Conveyor Belt

The present paper explores the concept of digital data processing algorithms' mix and outlines an approach to disclosing the relation as defined in the mix mentioned. Alongside with that we offer certain criteria for the determination of equivalence classes for the present mix in the context of automated item measurement on the conveyor belt problem.


Introduction
A large number of problems which arise in complex technical vision studies, as well as in optical checking scenarios etc., employ various digital image processing algorithms.The option of solving particular problems using a variety of methods can be viewed as an additional complication.Thus, the solution of the major problem is complicated by the lack of a formalized approach to the choice particular tasks' solution methods.For example, the researcher has to take great pains with a task of image processing, particularly filtering and segmentation, when it comes to creating a pattern recognition system (PRS).Ironically, fairly well developed and comprehensive toolkits, actually complicate this task.This in turn, results in either choosing the more or less 'fancy' algorithm as your number one option, or, developing a fairly complex algorithm for a task where a much simple method could suffice.
In the end, it brings us to the problem of creating an automated (and in some scenarios even automatic) image processing algorithms' development, fit for the purpose of static and motion image processing in a predefined scenario.In this paper we shall limit ourselves to the study of the problem of automated item measurement on the conveyor belt.
Suppose there is a certain structure which contains algorithms which cover 'most' methods of preliminary image processing, i.e. filtering, segmentation and morphological processing.For the sake of argument, we shall call this structure ImPr (acronym for Image Processing).
From hence arises a reasonable question: does this structure qualify as a set?
The answer to this question is not obvious, for reasons that historically have originated from the "naive" set theory, which allowed to define a group of any item(s) as a set only on the basis of some property, which these items possess.This approach had eventually led to a crisis in the foundations of mathematics.
So, what are the chances the use of the term 'set' will not result in Russell's Paradox [1] or, for that matter, any other paradox?Naturally, paradoxes are quite likely to occur if we stick to the 'naive' interpretation of the set concept.We shall use the following axiom: ∃Y∀x(x∈Y⟺Φ(x)).I.e. for the condition Ф(x) exists a set Y, comprised of the same x, which obey Ф(x).
Then by the axiom of separation there exists the Y set: ∀x(x∈Y⟺x∉{x}).
And if it is possible for any x then, particularly, it is also true for x=y, i.e., the following is possible y∈y⟺y∉y.This results in a contradiction, which shows that applying 'naive' theory of sets to all existing items is not feasible.
Moreover, there are other paradoxes which do not allow to call a collection of items that satisfy a certain condition a set.
From the mid-20th century onwards the set is defined as a model satisfying the axioms of Zermelo-Fraenkel set theory (ZFC) We will now show that the structure consisting digital image processing algorithms is the set and give a formal description of this set, as well as some examples of relations as defined therein.

Check of system of axioms of Zermelo-Fraenkel
Let us make sure that the mentioned structure is a set and that it satisfies the rules of Zermelo-Fraenkel axiomatic system [1][2][3], and is a complete set.In all our subsequent arguments we shall assume that a, b, c are sets, the elements of which can also be sets.
1. Dimensions axiom.The set is defined by the elements: the sets consisting of the same elements are equal.
x y ( z (z x z y) x = y) Let's define a set of algorithms of ImPr as the set containing image enhancement algorithms (the averaging filter, the median filter, Gauss's filter, etc.), algo-rithms of selection of circuits, algorithms of morphological processing of images [4][5][6][7][8]9].

Axiom of an empty set.
There is an empty set e without unit element: ( ) e a a e (2) 3. Couple axiom.It is possible to construct couple of two sets ( { , }) x y z z x y (3) ) This axiom is equivalent to an axiom of selection of the "naive" theory of sets: from each set it is possible to select at least one subset y, having stated judgment Φ about each element of this set of x.Formally our structure, allows to select algorithms of frequency filtering of the image, for example.
5. Substitution axiom.Ф(x,y) -the property that for every x, there exists no more than one y, that satisfies Ф(x,y).Then for every set X could be found set Y {y: x X :Ф(x, y)} (5) 6. Foundation axiom: )) ( ( x y x y y x x (6) In each non-empty set there will be an element which is not crossed with an initial set.In other words, in a set there has to be the "minimum" element which intersection with a set is empty.There is no infinite sequence of the enclosed sets: each chain of sets Really, all specified structure members owing to the nature assume classification that means existence of the hierarchy allowing to select the final chain of subsets which is not including all set.
7. Axiom of infinity.There are infinite sets, such sets A, that cardinality of the A is equal to the cardinality }. {A A Or using language of quantifiers: ). }) { ( ( Our structure, owing to its nature, is potentially infinite that does not contradict this axiom.

})) { ( (
For any set of in pairs not crossed non-blank sets there is, at least, one set which contains precisely one element, the general with each of non-empty sets.

Characteristics of Sets
Since the given set ImPr is a naturally built set, the following characteristic of the set becomes evident: ImPr -is a non-empty infinite enumerable set of elements required for the solution of a given image processing task.
In accordance with the nature of the set's elements, it is deemed reasonable to discriminate the following subsets: x AF -image filtering algorithms' subset; x AS -image segmentation algorithms' subset; x AMP -morphological image processing algorithms; x AR -description and representation algorithms; x APR -recognition algorithms.
We can safely call any of the subsets an infinite one, as a clearly formulated proof of image processing algorithms' finiteness is non-existent.
The binary operation of algorithms' composition if defined in the original set ImPr×ImPr→ImPr.The result of the composition of the two image processing algorithms is the image processing algorithm.In the generic case this operation is neither that of association or of commutation.
The complete cycle of image x digital processing can be formally described as follows: Then the complete cycle can be represented as: ) 4 Relationships, defined in the ImPr set In order to form a chain of algorithms, let us define some relations for the ImPr set.
1) Algorithms f and g are qualitatively equivalent if for the same set of input parameters there exist the same output parameters.Analogous to that we can introduce the concept of performance equivalence (a key featurethe number of processor cycles), by complexity.
2) Algorithms f and g are strictly equivalent if they are qualitatively equivalent, as well as equivalent in complexity and speed.
There is a clear relation between quality and strict equivalence.This clarity is manifested in complete consistency in the algorithms' output: ( ) ( ) Result f Result g .In particular, for the algorithms, the execution of which results in images, quality and strict equivalence means full output image congruence, and, consequently, correlation coefficient equaling one: 1 r g f , , where -brightness values in the pixels with coordinates y x, of output images generated by algorithms g f, , respectively; g , f -mean pixel brightness value for images, generated algorithms g f, , respectively; N M, -number of pixels in the images vertically and horizontally, respectively.
Often it is quite sensible to exploit fuzzy similarity relations of alternative algorithms when conducting a search for an adequate image processing algorithm.Let us define one of the fuzzy similarity types 'a visual similarity' and define it as follows: algorithms f and g are visually similar, if the correlation coefficient between the output images of these algorithms is larger than O : {1,2,..., } \ { , } V m i j -a set of integers from 1 to m , excluding numbers i and j .
The present relations allow to create mixes (compositions) of algorithms which can be used to solve a variety of practical tasks: from improving image quality to pattern recognition and the task similar to it, i.e. parts geometry measurement.

The example of the subsets' structure of for the formation of the digital image processing algorithms' mixes
We restrict ourselves to the minimum composition of the sets of algorithms that allows to demonstrate the ideas outlined above Consider the problem of preprocessing the image details for the subsequent measurement of product dimensions.Preprocessing process consists in performing sequential filtering and edge detecting.
The compassion of each subset is given in Table 1.To solve a particular problem we have to determine the composition of the subsets of ImPr set and then having selected a particular criterion or criteria, choose the set of mixes for subsequent testing.
In this case by defining image preprocessing algorithm, we will create all possible mixes (with the total number being 8) and evaluate the quality of the outcome for a particular image by enumerating the possibilities.
To assess the quality necessary: 1. Determine the equivalence classes of asymptotic complexity among algorithms.2. Identify visually similar algorithms.The results of evaluation time of the mixtures are shown in Fig. 2. In addition to the choice of pre-image processing method, this chart allows, for example, to draw a conclusion about equivalence by complexity of algorithms of the Sobel operator and the Prewitt operator [5].The diagram illustrates that multiple launches show the same time processing the image data operators.In addition, the relative complexity by equivalence of these operators also is result of similarity of masks of these operators [5,8,9], which are differs only by constants.Thus, we obtain similar results using filters having different computational complexity.As a result, there is ability of optimization, that consists in the selection of algorithms and their parameters, the most appropriate specific conditions.And only if was proved that chosed mix of algorithms is optimum in some meaning (for example in terms of performance) we have reason to believe that the task of the image preprocessing solved.

Conclusions
The key findings of this paper are the following: 1.It has been established that there exists a formal set of digital image processing algorithms; 2. The relations in the set of digital image processing algorithms have been defined; 3.An approach to algorithm's mixes for digital data processing in the scenario of automated item geometry measurement on the conveyor belt has been proposed.4. A mechanism of visual similarity classes search in real-life applications has been shown.As the result of the practical uses of this mechanism it was shown: -In the context of a given task even the algorithms which are considered to be among the best (Gauss filter and Canny operator [6,9]) do not guarantee a consistently good outcome.
-Experimental data shows that the following three mixes can be deemed the most effective: averaging filter and Sobel operator, averaging filter and Prewitt operator and averaging filter and Roberts operator.
-By expert opinion the most roubust algorithm mix for the given scenario was the one on averaging filter and Sobel operator.However, in terms of speed this mix loses out to that of averaging filter with Roberts operator [9].
, f g r !O .O value may vary depending on the applica- tion.It is possible to set a 'default value': 0,95 O .Note that the ratio of visual similarity is reflexive, At the same time the relation of visual similarity is not transitive, as the validity of in the generic case.Let us define an additional relation of visual similarity to overcome the intransitivity mentioned.We shall call this relation a transitive one: algorithms i f and j f are connected by the relation of transitive visual similarity, if the following relation is true: number of alternative algorithms for the solution of a certain task; D Disp V l -a set of placements l of integers from the set V ;

3 .
Fig. .Filter combinations: A) Gauss and Sobel operator, B) Gauss and Canny, C) Gauss and Prewitt, D) averaging and Prewitt.E) averaging and Roberts F) averaging and Sobel G) Gauss and Roberts H) averaging and Canny

Fig. . 1 . 1 2
Fig. .The result of the correlation analysis of the Gauss's filter and the averaging filter for the different radius of filtering.The following chart shows that the relations given can be applied for the Gauss and averaging filters.By

Fig. 3 .
Fig. 3.The results of correlation analysis of Gaussian filter and averaging filter for the filtration of various radius