Method and device for determining fault type of numerical control machine tool

By storing and calculating the fault types of CNC machine tools using knowledge graphs, and using random walk and logistic regression methods to automatically determine the fault types, the problem of low fault maintenance efficiency caused by manual intervention is solved, and efficient and accurate fault type determination is achieved.

CN115221330BActive Publication Date: 2026-06-26CHINA MOBILE SHANGHAI ICT CO LTD +2

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA MOBILE SHANGHAI ICT CO LTD
Filing Date
2021-04-14
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

In the current technology, the fault inspection and maintenance of CNC machine tools mainly rely on manual intervention, resulting in low fault maintenance efficiency.

Method used

A knowledge graph is used to store CNC machine tool knowledge. By obtaining vectors of fault entities and fault types, similarity data is calculated, and random walk and logistic regression methods are used to automatically determine the fault type.

Benefits of technology

It improves the efficiency of fault type identification, enhances the automation and visualization of fault maintenance, and improves the accuracy and reusability of fault type identification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115221330B_ABST
    Figure CN115221330B_ABST
Patent Text Reader

Abstract

The application provides a method and device for determining fault type of a numerical control machine tool, wherein the method comprises: obtaining a first vector and a plurality of second vectors in a database, wherein the database is a database for storing knowledge of the numerical control machine tool in a manner of a knowledge graph; the first vector is used for representing an entity of the numerical control machine tool that has a fault, and the second vector is used for representing a fault type of the numerical control machine tool; calculating corresponding fault type similarities according to the first vector and the plurality of second vectors to obtain similarity data; and determining the fault type of the numerical control machine tool according to the similarity data. Through the application, the problem that the fault type is determined in a manner of manual intervention in the prior art, resulting in low fault maintenance efficiency, is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of information technology, and in particular to a method and apparatus for determining the fault type of a CNC machine tool. Background Technology

[0002] With the development of industrial automation, CNC machine tools are increasingly widely used in industrial manufacturing, such as CNC lathes, CNC milling machines, CNC grinding machines, and CNC electrical discharge machining tools. The machine tools, power hydraulic systems, electrical control systems, and integrated digital program control systems ensure their intelligence and high performance. Therefore, maintaining and diagnosing CNC machine tool faults is a key focus in the field. However, current technical solutions for CNC machine tool fault inspection and maintenance largely rely on manual intervention, employing techniques based on expert systems and simple rule-based reasoning, resulting in low fault maintenance efficiency. Summary of the Invention

[0003] This application provides a method and apparatus for determining the fault type of a CNC machine tool, in order to solve the problem that the fault type determination in the prior art is done by manual intervention, resulting in low fault maintenance efficiency.

[0004] To solve the above problems, this application is implemented as follows:

[0005] In a first aspect, embodiments of this application provide a method for determining the fault type of a CNC machine tool. The method includes: acquiring a first vector and a plurality of second vectors from a database, wherein the database is a database that stores knowledge of CNC machine tools in a knowledge graph manner; the first vector is used to characterize the entity of the CNC machine tool that has malfunctioned; calculating the corresponding fault type similarity based on the first vector and the plurality of second vectors to obtain similarity data; and determining the fault type of the CNC machine tool based on the similarity data.

[0006] Secondly, embodiments of this application provide a device for determining the fault type of a CNC machine tool, applied to a terminal. The method includes: an acquisition module, used to acquire a first vector and multiple second vectors from a database, wherein the database is a database that stores knowledge of CNC machine tools in a knowledge graph manner; the first vector is used to characterize the entity of the CNC machine tool that has malfunctioned, and the second vectors are used to characterize the fault type of the CNC machine tool; a calculation module, used to calculate the corresponding fault type similarity based on the first vector and the multiple second vectors to obtain similarity data; and a determination module, used to determine the fault type of the CNC machine tool based on the similarity data.

