A packaging machine fault diagnosis method and system
By constructing a heterogeneous graph of equipment and performing causal analysis and cross-node temporal attention fusion, the problem of insufficient multimodal data fusion in packaging machine fault diagnosis is solved, and a comprehensive characterization of the overall health status of the packaging machine and highly accurate identification of fault types are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHANDONG TAISHAN LIFU FOOD TECH CO LTD
- Filing Date
- 2025-12-11
- Publication Date
- 2026-07-24
Smart Images

Figure CN121705919B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology. More specifically, this invention relates to a method and system for diagnosing packaging machine faults. Background Technology
[0002] As a key piece of equipment in modern industrial production lines, the operating status of packaging machines directly affects the efficiency and product quality of the entire production process. With the continuous improvement of automation levels, packaging machines are becoming increasingly complex in structure and faster in operation, with close mechanical, electrical, pneumatic, and hydraulic coupling relationships between their components. Under this high-intensity, continuous working mode, various factors such as mechanical wear, electrical aging, and abnormal control logic can cause malfunctions, leading to production interruptions, material waste, and even safety accidents, resulting in significant economic losses. Traditional fault diagnosis methods mainly rely on manual inspection and post-incident maintenance. This approach heavily depends on the experience and knowledge level of maintenance personnel, resulting in slow response times, low efficiency, and difficulty in accurately identifying and locating complex, multi-component, intermittent, or early-stage faults, failing to meet the demands of modern, intelligent production.
[0003] To improve the automation and intelligence of fault diagnosis, researchers have begun to introduce data-driven diagnostic methods. For example, machine learning models such as support vector machines and neural networks are used to analyze single or multiple sensor signals such as vibration, temperature, and current of packaging machines to identify abnormal patterns. However, existing methods still have many limitations. On the one hand, most methods treat the data from each measuring point as independent time series, ignoring the clear physical connections and control logic dependencies between the components of the packaging machine as a complete physical system. This approach fragments the topological information within the equipment, making it difficult to capture the propagation path and evolution of faults between different components. On the other hand, existing data fusion technologies mostly focus on simple feature splicing, failing to effectively integrate the heterogeneous information contained in multimodal data (such as vibration, temperature, and visual images), and failing to deeply explore the causal relationships between various monitored variables. This makes the model susceptible to spurious correlation interference and insufficient ability to trace the root cause of faults. Furthermore, how to effectively combine the spatial structural characteristics of the equipment with the temporal evolution characteristics of the data to achieve synergistic analysis of spatiotemporal information, thereby comprehensively and dynamically characterizing the overall health status of the equipment, is a technical challenge that urgently needs to be solved in the field of packaging machine fault diagnosis. Summary of the Invention
[0004] To address the technical problem of how to comprehensively and dynamically characterize the overall health status of equipment, this invention provides the following solution.
[0005] A method for diagnosing packaging machine faults includes: acquiring operational data from multiple measurement points within the packaging machine; constructing a heterogeneous graph of the equipment containing multiple types of nodes and connecting edges based on the physical structure and control logic of the packaging machine; calculating the causal relationship strength between each node using a preset causal analysis method, and weighting and fusing it with the topology of the heterogeneous graph to generate a causal-enhanced directed acyclic graph; dividing the operational data into continuous time steps, and inputting the operational data of each node into a hierarchical Bayesian model within each time step to calculate the probability feature vector representing the potential operational state of the node; for any node in the directed acyclic graph, using a cross-node temporal attention mechanism to fuse the probability feature vector sequence of the node itself, its parent node, and its child nodes in continuous time steps to generate the spatiotemporal fusion feature of the node; performing a graph readout operation on the spatiotemporal fusion features of all nodes to obtain a graph-level feature vector representing the overall operational state of the packaging machine; and inputting the graph-level feature vector into a fully connected network classifier to output the fault type and confidence level of the packaging machine.
[0006] This invention can comprehensively and dynamically characterize the overall health status of equipment.
[0007] Furthermore, the construction of a heterogeneous device graph containing multiple types of nodes and connection edges based on the physical structure and control logic of the packaging machine includes: defining the execution components and sensing components of the packaging machine as device nodes; defining the control unit of the packaging machine as a control node; establishing physical connection edges between device nodes according to the physical association between the execution components and sensing components; and establishing control connection edges between control nodes and device nodes according to the control signal flow direction between the control unit and the execution components and sensing components.
[0008] This invention can integrate prior knowledge of physical structure and control logic into the diagnostic process.
[0009] Furthermore, the packaging machine uses a feeding servo motor and a horizontal sealing cutter as the execution components, a photoelectric sensor as the sensing component, and a programmable logic controller (PLC) as the control node.
[0010] Furthermore, a preset causal analysis method is used to calculate the causal relationship strength between each node, and the strength of the causal relationship is weighted and fused with the topology of the heterogeneous device graph to generate a causal-enhanced directed acyclic graph. This includes: using a preset causal testing method to analyze the time series of the running data of any two nodes, calculating the parameters characterizing their causal relationship, and determining the causal relationship strength between the two nodes based on the parameters; constructing a causal relationship adjacency matrix from the causal relationship strengths of all nodes; representing the topology of the heterogeneous device graph as a topology adjacency matrix; and weighting and fusion the causal relationship adjacency matrix and the topology adjacency matrix according to preset weight coefficients to generate the causal-enhanced directed acyclic graph.
[0011] This invention can uncover the deep causal relationships between variables rather than the superficial correlations, thereby improving the ability to trace the root cause of failures.
[0012] Furthermore, the preset causal analysis method is the PCMCI causal analysis method.
[0013] Furthermore, the step of inputting the operational data of each node into the hierarchical Bayesian model at each time step to calculate the probability feature vector representing the potential operational state of the node includes: setting the hierarchical Bayesian model to include an observation layer, a hidden state layer, and a transcendental parameter layer; using the operational data of the node as the input of the observation layer; assuming that the potential operational states of the nodes in the hidden state layer follow a classification distribution with a Dirichlet distribution as the prior; and inferring the posterior probability distribution representing multiple preset potential operational states in the hidden state layer based on the input of the observation layer, and using the posterior probability distribution as the probability feature vector.
[0014] This invention uses probabilistic feature vectors, which can describe the potential operating state of a node in a probabilistic way.
[0015] Furthermore, by utilizing a cross-node temporal attention mechanism, the probability feature vector sequences of the node itself, its parent node, and its child nodes over consecutive time steps are fused to generate the spatiotemporal fusion features of the node. This includes: for the target node, at the current time step, using its probability feature vector as the query vector; using the probability feature vector sequences of its own, its parent node, and its child nodes over a predetermined period of time steps as the key vector and value vector; calculating the attention scores of the query vector and the key vector, and performing a weighted summation of the value vector to obtain the spatiotemporal fusion features of the node.
[0016] This invention utilizes a query method to conveniently achieve deep coupling between device spatial topology information and multivariate temporal evolution information.
[0017] Furthermore, the step of performing graph readout operation on the spatiotemporal fusion features of all nodes to obtain a graph-level feature vector representing the overall operating status of the packaging machine includes: using a preset aggregation function to aggregate the spatiotemporal fusion features of all nodes to generate the graph-level feature vector.
[0018] Furthermore, operational data from multiple measuring points within the packaging machine is acquired, including: acquiring operational data such as vibration signals, temperature signals, current signals, and operating status images by installing vibration sensors, temperature sensors, current sensors, and industrial cameras at the main motor, feeding belt, and horizontal sealing cutter positions of the packaging machine.
[0019] The present invention also provides a packaging machine fault diagnosis system, including a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to implement the packaging machine fault diagnosis method described above.
[0020] In summary, compared with existing technologies, this invention integrates prior knowledge of the physical structure and control logic of the packaging machine into the diagnostic model. By constructing a heterogeneous diagram of the equipment and performing causal reinforcement, it overcomes the shortcomings of traditional methods that treat data from each measuring point as isolated sequences and ignore the inherent physical connections between components and the fault propagation path. This method can uncover deep causal relationships between variables rather than superficial correlations, fundamentally improving the ability to trace the root cause of faults and effectively avoiding diagnostic misjudgments caused by spurious correlations. Furthermore, through a cross-node temporal attention mechanism, this invention achieves deep coupling between equipment spatial topology information and multivariate temporal evolution information, enabling collaborative analysis of fault propagation between different components and its temporal development patterns. This generates a more comprehensive and accurate representation of the overall operating status of the equipment, ultimately significantly improving the accuracy and reliability of fault type identification. Attached Figure Description
[0021] Figure 1 This is a schematic illustration of a device heterogeneity diagram according to an embodiment of the present invention; Figure 2 This is a schematic diagram illustrating step S5 according to an embodiment of the present invention; Figure 3 This is a schematic diagram illustrating step S7 according to an embodiment of the present invention. Detailed Implementation
[0022] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
[0023] A method for diagnosing packaging machine faults, comprising: S1, acquires operating data from multiple measuring points within the packaging machine; Specifically, by installing vibration sensors, temperature sensors, current sensors, and industrial cameras on key components of the packaging machine, such as the main motor, feeding belt, and horizontal sealing cutter, operational data such as vibration signals, temperature signals, current signals, and operating status images are collected. These multimodal data from different sources and with different structures are then uniformly preprocessed with timestamp alignment and normalization.
[0024] S2, Based on the physical structure and control logic of the packaging machine, construct a heterogeneous device diagram containing multiple types of nodes and connecting edges; Specifically, the execution components and sensing components of the packaging machine can be defined as device nodes; the control unit of the packaging machine can be defined as a control node; physical connection edges between device nodes can be established based on the physical association between the execution components and sensing components; and control connection edges between control nodes and device nodes can be established based on the control signal flow between the control unit and the execution components and sensing components.
[0025] like Figure 1 As shown, specifically taking a typical pillow-type packaging machine as an example, it includes key components such as a feeding servo motor, a horizontal sealing cutter, a photoelectric sensor, and a programmable logic controller (PLC). In this method, the feeding servo motor and the horizontal sealing cutter are the execution components, and the photoelectric sensor is the sensing component; they are collectively defined as equipment nodes. The programmable logic controller (PLC), which is responsible for coordinating the operation of all components, is defined as the control node.
[0026] After defining the nodes, connections are established based on their actual relationships. For example, photoelectric sensors are typically installed near the horizontal sealing cutter to detect color marks on the packaging film to determine the cutting position. Therefore, a physical connection edge is established between the photoelectric sensor node and the horizontal sealing cutter node to represent their close physical association. Simultaneously, the PLC sends pulse signals to the feeding servo motor to control the feeding speed and receives signals from the photoelectric sensor. Therefore, control connection edges are established from the PLC control node to the servo motor device node, and from the photoelectric sensor device node to the PLC control node. In this way, a heterogeneous equipment diagram that fully depicts the physical layout and control flow of the packaging machine is constructed.
[0027] S3, calculate the causal relationship strength between each node using a preset causal analysis method, and then weight and fuse it with the topology of the heterogeneous graph of the device to generate a causal-enhanced directed acyclic graph. Specifically, a preset causal analysis method is used to analyze the time series of the running data of any two nodes, calculate the parameters characterizing their causal relationship, and determine the causal relationship strength between the two nodes based on the parameters; construct a causal relationship adjacency matrix from the causal relationship strengths between all nodes; represent the topology of the heterogeneous device graph as a topology adjacency matrix; and perform weighted fusion of the causal relationship adjacency matrix and the topology adjacency matrix according to preset weight coefficients to generate the causal-enhanced directed acyclic graph.
[0028] For example, operational data from various components of the packaging machine can be collected, such as the time series of the current of the feeding servo motor and the temperature time series of the horizontal sealing cutter. The PCMCI causal analysis method is then used to analyze these two time series. The results may show that, statistically, past values of the motor's current time series can significantly predict future values of the horizontal sealing cutter's temperature time series, yielding a small p-value, such as 0.02. This p-value is converted into a higher causal strength score, such as 0.9, indicating that the motor's operating state has a strong causal influence on the horizontal sealing cutter temperature. This process is repeated for all node pairs to generate a causal adjacency matrix, where each element represents the causal strength between a pair of nodes.
[0029] Next, the heterogeneous graph of devices constructed in the previous step is converted into a topological adjacency matrix. If there is a physical or control connection between two nodes, the corresponding element in the matrix is 1; otherwise, it is 0. To obtain a more comprehensive graph representation, the causal adjacency matrix and the topological adjacency matrix are weighted and fused. For example, the importance weight of the topological structure is set to 0.3, and the importance weight of the causal relationship is set to 0.7. Then, the final fusion result between two nodes is 0.3 multiplied by their topological connection value plus 0.7 multiplied by their causal relationship strength value. The resulting causal enhanced graph, i.e., a directed acyclic graph, not only reflects the static topological structure of the devices but also incorporates the dynamic causal relationships contained in the operational data, allowing the edge weights of the graph to more accurately represent the degree of mutual influence between components.
[0030] S4, the running data is divided into continuous time steps. In each time step, the running data of each node is input into the hierarchical Bayesian model to calculate the probability feature vector that represents the potential running state of the node. Specifically, the running data is divided into multiple time steps using windows of fixed size. The hierarchical Bayesian model includes an observation layer, a hidden state layer, and a transcendental parameter layer; the running data of the nodes is used as the input to the observation layer; it is assumed that the potential running states of the nodes in the hidden state layer follow a classification distribution with a Dirichlet distribution as the prior; based on the input of the observation layer, the posterior probability distribution representing multiple preset potential running states in the hidden state layer is inferred in reverse, and this posterior probability distribution is used as the probability feature vector.
[0031] Specifically, taking the transverse sealing cutter node as an example, its operational data mainly consists of real-time temperature data. This temperature data, such as 180.5 degrees Celsius collected at a certain second, is used as input to the observation layer of the hierarchical Bayesian model. Three possible operating states of the transverse sealing cutter are predefined: normal constant temperature, abnormal temperature rise, and low temperature. These states constitute the hidden state layer of the model. A Dirichlet distribution is used as the prior for the probability of these states, allowing the model to have an initial, uncertain estimate of the states even without data.
[0032] When the observed temperature of 180.5 degrees Celsius is input, a variational inference algorithm is used for calculation. This algorithm updates its belief in the hidden state based on the observed data. Assuming that historical data shows a normal isothermal state typically corresponds to a temperature around 180 degrees Celsius, while an abnormal temperature rise corresponds to a temperature consistently above 185 degrees Celsius, the model, upon receiving the 180.5 degree reading, will calculate the posterior probabilities of these three states. The final output is a probability vector, for example, 0.95, 0.04, 0.01. This probability vector indicates that at the current moment, the horizontal sealing cutter has a 95% probability of being in a normal isothermal state, a 4% probability of being in an abnormal temperature rise state, and a 1% probability of being in a low-temperature state. This probability vector is the probabilistic feature vector of the node at that time step, describing the node's potential operating state in a probabilistic way.
[0033] S5. For any node in the directed acyclic graph, the spatiotemporal fusion feature of the node is generated by fusing the probability feature vector sequences of the node itself, its parent node and child nodes in continuous time steps using the cross-node temporal attention mechanism. Specifically, for any target node in the graph, its set of parent nodes and set of child nodes are determined based on the causal-enhanced directed acyclic graph structure. Then, the sequence of probability feature vectors of the target node itself, all its parent nodes, and all its child nodes at multiple consecutive time steps is taken as input. The cross-node temporal attention mechanism is used to learn the importance weights of each node at different time points, and these weighted probability feature vectors are aggregated to generate a spatiotemporal fusion feature that integrates neighborhood structure information and temporal dynamic information.
[0034] In an optional embodiment, for a target node, at the current time step, its probability feature vector is used as a query vector; the sequence of probability feature vectors of itself, its parent node, and its child nodes over a predetermined period of time is used as a key vector and a value vector; the attention scores of the query vector and the key vector are calculated, and the value vector is weighted and summed to obtain the spatiotemporal fusion features of the node.
[0035] like Figure 2As shown, specifically, the target node is assumed to be the feeding servo motor, currently at the 100th time step. Its parent node is the PLC, and its child nodes are photoelectric sensors. First, the probabilistic feature vector of the feeding servo motor at the 100th time step is obtained, for example, vector A, which will serve as the query vector. This vector represents the state of greatest interest at the moment.
[0036] Next, a historical data segment is collected, such as from time steps 90 to 99. The probabilistic feature vector sequences of the feeding servo motor itself, the PLC, and the photoelectric sensor during this period are aggregated as key and value vectors (the key and value vectors are identical). The attention mechanism calculates the similarity between the query vector A and all these historical key vectors, obtaining a series of attention scores. For example, the calculation results might indicate that the current state of the motor is most relevant to the state of the PLC at step 95 and the state of the motor itself at step 92; therefore, these two historical vectors will receive higher attention weights. All historical value vectors are weighted and summed according to these weights to generate a new feature vector. This new feature vector is the spatiotemporal fusion feature of the feeding servo motor, which not only includes the motor's own evolution history but also intelligently incorporates information from its upstream and downstream related components at moments when they had a critical impact on it in the past.
[0037] S6, perform graph readout operation on the spatiotemporal fusion features of all nodes to obtain a graph-level feature vector representing the overall operating status of the packaging machine; Specifically, the graph average pooling method is used to sum the spatiotemporal fusion feature vectors of all nodes element by element and calculate the average value. Alternatively, the graph attention pooling method is used to learn a global attention weight to perform a weighted summation of the spatiotemporal fusion features of all nodes, ultimately compressing the information of the entire graph into a fixed-dimensional graph-level feature vector.
[0038] Specifically, based on the calculations in the previous step, a spatiotemporal fusion feature containing rich spatiotemporal information has been generated for each node in the heterogeneous diagram of the packaging machine, such as the feeding servo motor, the horizontal sealing cutter, the photoelectric sensor, and the PLC. It is assumed that the spatiotemporal fusion feature of each node is a 64-dimensional vector. To obtain a single indicator that can represent the overall operating status of the entire packaging machine at the current moment, it is necessary to aggregate this information scattered across various nodes.
[0039] An aggregation function is used to perform the graph readout operation. A simple approach is to use average pooling, which involves summing the 64-dimensional spatiotemporal fusion features of all nodes one by one and then dividing by the total number of nodes to obtain a 64-dimensional graph-level feature vector. Alternatively, a more complex aggregation method, such as max pooling, can be used to select the maximum value of the spatiotemporal fusion features of all nodes in each dimension to construct the final graph-level feature vector. The generated graph-level feature vector is like a comprehensive health snapshot taken of the entire packaging machine, condensing the overall performance of all components and their interactions at the current moment.
[0040] S7. Input the graph-level feature vector into a fully connected network classifier and output the fault type and confidence level of the packaging machine.
[0041] Specifically, the graph-level feature vector is input into a multilayer perceptron (MLP) containing at least two hidden layers. Each hidden layer is followed by a ReLU activation function for nonlinear transformation. The output layer uses a Softmax activation function, and the dimension of the output vector is equal to the predefined number of fault types. Each value in the output vector represents the probability or confidence level of the packaging machine belonging to the corresponding fault type. In other embodiments, a normal state type can also be added to the dimension of the output vector. Then, each value in the output vector represents the probability or confidence level of the packaging machine belonging to the corresponding fault type or the normal state type, such as... Figure 3 The diagram shows step S7. The final output vector is (0.05, 0.03, 0.92), which means that the probability of the node being in fault type A is 0.05, the probability of fault type B is 0.03, and the probability of being in a normal state is 0.92.
[0042] The present invention also relates to a packaging machine fault diagnosis system, including a processor and a memory. The memory stores a computer program, and the processor can interact with the memory and call the computer program (e.g., via a bus). The processor then executes the computer program, and when the computer program is executed by the processor, it implements the packaging machine fault diagnosis method of the above embodiments.
[0043] In this invention, the aforementioned memory can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. For example, a computer-readable storage medium can be any suitable magnetic or magneto-optical storage medium.
[0044] This specification and accompanying drawings are merely illustrative descriptions of the invention as defined in the appended claims. It is obvious that those skilled in the art can make various modifications and variations to this invention without departing from its scope.
Claims
1. A method for diagnosing faults in a packaging machine, characterized in that, include: Acquire operational data from multiple measuring points within the packaging machine; Based on the physical structure and control logic of the packaging machine, a heterogeneous device diagram containing multiple types of nodes and connecting edges is constructed. The strength of causal relationships between nodes is calculated using a preset causal analysis method, and then weighted and fused with the topology of the heterogeneous graph of the device to generate a causal-enhanced directed acyclic graph. The running data is divided into consecutive time steps. In each time step, the running data of each node is input into the hierarchical Bayesian model to calculate the probability feature vector that represents the potential running state of the node. For any node in the directed acyclic graph, the spatiotemporal fusion feature of the node is generated by fusing the probability feature vector sequences of the node itself, its parent node and child nodes at consecutive time steps using a cross-node temporal attention mechanism. Perform graph readout operations on the spatiotemporal fusion features of all nodes to obtain graph-level feature vectors that characterize the overall operating status of the packaging machine; The graph-level feature vectors are input into a fully connected network classifier, which outputs the fault type and confidence level of the packaging machine.
2. The method according to claim 1, characterized in that, Based on the physical structure and control logic of the packaging machine, a heterogeneous device graph containing multiple types of nodes and connecting edges is constructed, including: The execution components and sensing components of the packaging machine are defined as device nodes; The control unit of the packaging machine is defined as a control node; Establish physical connection edges between device nodes based on the physical association between the execution component and the sensing component; Based on the control signal flow between the control unit and the execution and sensing components, a control connection edge is established between the control node and the device node.
3. The method according to claim 2, characterized in that, The packaging machine uses a feeding servo motor and a horizontal sealing cutter as the execution components, a photoelectric sensor as the sensing component, and a programmable logic controller (PLC) as the control node.
4. The method according to claim 1, characterized in that, A preset causal analysis method is used to calculate the causal relationship strength between each node, and this strength is then weighted and fused with the topology of the heterogeneous device graph to generate a causally-enhanced directed acyclic graph, including: Using a pre-defined causal test method, the time series of operational data of any two nodes are analyzed to calculate the parameters characterizing their causal relationship, and the strength of the causal relationship between the two nodes is determined based on these parameters. Construct a causal adjacency matrix from the causal relationship strengths between all nodes; The topological structure of the heterogeneous device graph is represented as a topological adjacency matrix; Based on preset weighting coefficients, the causal relationship adjacency matrix and the topological structure adjacency matrix are weighted and fused to generate the causal-enhanced directed acyclic graph.
5. The method according to claim 4, characterized in that, The preset causal analysis method is the PCMCI causal analysis method.
6. The method according to claim 1, characterized in that, In each time step, the operational data of each node is input into the hierarchical Bayesian model to calculate the probabilistic feature vector representing the potential operational state of that node, including: The hierarchical Bayesian model is defined as comprising an observation layer, a hidden state layer, and a transcendental parameter layer; The operational data of the nodes is used as input to the observation layer; Assume that the potential operating states of the nodes in the hidden state layer follow a classification distribution with a Dirichlet distribution as a prior. Based on the input of the observation layer, the posterior probability distribution representing various preset potential operating states in the hidden state layer is inferred in reverse, and the posterior probability distribution is used as the probability feature vector.
7. The method according to claim 1, characterized in that, By utilizing a cross-node temporal attention mechanism, the probabilistic feature vector sequences of the node itself, its parent node, and its child nodes at consecutive time steps are fused to generate the spatiotemporal fusion features of the node, including: For the target node, at the current time step, its probability feature vector is used as the query vector; Use the sequence of probability feature vectors of itself, its parent node, and its child nodes over a predetermined time step as the key vector and value vector; The attention scores of the query vector and key vector are calculated, and the value vectors are weighted and summed to obtain the spatiotemporal fusion features of the node.
8. The method according to claim 1, characterized in that, The graph readout operation performed on the spatiotemporal fusion features of all nodes yields a graph-level feature vector characterizing the overall operating state of the packaging machine, including: A preset aggregation function is used to aggregate the spatiotemporal fusion features of all nodes to generate the graph-level feature vector.
9. The method according to any one of claims 1 to 8, characterized in that, The system acquires operational data from multiple measuring points within the packaging machine, including: acquiring vibration signals, temperature signals, current signals, and operational status images by installing vibration sensors, temperature sensors, current sensors, and industrial cameras at the main motor, feeding belt, and horizontal sealing cutter positions of the packaging machine.
10. A packaging machine fault diagnosis system, characterized in that, It includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the packaging machine fault diagnosis method according to any one of claims 1 to 9.