###### Abstract  
The correct management of operations in thermoelectric plants is based on the continuous evaluation of the structural integrity of its components, among which there are elements made of stainless steel that perform water conduction functions at elevated temperatures. The working conditions generate progressive wear that must be monitored from the perspective of the microstructure of the material. When AISI 304 stainless steel is subjected to a temperature range between 450 and 850 \({}^{\circ}\)C, it is susceptible to intergranular corrosion. This phenomenon, known as sensitization, causes the material to lose strength and generates different patterns in its microstructure. This research analyzes three different patterns present in the microstructure of stainless steel, which manifest themselves through the following characteristics: the absence of intergranular corrosion, the presence of intergranular corrosion, and the precipitation of chromium carbides. This article shows the development of a methodology capable of recognizing the corrosion patterns generated in stainless steel with an accuracy of 98%, through the integration of a multilayer perceptron neural network and the following digital image processing methods: phase congruence and a gray-level co-occurrence matrix. In this way, an automatic procedure for the analysis of the intergranular corrosion present in AISI 304 stainless steel using artificial intelligence is proposed. stainless steel; image processing; artificial neural network; pattern recognition +
Footnote †: journal: Medical Engineering, Universidad Politecnica de Zacateas, Plan de Pardillo Son, Parque Industrial, Fresillo 9059, Zacateas, Mexico; [EMAIL_ADDRESS] (Correspondence: [EMAIL_ADDRESS] (A.J.-G.); [PERSON]. AISI 304 steel is used to manufacture boiler conductors in thermoelectric plants, which translates into elevated temperature working conditions and attack from external oxidizing agents such as humidity. The permanence of the steel in the temperature zone between 450 and 850 \({}^{\circ}\)C causes the precipitation of carbon through the generation of chromium-abundant carbides of the M23C6 type [4]. The main change that occurs after stainless steel's exposure is the appearance of susceptibility to intergranular corrosion, linked to the modification of the structure and the alteration of the mechanical properties of the material and, consequently, the generation of unexpected failures in the conductors and equipment in service [5]. In AISI 304 stainless steel, there are different states that are related to the duration and temperature of heat to which the material has been subjected; at temperatures close to 500 \({}^{\circ}\)C, carbides are manifested at the grain boundary as a thin and continuous sheet, i.e., at that time, there is no intergranular corrosion; see Figure 1a. When the steel is in operating conditions with temperatures close to 700 \({}^{\circ}\)C, the carbides take dendritic forms that develop at the intersection of the grain boundaries, where they start their agglomeration; under this morphology, intergranular corrosion starts; see Figure 1b. With increases in the working time and temperatures near 850 \({}^{\circ}\)C, the fine dendritic form of chromium carbide gradually transforms into a sizable nucleation that precipitates toward the grain boundary, giving way to a compromised condition for the material to continue operation [6]; see Figure 1c. This paper presents the development of a methodology that allows for the recognition of intergranular corrosion patterns generated in stainless steel from the integration of a multilayer perceptron artificial neural network (ANN) and the following digital image processing methods: phase congruency and gray-level co-occurrence matrix (GLCM), which will give way to an automatic diagnosis of the condition of stainless steel based on artificial intelligence.