[0007] Thirdly, embodiments of this application also provide an electronic device, including: a processor, a memory, and a program stored in the memory and executable on the processor, wherein when the program is executed by the processor, it implements the steps of the method for determining the type of CNC machine tool fault as described in the first aspect.

[0008] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the method for determining the fault type of a CNC machine tool as described in the first aspect.

[0009] In this embodiment, after storing the knowledge of CNC machine tools in a database based on a knowledge graph, the fault type of the CNC machine tool can be determined based on the similarity data between the first vector of the entity of the CNC machine tool that has malfunctioned and multiple second vectors used to characterize the fault type of the CNC machine tool. That is, the fault type can be determined automatically based on a knowledge graph, thereby solving the problem of low fault maintenance efficiency caused by manual intervention in the fault type determination in the prior art. This improves the efficiency of fault type determination. Moreover, the fault type determination based on the knowledge of CNC machine tools stored in a knowledge graph has strong reusability and better visualization. Attached Figure Description

[0010] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0011] Figure 1 This is a flowchart illustrating the method for determining the fault type of a CNC machine tool provided in an embodiment of this application;

[0012] Figure 2 This is a schematic diagram illustrating the fault type reasoning process of a CNC machine tool provided in an embodiment of this application;

[0013] Figure 3 This is a schematic diagram illustrating the main process of constructing a CNC machine tool knowledge graph provided in the embodiments of this application;

[0014] Figure 4 This is a schematic diagram illustrating the data source and data processing of the CNC machine tool knowledge graph provided in this application embodiment;

[0015] Figure 5 This is a schematic diagram of entity recognition and relation extraction based on Attention+Bi-LSTM provided in the embodiments of this application;

[0016] Figure 6 This is an overall schematic diagram of the modeling of CNC machine tools and the reasoning of fault types provided in the embodiments of this application;

[0017] Figure 7 This is a schematic diagram of the structure of the CNC machine tool fault type determination device provided in this application. Detailed Implementation

[0018] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0019] The terms "first," "second," etc., used in the embodiments of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products, or devices. Additionally, the use of "and / or" in this application indicates at least one of the connected objects, such as A and / or B and / or C, representing seven possibilities: including A alone, B alone, C alone, and the presence of both A and B, both B and C, both A and C, and the presence of A, B, and C.

[0020] It should be noted that the terminal involved in this application may be a mobile phone, tablet computer, laptop computer, personal digital assistant (PDA), mobile internet device (MID), wearable device, or in-vehicle device, etc.

[0021] The following describes the method for determining the fault type of a CNC machine tool provided in the embodiments of this application. See also... Figure 1 , Figure 1 This is a flowchart illustrating the method for determining the fault type of a CNC machine tool provided in the embodiments of this application. Figure 1 The method for determining the fault type of a CNC machine tool, as shown, can be executed by a terminal. The steps of this method include:

[0022] Step 102: Obtain a first vector and multiple second vectors from the database, wherein the database is a database that stores knowledge of CNC machine tools in the form of a knowledge graph; the first vector is used to represent the entity of the CNC machine tool that has malfunctioned, and the second vector is used to represent the fault type of the CNC machine tool.

[0023] Step 104: Calculate the corresponding fault type similarity based on the first vector and multiple second vectors to obtain similarity data;

[0024] Step 106: Determine the fault type of the CNC machine tool based on the similarity data.

[0025] Through steps 102 and 106 above, after storing the knowledge of CNC machine tools in the database based on knowledge graphs, the fault type of the CNC machine tool can be determined based on the similarity data between the first vector of the entity of the CNC machine tool that has malfunctioned and multiple second vectors used to characterize the fault type of the CNC machine tool. That is, the fault type can be determined automatically based on knowledge graphs, thereby solving the problem of low fault maintenance efficiency caused by manual intervention in the fault type determination in the prior art. This improves the efficiency of fault type determination. Moreover, the fault type determination based on the knowledge of CNC machine tools stored in the knowledge graph method has strong reusability and better visualization.

