The Development of Cotton-yarn-quality Predicting System
Ying Xiao1 Shulin Zhao2
Tianjin Polytechnic University, School of Textiles Tianjin Polytechnic University, School of Textiles Tianjin, China Tianjin, China yingxiao_sun@tom.com
Abstract: A new cotton-yarn-quality predicting system was
developed by using the merging programming technique of VB and Matlab in the paper. Using this system, the tenacity and evenness CV% of the cotton-yarn processing by conventional spinning at standard temperature and humidity can be predicted through inputting some fiber properties into the system, such as the percentage of impurities, the principal length, the percentage of short fiber, the degree of maturity, fiber strength and the value of Micronaire. And also it was verified that the system did the good job for predicting yarn tenacity and evenness CV% exactly with the relative error of less than 4% after the model being trained. The accuracy can meet the demand of spinning factories and so the predicting results would be useful for guiding the spinning practice. Figure1.The Overall System structure Key words: BP network; network model; yarn quality prediction; merging programming of VB and Matlab The system mainly consisted of the neural network I. INTRODUCTION building module, network training module, yarn-quality predicating module, the model database and other The quality of yarns is mainly determined by fiber modules. Each module could operate coordinately under properties, spinning processing, spinning equipments and the domination and regulation of main control program of the temperature and humidity of workshops, and so on. In VB and realize many functions, such as data document these factors, fiber properties are the most important one read and writing, network modeling, network model for the yarn quality. In order to predict the yarn quality training, retention, call, and yarn quality prediction. through digital simulation, it is essential to analyze the relationship between fiber properties and yarn quality III. BP NEURAL NETWORK MODEL DEVELOPMENT under any other conditions unchanged, such as processing temperature and humidity. In this paper, a BP neural 1. The Introduction of BP Neural Network network model was set up and based on the model, a new The BP Neural Network ( short for BP network), also yarn-quality predicting system was developed by which known as back propagation network, is a multiple layer the tenacity and evenness CV %of cotton yarns by ring feed-forward network, which generally includes an input spinning process at the standard temperature and humidity layer, an output layer and one or several hidden layers, could be predicted through inputting six fiber properties with its operation mainly consisting of two processes: the into the system. Furthermore, it was validated that the feed-forward transmission of the information and the system model did a good job for predicting both the yarn reverse transmission of the error[1]. In the former process, tenacity and the evenness CV% exactly with the relative the information was calculated from the input layer to error of less than 4%. output layer, layer by layer via hidden layer ,with the neural unit state of each layer only affecting the next II. THE DESIGN OF THE OVERALL STRUCTURE one's ;and in output layer, the system would turn to back A system was developed by using the merging propagation if the desired results were not achieved when programming technology of VB and Matlab and the compared with the target value. Then the error was system integrated the user-friendly interface of VB and transferred from the output layer to input layer with the the powerful function for data processing of Matlab. The network algorithmically adjudging its own weights and overall system structure was shown in Figure 1. thresholds and the adjusting process was repeated till it reached the desired results. 2. Neural Network Model Development Aiming at the above issue, the strength and evenness CV % of the yarns was predicted when the 3 layers and 4 layers BP networks were developed with neural network
toolbox in Matlab environment and trained [2-3]; viewed reduce the time for network training. Meanwhile, the from the training effect, not only the training time of network model structure was not too complicated and the 3-layer-network was shorter than the 4-layer-network, the problems were relatively simple in the quality predicting prediction precision was also higher. Therefore, 3-layer system, the actual total memory consumption was not too network model network structure was chosen in this much when the network was trained by this method. yarn-quality predicting system, which consisted of an The network model has been built completely after the input layer, a hidden layer and an output layer. above design, according to which the topology map could be drawn in Figure 2. The BP network could be divided A. Neurons Number in Input Layer into three layers: the input layer, the hidden layer, and the This system was mainly used to predict the yarn output layer. There were 6 nodes in the input layer, an tenacity and its evenness CV% under any other conditions adjustable number in the intermediate hidden layer, and 2 unchanged, such as processing, temperature and humidity. in the output layer. To reach the above objective, the yarns quality was predicted through inputting six indicators of fiber quality such as impurity rate, the principal length, the percentage of short fiber, the degree of maturity, fiber strength and Micronaire [4].Firstly, the 11 fiber quality indicators the spinning plants often measured were statistically analyzed and then the experts' opinions were gotten in this field, finally six neurons were taken in this layer to meet the requirement that the network neurons number should correspond to the fiber index number. B. Neurons Number in Hidden Layer There was no effective principle to follow to determine the neurons numbers in this layer, so the Figure2. The BP Net Structure optional one was mainly determined by training and contrast on different neurons numbers. It was revealed that IV. SYSTEM DEVELOPMENTS the network predicting accuracy was highest when the neurons number in this layer was 16 through training and 1. The Neural Network Construction Module contrast in the course of modeling the network. However, Developments this was only for the training data used by the author, if According to the requirements of network mode the training sample changed, the optional number of mentioned above, this part was developed by Matlab neurons would have a corresponding change, therefore the neural network toolbox, in which the Newcf. Function was neurons number in hidden layer could be set to a variables called to design the BP network; finally the designed with a recommended value 16 in the quality predicting network was packaged into the same function file named system, and the best suited hidden nodes number for net.m together with the data pre-designed program and the samples could be determined by the system operator network training program. During the construction and through training and contrast. training process, the network was activated by transferring the external data information and the design of the C. Neurons Number in Output Layer network nodes of hidden layer into the internal of function The yarn tenacity and evenness CV % were chosen for file through a call to this function file, after that the the predicting output items in this system. As a result, the network training was completed. corresponding output layer neurons number in the network 2. The Modules Developments on Network was taken as 2. Training and Yarn Quality Prediction D. Activation Function of Each Layer These two parts were developed with the technique of The common hyperbolic tangent function VB and Matlab merging programming, the running of −2 n −2 n f (n) = (1 − e ) (1 + e ) in BP network was adopted Matlab application program was controlled by the master control program of VB and the data transfer was carried as activation function in the hidden layer. This function out between the environments of VB and Matlab. could compress each input to a value between -1 and 1; while the linear function f (n) = w×n +bcould be adopted A. The Realization Base of VB and Matlab Merging Programming as the activation function in the output layer [5]. ActiveX Automation protocol is a protocol that allows E. Network Training Algorithm one application program (the control side) to control Levenberg-Marquardt algorithm was adopted to train another (the server side). As VB could supports the the network model in the system to overcome the ActiveX automation control side protocol and Matlab was disadvantages of criteria BP algorithm, such as long able to support automated server-side protocol, therefore training time and vulnerability to local optimum. It has when the ActiveX connection established between them. been proved that the improved algorithm could markedly The Matlab command could be called directly in VB environment, and then the realization of data transfer object named MT being created in the VB environment, between the two programs followed. the trained network model the user specified was loaded to Matlab environment through a call for Matlab to B. The Network Training Module Developments implement the "LOAD" command by MT.Execute The function this module require to be achieved was method;Then fiber index value was transferred into completing the network training and the retention of the Matlab environment from the VB environment by trained model on the basis of transferring the input MT.Putfullmatrix method and passed to the loaded messages from the network training interface in VB network mode after being pre-processed, then the yarn environment to the network models in Matlab quality was predicted through a call for the neural network environment as well as making them activated. The emulation function "SIM". Finally the predicting results realization processes were as follows: First, a Matlab. obtained were processed, transmitted in the VB application object named MT was created in the VB environment by MT.Getfullmatrix method and displayed environment so that the ActiveX connection could be on the quality-predicting interface [7]. achieved between VB and Matlab ; then the activation and training of the network could be realized on the basement V. MODEL LIBRARY CONSTRUCTING of transferring the input messages from the network Cotton yarns with different count were collected from training interface in VB environment to Matlab several cotton mills within a year, along with the environment by MT.Putfullmatrix method, the call for corresponding raw cotton information indicators. After Matlab by MT.Execute method to implement the net.m being analyzed and processed, the data could be used to function files and the transfer of data information and the train the network models constructed by this system, and setting to the network hidden layer nodes to the network then all the trained models were saved in model database through function parameters latter ; After training, the for the yarn quality prediction. trained network model was saved into model base, which was available to be called by yarn quality prediction VI. THE INSTANCE AND ANALYSIS module through a call for Matlab program to implement The model"JC18.2T" was called from the model the "SAVE" order by MT.Execute method [6]. library to predict the quality of the JC18.2T yarn produced C. The Yarn Quality Predicting Module by a factory. The properties of the raw cotton the yarn used were summarized in Table 1, while both the The function this module to be realized was predictive values and the measured values were shown in transferring the fiber quality index value from the Table 2; As it could be seen in Table 2, the yarn tenacity quality-predicting interface in VB environment to the trained network model that loaded in Matlab environment and its evenness CV%were predicted with the relative to realize the prediction and not only returning the error of less than 4% by the trained model. Since the prediction results to VB environment but also displaying predicting accuracy was in an acceptable range, the them on quality prediction interface, the above functions predicting results would be useful for guiding yarn was realized as follows: after the Matlab application -spinning practice.
TABLE I. THE PROPERTIES OF COTTON FIBER
Group Impurity Principle Length Short Fiber Content Strength
TABLE II. THE TABLE OF COMPARISON BETWEEN PREDICTING VALUE AND MEASURING VALUE
Predictive Value Measured Value Relative Error
Group Number Strength CV % Strength CV % Strength CV % (cN·tex-1) (%) (cN·tex-1) (%) (%) (%)
1 15.7 12.6 15.5 12.5 +1.29 +0.80
2 15.3 12.6 14.9 13.0 +2.61 -3.08 3 14.3 12.8 14.8 12.9 -3.38 +0.78 4 14.5 12.7 14.8 13.0 -2.03 -2.31 5 14.6 12.9 14.1 12.8 +3.55 -0.78 VII. CALCULATIONS In order to predict the yarn quality through digital simulation, it is essential to predict the yarn quality with higher accuracy in the spinning process. In this paper, a further exploration was made to this part and artificial neural network model was built to predict yarn strength and evenness. And also it was verified that the system did the good job for predicting yarn tenacity and evenness CV% exactly with the relative error of less than 4% after the model being trained. The accuracy can meet the demand of spinning factories and so the predicting results would be useful for guiding the spinning practice. REFERENCES [1] Xiangsheng Huang,Hanbin Xiao.Application of Wavelet Analysis and ANN in Ultrasonic Quantitative Testing[J],Port Engineering Technology,2008(6):13-15. [2] Bao Liu, Gang Wu. Surface Prediction Model Based on BP Neural Network [J].Heat Treatment Technology and Equipment, 2006(6):37-40. [3] Xiancai Gui. Realization of BP Networks and Their Application on MATLAB [J].Journal of Zhanjiang Normal College, 2004, 25 (3):79-84. [4] Xiaomei Zou, Guan Liang. The Relationships of Performance of Rraw Cotton,Spinning Process and Yarn Quality[J]. Inspection and Quarantine Science, 2005, (12):143-144. [5] Cong Shuang.Matlab Neural Network Toolbox and its Application [M]. University of Science and Technology of China Press.2003-5 (2). [6] Zhisong Zhu, Xiaoli Guo. Research on Merging Programming of VB and MATLAB [J]. Computer Applications, 2003(9):18-19. [7] Li Feng, Ju Li. Method of Hybird Programming with VB and Matlab[J], Software Technology, 2005 (5):110-112.