## 3 Materials and Methods  
The research was conducted storage period of 7 months from the loading date. Samples were taken every 4 days (8 samples per month). Five samples were taken each time from a randomly selected batch of wheat pile. Approximately 0.5 kg of grain was collected for testing. Samples were taken using a prototype multichannel probe with an overall length of 150 cm, which was equipped with a humidity and temperature sensor type AM2302. The probe allowed the acquisition of a representative cross-sectional sample at the depth of up to 120 cm and for the study of temperature and humidity of the intergranular space at a depth of about 100 cm. Then the sample was taken to the laboratory, where the contaminants were determined by means of the weight-sieve and microscopic methods. In parallel, the same sample was evaluated using computer image analysis. For this purpose, a special test stand, equipped with a camera for image acquisition (sampling) and connected with a computer application for grain evaluation was used. After the acquisition of the image, the analysis was carried out using the computer application \"Agropol V06\". Figure 1 shows the multichannel probe. Figure 2 shows the test stand. To carry out research based on computer image analysis, the \"Agropol V06\" application was developed, which is used to analyze, process, and recognize images. Its basic feature is the ability to build image processing scripts. For this purpose, a scripting language was built in which allows for a number of graphic operations. The program is adapted to read and write images in standard graphic formats (BMP, JPEG). The results obtained were compared with those from the laboratory. The task of \"Agropol V06\" computer application based on the RGB color description model and the application of the color recognition model was to extract the measured objects from the background and average the RGB components within the object outline:  
\[R,G,B=\frac{\sum R_{0-255}\cdot K}{\sum K} \tag{1}\]  
where: \(R\)--acquisition resolution (0-255) and \(K\)--number of pixels of a given resolution. With the average values of the \(R\), \(G\), \(B\) components, you can calculate the average brightness of the image according to the formula:  
\[I=(R+G+B)/3 \tag{2}\]  
Neural modelling was used for comparative assessment. The models were generated with the Automatic Designer using the following settings:  
Figure 1: The multichannel probe for sampling. [Source: [PERSON]]. Figure 2: The computer image analysis stand. [Source: [PERSON]]. input variable: binding quantity in percentage using the traditional (weight-sieve) method for 22 samples,  
- output variable: binding quantity in percentage by computer image analysis, for 22 trials,  
- designed models: three-line network, four-layer perceptron, four-layer perceptron,  
- activation function: linear. Out of 10 network models, 5 models meeting the best selection criteria were generated. One linear network model, 2 RBF network models, and 2 MLP (multilayer perceptron) network models were selected. In Table 1 features of selected models of neural networks are presented. In addition, as part of the research, the management of the entire technological process was implemented in parallel with the currently operating system. Thanks to such an approach it was possible to work out an optimal scheme for the implementation of the new solution. It was also possible to compare the time of conducted research, determine the costs incurred by both operating systems and calculate the operating profit related to the implementation of the new solution. As part of the research, only the cleaning process was analyzed for profitability. The whole technological process was divided into the following stages: weighing, sampling, evaluation of the composition and quality of contaminants, unloading, intra-elevator transport, cleaning (separation), drying, storage, and transport.