[0026] In a specific embodiment of this application, the knowledge in the knowledge graph corresponding to the CNC machine tool is stored in a table-structured database in the form of (S, P, O) triples, for example, (entity, attribute, attribute value), (entity A, relation, entity B), specifically (PLC fault, fault type, electrical fault), which can be simplified to (h, r, t), where h represents the head entity, r represents the relation, and t represents the tail entity. That is, the vectors in this embodiment are stored in the form of triples. Specifically, the TransH method can be used to represent triples as vectors, that is, all entities and relations in the knowledge graph are represented as a low-dimensional vector, i.e., (h, r, t) → Since a triple can include (entity A, relation, entity B), representing it as a vector allows for quick and easy identification of the fault type of the malfunctioning entity.

[0027] For example, the entity of the CNC machine tool that malfunctions, represented by the first vector, can be a hydraulic cylinder or a hydraulic motor, i.e., a hydraulic cylinder or hydraulic motor malfunction. The malfunction types represented by multiple second vectors can include: hydraulic malfunctions, mechanical malfunctions, and electrical malfunctions. Of course, the above is merely an example; the entity that malfunctions can also be other entities, and the malfunction types can include even more types, depending on the specific circumstances.

[0028] In an optional embodiment of this application, the method of determining the fault type of the CNC machine tool based on similarity in step 106 above may further include:

[0029] Steps 106-11: Select N data points from multiple similarity data points in descending order of similarity, and use these N data points as a candidate set;

[0030] Steps 106-12 determine the walk results of the candidate set through random walk, wherein the guiding parameters in the random walk include the state transition probabilities of N similarity labels;

[0031] Steps 106-13: Score the walk results using a scoring function to obtain the scoring results;

[0032] Steps 106-14: The scoring results are calculated using logistic regression to obtain the calculation results, which are used to indicate the fault type of the CNC machine tool.

[0033] In steps 106-11 to 106-14 above, similarity can be represented by scores. Therefore, the N similarities can be N scores from highest to lowest. It should be noted that if similarity is represented by scores, the sum of all scores is 1. For example, if there are four types of faults, four similarities can be obtained, such as 0.1, 0.6, 0.2, and 0.1. If N is 2, the similarities in the candidate set are 0.6 and 0.2. Of course, the above similarities and the values ​​of N are merely illustrative examples; in specific application scenarios, appropriate settings can be made according to the actual situation. The fault types determined by the above probabilistic logical reasoning method that integrates numerical calculations are more accurate and efficient than manual intervention.

[0034] Based on this, in specific application scenarios, the similarity scores are 0.6 (hydraulic fault), 0.3 (mechanical fault), and 0.1 (electrical fault), respectively, with N taking the value of 2. Therefore, steps 106-11 to 106-14 above can include:

[0035] Step 11: Obtain the top 2 candidates (the two with the highest scores) as the candidate set, and convert the similarity score into a parameter of the state transition probability;

[0036] If there are four types of the aforementioned faults, then four similarity scores can be obtained, such as 0.1, 0.6, 0.2, and 0.1. If N is 2, then the candidate set includes 0.6 and 0.2.

[0037] Step 12: Incorporate the state transition probability into the probabilistic logic reasoning process as a guiding parameter in the random walk.

[0038] Step 13: Calculate the various possibilities of the walk using the following scoring function:

[0039]

[0040] Among them, F ρ F is the set of inference rules obtained from random walks, where f is a rule, ρ is the prediction target, δ(f) is the estimate of rule f, and F is the set of rules.

[0041] Step 14: Apply logistic regression to calculate the probability of entity relationships. For example, the final result can be deduced as (hydraulic cylinder and hydraulic motor failure, failure type, hydraulic failure), meaning the failure type of the hydraulic cylinder and hydraulic motor failure is a hydraulic transmission and control failure. The calculation formula is as follows:

[0042] P(ρ=y|X)=F(X) y (1-F(X)) 1-y

[0043]

[0044] Where y is the 0-1 label value of ρ; the -1n value of P(ρ=y|X) is the loss function of the rule. The purpose of the calculation is to make the loss function as small as possible and to update the weight of the rule accordingly; then, the rule with smaller weight is removed from F and the model (rule, weight, function) is output. The new triple is inferred from this model.

[0045] As can be seen, in the embodiments of this application, such as Figure 2 As shown, prior knowledge obtained through the TransH-based numerical calculation method is incorporated into the probabilistic logic reasoning process of the random walk to deduce the fault type. This approach improves the efficiency of fault diagnosis and prediction for CNC machine tools while ensuring the accuracy of the reasoning.

[0046] In an optional embodiment of this application, before obtaining the first vector and multiple second vectors from the database in step 102, the method of this application may further include:

[0047] Step 201: Construct the framework of the knowledge graph corresponding to the CNC machine tool;

[0048] Step 202: Obtain data from the CNC machine tool based on the framework;

[0049] Step 203: Extract knowledge from the data to obtain extraction results. The extraction results include a third vector representing knowledge in the form of triples. The knowledge includes at least one of the following: entity, entity attributes, and relationships between entities.

[0050] Step 204: Perform graph fusion on the extraction results to obtain the target vector for storage in the database, wherein the target vector includes a first vector and a second vector;

[0051] Step 206: Construct a knowledge graph of the CNC machine tool based on the target vector.

[0052] As can be seen from steps 201 to 206 above, before determining the fault type in a CNC machine tool, it is necessary to construct a knowledge graph of the CNC machine tool. For example... Figure 3 As shown, the main process of constructing a knowledge graph for CNC machine tools includes: knowledge modeling, data acquisition, and knowledge extraction. Specifically, first, a basic knowledge graph framework for the CNC machine tool is determined for knowledge modeling, then data acquisition is performed, and the knowledge extracted from the data is added to the framework. It should be noted that for newly acquired knowledge, such as real-time data from the platform, a new framework needs to be extracted based on the relationships within the knowledge. Then, the framework and knowledge are integrated. In other words, this application uses a combination of top-down and bottom-up approaches to construct the knowledge graph for CNC machine tools.

[0053] Furthermore, the framework for constructing the knowledge graph corresponding to the CNC machine tool involved in step 201 above can further include:

[0054] Step 201-11: Determine the knowledge elements in the domain related to CNC machine tools; wherein, the knowledge elements are used to represent the data corresponding to the attributes of CNC machine tools;

[0055] In the specific application scenarios of this application embodiment, the knowledge element may refer to the various components of the CNC machine tool itself, the performance parameters of the CNC machine tool, historical fault cases, real-time data of the machine tool, etc.

[0056] Steps 201-12: Configure classes for representing the concepts related to the CNC machine tool field;

[0057] In the specific application scenarios of this application embodiment, for example, CNC machine tools and historical cases are the major categories; the major categories are divided into subcategories, such as CNC machine tools and lathes, grinding machines, etc., and each category contains a specific entity, such as each machine tool is an entity.

[0058] Steps 201-13: Configure data based on class to characterize the data associated with the machine tool;

[0059] The data associated with the CNC machine tool refers to attributes and relationships. These attributes and relationships are defined based on classes, representing the inherent attributes of each entity and the relationships between entities. For example, the equipment name and equipment number of a CNC machine tool are its attributes, and the occurrence of a certain fault in a CNC machine tool represents the relationship between the CNC machine tool and the fault.

[0060] Step 201-14: Configure constraints, wherein the constraints are used to indicate the constraints between the CNC machine tool and the target machine tool, which is different from the CNC machine tool.

[0061] The constraint can be an attribute of a CNC machine tool that its subclasses, such as lathes and grinding machines, also possess; in other words, the constraint is transitive.

[0062] Steps 201-11 to 201-14 above constitute the process of knowledge modeling of the CNC machine tool in this application; wherein, regarding the method of obtaining CNC machine tool data based on the framework involved in step 202 above, in this application, the CNC machine tool data can be further obtained from at least one of the following: real-time platform data, equipment parameter data, experience data (such as expert knowledge), and historical case data.

[0063] Historical case data and real-time platform data are obtained directly from the system's backend database, while some knowledge acquired from the internet is obtained using web scraping techniques, specifically... Figure 4 As shown.

[0064] Optionally, the method of extracting knowledge from the data involved in step 203 above may further include at least one of the following:

[0065] Step 203-11: Extract knowledge from the data based on the preset template;

[0066] Step 203-12: Extract knowledge from the data based on the target neural network model.

[0067] As can be seen, after obtaining the data, the entities, attributes, and relationships are extracted. Different methods are used for different types and structures of data.

[0068] For structured data such as real-time platform data and semi-structured data such as expert instructions, a rule-based approach is adopted. This involves extracting the corresponding entities and relationships using pre-set templates as the basic data resources for the graph, and then labeling the entities and relationships. For example, local relationships between equipment and components, such as machine tools and cutting tools; collaborative relationships between equipment, such as machine tool A and machine tool B; and inheritance relationships between concepts and their subclasses, such as the subcategories of CNC machine tools.

[0069] For unstructured data such as historical case data, an attention mechanism is added to the bidirectional Long Short-Term Memory (LSTM) neural network model (the target neural network model) to transform entity acquisition and relation extraction into a multi-classification problem, thereby obtaining entities and relations from this type of data. For example... Figure 5 As shown, the flow steps of the corresponding algorithm model in this application include:

[0070] Step 31: The input layer inputs the sentence into the model, such as the sentence "CK61100E large CNC series machine tool belongs to medium and large machine tool, ... main configuration description: ... standard configuration of vertical four-station 300*300 electric tool post".

[0071] Step 32, the word vector layer is used for a given sentence S containing T words: S = x1, x2, ..., x T The example is represented in word vector form, that is Figure 5 In the context of e1, e2, ..., e n For example, in step 31, after the sentence has been segmented into words, each word is mapped to a low-dimensional space. H1

[0072] Step 33: The Bi-LSTM layer first introduces a gating mechanism, simultaneously incorporating the previous cell state into the calculation of the input gate, forget gate, and new information. Finally, the output is the current hidden state h. t Based on the current cell state o t The weight matrix of the output gate, tanh(c t The product of ) yields:

[0073] h t =o t tanh(c t )

[0074] Furthermore, this layer has two networks, forward and backward, which capture high-level features by capturing past and future information in the sentence to obtain contextual information. For example... Figure 5 As shown, the final output of this layer is in the following form:

[0075]

[0076] Step 34: The Attention layer generates weight vectors and fuses them with the vector set generated by the Bi-LSTM layer, merging the word-level features into sentence-level feature vectors, i.e., r in the formula below. The final sentence h used for classification is then used. * Represented as:

[0077] h * =tanh(r)

[0078] In step 35, the output layer uses a softmax classifier to predict labels based on the sentence's feature vectors, ultimately completing entity recognition and extraction of semantic relationships between entities. For example, the sentence in step 31 can ultimately extract two entities: "CK61100E large CNC series machine tool" and "standard vertical four-station 300*300 electric tool holder," as well as the overall and local relationships between these two entities.

[0079] Based on the above Figures 1 to 5 The overall process in the embodiments of this application is as follows: Figure 6 As shown, based on this, the overall process in this application includes the following steps:

[0080] Step 301, knowledge modeling, involves analyzing and organizing knowledge in the field of CNC machine tools to summarize a basic knowledge framework.

[0081] Step 302, data acquisition, which involves using natural language processing methods such as web crawling to acquire data from existing historical databases and real-time data from the platform and storing it in the database.

[0082] Step 303, knowledge acquisition; wherein, in this application, a method combining rule-based and deep learning is adopted, and when analyzing unstructured text data, an attention mechanism is added to the bidirectional LSTM to acquire entities and relationships.

[0083] Step 304, Knowledge Fusion; Here, the data in the platform can be added to the knowledge graph, and the data processing work such as entity recognition and relation extraction described above is carried out to fuse the graph, thereby ensuring the dynamic update and integrity of the graph.

[0084] Step 305, CNC machine tool fault diagnosis based on knowledge reasoning. In this application, prior knowledge obtained through the TransH-based numerical calculation method is incorporated into the probabilistic logic reasoning process of the random walk, ensuring the speed and accuracy of the reasoning, enabling rapid fault diagnosis and prediction of CNC machine tools.

[0085] Step 306, Knowledge Application; This involves collecting and analyzing historical and real-time data of the machine tool, using knowledge graph technology to analyze and monitor the CNC machine tool, accurately understanding its operating status and displaying it visually, and using the reasoning function of the knowledge graph to perform in-depth data mining to achieve early warning, rapid location and elimination of faults, restore normal machine tool operation, and improve equipment utilization efficiency.

[0086] As can be seen, by constructing a knowledge graph of CNC machine tools and using a probabilistic logic reasoning method that integrates numerical calculations in the knowledge graph, the reasoning process for fault types becomes more interpretable and the reasoning results are more accurate, making it easier to accurately diagnose and analyze CNC machine tools and provide timely solutions.

[0087] The various optional implementation methods described in the embodiments of this application can be combined with each other or implemented individually without conflict, and the embodiments of this application do not limit this.

[0088] See Figure 7 , Figure 7 This is a structural diagram of the CNC machine tool fault type determination device provided in the embodiments of this application. Figure 7 As shown, the CNC machine tool fault type determination device 700 includes:

[0089] The acquisition module 72 is used to acquire a first vector and multiple second vectors from the database, wherein the database is a database that stores knowledge of CNC machine tools in the form of a knowledge graph; the first vector is used to represent the entity of the CNC machine tool that has malfunctioned, and the second vector is used to represent the malfunction type of the CNC machine tool;

[0090] Calculation module 74 is used to calculate the corresponding fault type similarity based on the first vector and multiple second vectors to obtain similarity data;

[0091] The determination module 76 is used to determine the fault type of the CNC machine tool based on similarity data.

[0092] By using the apparatus in this application embodiment, after storing the knowledge of CNC machine tools in a database based on a knowledge graph, the fault type of the CNC machine tool can be determined based on the similarity data between the first vector of the entity of the CNC machine tool that has malfunctioned and multiple second vectors used to characterize the fault type of the CNC machine tool. In other words, the fault type can be determined automatically based on a knowledge graph, thereby solving the problem of low fault maintenance efficiency caused by manual intervention in the fault type determination in the prior art. This improves the efficiency of fault type determination. Moreover, the fault type determination based on the knowledge of CNC machine tools stored in the knowledge graph has strong reusability and better visualization.

[0093] Optionally, the determining module 76 in this embodiment may further include: a filtering unit, configured to filter N data from the plurality of similarity data in descending order, and to use the N data as a candidate set; a first determining unit, configured to determine the walk result of the candidate set by means of a random walk, wherein the guiding parameters in the random walk include the state transition probabilities of the N similarity identifiers; a scoring unit, configured to score the walk result by means of a scoring function; and a calculation unit, configured to calculate the scoring result by means of logistic regression to obtain a calculation result, wherein the calculation result is used to indicate the fault type of the CNC machine tool.

[0094] Optionally, the apparatus in this embodiment may further include: a first construction module, configured to construct a framework of a knowledge graph corresponding to the CNC machine tool before acquiring a first vector and multiple second vectors from the database; an acquisition module, configured to acquire data of the CNC machine tool based on the framework; an extraction module, configured to extract knowledge from the data to obtain an extraction result, wherein the extraction result includes a third vector representing knowledge in the form of a triple, and the knowledge includes at least one of the following: an entity, an attribute of an entity, and a relationship between entities; a fusion module, configured to perform graph fusion on the extraction result to obtain a target vector for storage in the database, wherein the target vector includes the first vector and the second vector; and a second construction module, configured to construct the knowledge graph of the CNC machine tool based on the target vector.

[0095] Optionally, the first construction module in this application embodiment may further include: a second determining unit, configured to determine knowledge elements in the domain associated with the CNC machine tool; wherein the knowledge elements are used to characterize data corresponding to the attributes of the CNC machine tool; a first configuring unit, configured to configure classes for characterizing concepts related to the CNC machine tool domain; a second configuring unit, configured to configure data for characterizing the CNC machine tool based on the classes; and a first configuring unit, configured to configure constraints, wherein the constraints are used to indicate the constraints between the CNC machine tool and a target machine tool, the target machine tool being different from the CNC machine tool.

[0096] Optionally, the extraction module in this application embodiment includes at least one of the following: a first extraction unit, used to extract knowledge from the data based on a preset template; and a second extraction unit, used to extract knowledge from the data based on a target neural network model.

[0097] The CNC machine tool fault type determination device 700 can achieve the following in the embodiments of this application: Figure 1 The various processes in the method embodiments, and the ways to achieve the same beneficial effects, will not be repeated here to avoid repetition.

[0098] Those skilled in the art will understand that all or part of the steps of the methods described in the above embodiments can be implemented by hardware related to program instructions, and the program can be stored in a readable medium. This application also provides a readable storage medium storing a computer program, which, when executed by a processor, can implement the above-described methods. Figure 1 Any step in the corresponding method embodiment can achieve the same technical effect, and will not be repeated here to avoid repetition.

[0099] The storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0100] The above description represents the preferred embodiments of this application. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles described in this application, and these improvements and modifications should also be considered within the scope of protection of this application.

Claims

1. A method for determining the fault type of a CNC machine tool, characterized in that, The method includes: Obtain a first vector and multiple second vectors from a database, wherein the database is a database that stores knowledge of CNC machine tools in the form of a knowledge graph; the first vector is used to represent the entity of the CNC machine tool that has malfunctioned, and the second vector is used to represent the malfunction type of the CNC machine tool; Based on the first vector and multiple second vectors, calculate the corresponding fault type similarity to obtain similarity data; The fault type of the CNC machine tool is determined based on the similarity data; Determining the fault type of the CNC machine tool based on the similarity includes: From the multiple similarity data, N data points are selected in descending order of similarity, and these N data points are used as a candidate set. The candidate set is determined by a random walk, wherein the guiding parameters in the random walk include the state transition probabilities of the N similarity identifiers, and the walk result includes a set of inference rules; The walk results are scored using a scoring function to obtain a scoring result, which is the sum of the estimated values ​​of each inference rule in the inference rule set. The scoring results are calculated using logistic regression to obtain the calculation results, which are used to indicate the fault type of the CNC machine tool.

2. The method for determining the fault type of a CNC machine tool according to claim 1, characterized in that, Before retrieving the first vector and multiple second vectors from the database, the method further includes: Construct a framework for the knowledge graph corresponding to the CNC machine tool; Data of the CNC machine tool is acquired based on the aforementioned framework; Knowledge extraction is performed on the data to obtain extraction results, wherein the extraction results include a third vector representing the knowledge in the form of triples, and the knowledge includes at least one of the following: entity, attribute of the entity, and relationship between the entities; The extraction results are subjected to spectral fusion to obtain a target vector for storage in the database, wherein the target vector includes the first vector and the second vector; A knowledge graph of the CNC machine tool is constructed based on the target vector.

3. The method for determining the fault type of a CNC machine tool according to claim 2, characterized in that, The framework for constructing the knowledge graph corresponding to the CNC machine tool includes: Determine the knowledge elements in the domain associated with the CNC machine tool; wherein the knowledge elements are used to characterize data corresponding to the attributes of the CNC machine tool; Configure classes for representing concepts related to the CNC machine tool field; The class configuration is used to characterize the data associated with the machine tool; Configure constraints, wherein the constraints are used to indicate the constraints between the CNC machine tool and the target machine tool, the target machine tool being different from the CNC machine tool.

4. The method for determining the fault type of a CNC machine tool according to claim 2, characterized in that, The extraction of knowledge from the data includes at least one of the following: Knowledge extraction is performed on the data based on a preset template; Knowledge extraction is performed on the data based on the target neural network model.

5. A device for determining the fault type of a CNC machine tool, applied in a terminal, characterized in that, include: The acquisition module is used to acquire a first vector and multiple second vectors from a database, wherein the database is a database that stores knowledge of CNC machine tools in the form of a knowledge graph; the first vector is used to represent the entity of the CNC machine tool that has malfunctioned, and the second vector is used to represent the malfunction type of the CNC machine tool; The calculation module is used to calculate the corresponding fault type similarity based on the first vector and multiple second vectors to obtain similarity data; A determination module is used to determine the fault type of the CNC machine tool based on the similarity data; The determining module includes: A filtering unit is configured to filter N data points from the plurality of similarity data points in descending order, and to use the N data points as a candidate set; The first determining unit is used to determine the walk result of the candidate set by means of random walk, wherein the guiding parameters in the random walk include the state transition probabilities of the N similarity identifiers, and the walk result includes a set of inference rules; The scoring unit is used to score the walk results through a scoring function to obtain a scoring result, which is the sum of the estimated values ​​of each inference rule in the inference rule set; The calculation unit is used to calculate the scoring results through logistic regression to obtain the calculation results, wherein the calculation results are used to indicate the fault type of the CNC machine tool.

6. The device for determining the fault type of a CNC machine tool according to claim 5, characterized in that, The device further includes: The first construction module is used to construct the framework of the knowledge graph corresponding to the CNC machine tool before obtaining the first vector and multiple second vectors from the database; The acquisition module is used to acquire data of the CNC machine tool based on the framework; An extraction module is used to extract knowledge from the data to obtain extraction results, wherein the extraction results include a third vector representing the knowledge in the form of triples, and the knowledge includes at least one of the following: an entity, the attribute of the entity, and the relationship between the entities; A fusion module is used to perform graph fusion on the extraction results to obtain a target vector for storage in the database, wherein the target vector includes the first vector and the second vector; The second construction module is used to construct a knowledge graph of the CNC machine tool based on the target vector.

7. The device for determining the fault type of a CNC machine tool according to claim 6, characterized in that, The first building module includes: The second determining unit is used to determine knowledge elements in the field associated with the CNC machine tool; wherein the knowledge elements are used to characterize data corresponding to the attributes of the CNC machine tool; The first configuration unit is used to configure classes that characterize concepts related to the CNC machine tool field; The second configuration unit is used to configure data associated with the machine tool based on the class configuration. The first configuration unit is used to configure constraints, wherein the constraints are used to indicate the constraints between the CNC machine tool and the target machine tool, and the target machine tool is different from the CNC machine tool.

8. The device for determining the fault type of a CNC machine tool according to claim 6, characterized in that, The extraction module includes at least one of the following: The first extraction unit is used to extract knowledge from the data based on a preset template. The second extraction unit is used to extract knowledge from the data based on the target neural network model.

9. An electronic device, characterized in that, include: A processor, a memory, and a program stored in the memory and executable on the processor, wherein the program, when executed by the processor, implements the steps of the method for determining the fault type of a CNC machine tool as described in any one of claims 1 to 4.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the method for determining the fault type of a CNC machine tool as described in any one of claims 1 to 4.