Anomaly detection method, anomaly detection device, and program
The method uses spindle load data and process identification to detect anomalies in machining processes, addressing the challenge of limited data availability by employing normal models, facilitating quick and effective anomaly detection.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- KOBE STEEL LTD
- Filing Date
- 2024-12-05
- Publication Date
- 2026-06-17
Smart Images

Figure 2026098485000001_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to an abnormality detection method, an abnormality detection device, and a program.
Background Art
[0002] Patent Document 1 discloses a machining diagnosis device that performs machining diagnosis using a learned model. Patent Document 2 discloses a method for performing abnormality detection by estimating a probability distribution followed by variations in feature amounts in consideration of fluctuations in load due to disturbances applied to a tool.
Prior Art Documents
Patent Documents
[0003]
Patent Document 1
Patent Document 2
Summary of the Invention
Problems to be Solved by the Invention
[0004] However, in the above prior art, in order to create a learned model or estimate a probability distribution, it is necessary to repeatedly perform a target machining process before actual production.
[0005] The present invention has been made in view of the above problems, and its main object is to provide an abnormality detection method, an abnormality detection device, and a program that enable easy abnormality detection even in a machining process with little actual performance.
Means for Solving the Problems
[0006] To solve the above problems, an abnormality detection method according to one aspect of the present invention comprises: an acquisition step of acquiring spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor; a selection step of selecting a normal model that represents the relationship between time and load during normal conditions, corresponding to the machining process identified by the process identification data; and an abnormality detection step of detecting an abnormality in the machining process using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, wherein the normal model is a model that represents the relationship between time and load in past machining processes when an abnormality was not detected by a simple load determination that determines an abnormality based on load variability.
[0007] In the above embodiment, the system may further include a simplified load determination step that determines an abnormality based on the load variation in the spindle load data.
[0008] In the above embodiment, the simplified load determination step may determine an abnormality by using the error between the average value and the root mean square of a predetermined number of recent points of the load in the spindle load data as a simplified load determination index.
[0009] In the above embodiment, the acquisition step may further acquire spindle speed data representing the rotational speed of the spindle, and the simplified load determination step may correct the simplified load determination index to a smaller value in the interval in which the rotational speed of the spindle changes.
[0010] In the above embodiment, if no abnormality is detected in the simplified load determination step, the embodiment may further include an update step in which the normal model is updated based on the spindle load data.
[0011] In the above embodiment, the normal model is generated based on a predetermined number of spindle load data, and the update step may exclude the spindle load data with the largest degree of difference from the spindle load data for which abnormalities were not determined in the simplified load determination step and the predetermined number of spindle load data for the normal model, and generate the normal model based on the remaining predetermined number of spindle load data.
[0012] In the above embodiment, the acquisition step may further include acquiring position coordinate data representing the machining position during the machining process, the normal model further including the relationship between time and machining position under normal conditions, and a position deviation determination step which compares the position coordinate data with the normal model to determine the position deviation of the machining position.
[0013] In the above embodiment, the system may further include a notification step in which a notification is sent to a predetermined terminal when an abnormality is detected by the abnormality detection step or when a positional misalignment is determined by the positional misalignment determination step.
[0014] In the above embodiment, the specific step of identifying the processing step using the process identification data may be further included.
[0015] Furthermore, another embodiment of the present invention provides a method for generating a normal model, comprising: an acquisition step of acquiring spindle load data representing the load on a spindle during a machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor; a simplified load determination step of determining an abnormality based on the variation in the load in the spindle load data; and, if no abnormality is determined in the simplified load determination step, a generation step of generating a normal model representing the relationship between time and load under normal conditions based on the spindle load data.
[0016] Furthermore, another aspect of the present invention provides an abnormality detection device comprising: an acquisition unit that acquires spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor; a selection unit that selects a normal model representing the relationship between time and load during normal operation, corresponding to the machining process identified by the process identification data; and an abnormality detection unit that detects abnormalities in the machining process using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, wherein the normal model is a model representing the relationship between time and load in past machining processes when no abnormality was detected by a simple load determination that determines abnormalities based on load variability.
[0017] Furthermore, a program in another aspect of the present invention causes a computer to perform the following actions: acquire spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor; select a normal model representing the relationship between time and load under normal conditions, corresponding to the machining process identified by the process identification data; and detect an abnormality in the machining process using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, wherein the normal model is a model representing the relationship between time and load in past machining processes where an abnormality was not detected by a simple load determination that determines an abnormality based on load variability. [Effects of the Invention]
[0018] According to the present invention, abnormalities can be easily detected even in processing steps with little track record. [Brief explanation of the drawing]
[0019] [Figure 1] This figure shows an example of an anomaly detection device. [Figure 2] This figure shows an example of an anomaly detection method. [Figure 3] This figure follows Figure 2. [Figure 4] It is a diagram showing an example of a misalignment determination step. [Figure 5] It is a diagram for explaining misalignment. [Figure 6] It is a diagram showing an example of an abnormality detection step. [Figure 7] It is a diagram following FIG. 6. [Figure 8] It is a diagram following FIG. 7. [Figure 9] It is a diagram following FIG. 8. [Figure 10] It is a diagram for explaining abnormality detection. [Figure 11] It is a diagram for explaining abnormality detection. [Figure 12] It is a diagram for explaining abnormality detection. [Figure 13] It is a diagram for explaining abnormality detection. [Figure 14] It is a diagram for explaining abnormality detection. [Figure 15] It is a diagram showing an example of a simple load determination step. [Figure 16] It is a diagram showing an example of a correction value calculation step. [Figure 17] It is a diagram for explaining simple load determination. [Figure 18] It is a diagram showing an example of a normal model update step. [Figure 19] It is a diagram following FIG. 18.
Embodiments for Carrying Out the Invention
[0020] Hereinafter, embodiments of the present invention will be described with reference to the drawings. In this specification and each drawing, elements that are the same as those described above with respect to the already shown drawings may be denoted by the same reference numerals, and detailed descriptions may be omitted as appropriate.
[0021] FIG. 1 is a block diagram showing a configuration example of an abnormality detection device 1. The abnormality detection device 1 is a device that detects the occurrence or omen of an abnormality in a machining process executed by a machine tool 2 and notifies an operator.
[0022] The anomaly detection device 1 is a computer equipped with a control unit 10. The control unit 10 includes a CPU, RAM, ROM, non-volatile memory, and an input / output interface, etc. The CPU performs information processing according to a program loaded from ROM or non-volatile memory into RAM.
[0023] The program may be supplied to the anomaly detection device 1 via a non-temporary storage medium, or it may be supplied to the anomaly detection device 1 via a communication network.
[0024] The control unit 10 includes a processing data acquisition unit 11, a process identification unit 12, a normal model selection unit 13, a position deviation determination unit 14, an anomaly detection unit 15, a simple load determination unit 16, and a normal model update unit 17. These functional units 11 to 17 are realized by the CPU of the control unit 10 executing information processing according to a program.
[0025] Furthermore, the control unit 10 includes a determination information storage unit 18 and a normal model storage unit 19. These storage units 18 and 19 are located in the non-volatile memory of the control unit 10. However, the storage units 18 and 19 may be located in external storage devices.
[0026] Machine tool 2 is a machine that performs cutting, slicing, grinding, polishing, etc., on a workpiece, and is such as a machining center, lathe, milling machine, or grinding machine. Machine tool 2 has a spindle on which a tool or workpiece is mounted and which is driven by a motor.
[0027] The data collection device 3 is a device that collects machining process data from the machine tool 2 and transmits it to the anomaly detection device 1. For example, it is an independent PC that collects data from the machine tool 2 via a network and transmits it to the anomaly detection device 1.
[0028] The machining process data includes spindle load data, machining information, and position coordinate data. Spindle load data represents the load on the spindle during the machining process and includes, for example, motor power consumption, motor voltage, motor current, or motor torque.
[0029] Machining information includes, for example, the main program number, subprogram number, machine tool operating status, cutting signal, M code command signal, tool number, and spindle speed.
[0030] Of these, the main program number, subprogram number, and tool number are examples of process identification data used to identify the machining process. The spindle speed is data representing the rotation speed of the spindle during the machining process.
[0031] Position coordinate data is data that represents the machining position during the machining process, and includes, for example, tool position data based on the machine tool's specific coordinate system, or tool position data based on a coordinate system with an arbitrary point within the machine tool as the origin.
[0032] The machining data acquisition unit 11 acquires machining process data collected from the machine tool 2 by the data acquisition device 3 (machining data acquisition step). Specifically, the machining data acquisition unit 11 acquires spindle load data, process identification data (program number, etc.), spindle rotation speed data, and position coordinate data, etc. The machining data acquisition unit 11 sequentially provides the machining process data at that time, collected from the machine tool 2 by the data acquisition device 3, to the process identification unit 12, etc.
[0033] The process identification unit 12 identifies the machining process currently being machined from the machining process data acquired from the machining data acquisition unit 11 (process identification step). Specifically, the process identification unit 12 identifies the machining process currently being machined based on the main program number, subprogram number, and tool number, which are included in the machining process data as process identification data. However, the machining process data may also contain information that directly identifies the machining process.
[0034] The normal model selection unit 13 selects a normal model corresponding to the machining process identified by the process identification unit 12 (normal model selection step). That is, based on the identified machining process, the normal model selection unit 13 selects a normal model for the same machining process as the one currently being machined from among the normal models stored in the normal model storage unit 19. The normal model storage unit 19 stores a normal model for each machining process.
[0035] The normal model is a model that represents the relationship between time and load under normal conditions. Specifically, the normal model represents the relationship between time and load in past machining processes when no abnormality was detected in the simplified load determination step by the simplified load determination unit 16 described later. The normal model may further include the relationship between time and machining position under normal conditions.
[0036] The normal model is created based on machining process data from one or more identical machining steps that were not identified as abnormal in the simplified load determination step. In other words, the relationship between time and load in the normal model is generated based on a predetermined number of spindle load data that were not identified as abnormal in the simplified load determination step. Furthermore, the relationship between time and machining position in the normal model is generated based on a predetermined number of position coordinate data that were not identified as abnormal in the simplified load determination step.
[0037] The position deviation determination unit 14 compares the position coordinate data included in the machining process data with the normal model to determine the position deviation of the machining position (position deviation determination step). That is, the position deviation determination unit 14 determines the position deviation of the machining position by comparing the machining position represented by the position coordinate data of the machining process in progress with the machining position represented by the selected normal model. Note that the position deviation determination unit 14 may be omitted.
[0038] The anomaly detection unit 15 detects anomalies in the machining process using one or more feature quantities calculated based on the difference between the spindle load data included in the machining process data and the normal model (anomaly detection step). In other words, the anomaly detection unit 15 determines that an anomaly has occurred in the machining process when the feature quantity calculated based on the difference between the load represented by the spindle load data of the machining process in progress and the load represented by the selected normal model is greater than or equal to a threshold.
[0039] If the position deviation determination unit 14 determines that a position deviation has occurred, or if the abnormality detection unit 15 detects an abnormality, a notification of the position deviation or load abnormality is sent to a designated terminal, such as a terminal held by the operator (notification step).
[0040] The simplified load determination unit 16 determines an abnormality based on the load variation in the spindle load data included in the machining process data (simplified load determination step). The simplified load determination unit 16 determines an abnormality using only one set of acquired machining process data. In other words, the simplified load determination unit 16 determines an abnormality based on the machining process data itself, without comparing it with a normal model.
[0041] The simplified load determination unit 16 detects abnormalities by using the absolute value of the difference between the average value and the root mean square of multiple spindle load data with different elapsed times in the same machining process as a simplified load determination index. Specifically, the simplified load determination index is the error between the average value and the root mean square of a predetermined number of recent load points in the spindle load data.
[0042] Furthermore, the simplified load determination unit 16 may correct the simplified load determination index based on the spindle speed included in the machining process data. Specifically, the simplified load determination unit 16 considers the section in which the spindle speed changes as not being in the machining process and corrects the simplified load determination index to a smaller value in that section.
[0043] The judgment information storage unit 18 stores parameters such as thresholds used for judgments made by the position deviation judgment unit 14, the anomaly detection unit 15, and the simplified load judgment unit 16. The judgment information storage unit 18 also stores the judgment results made by the position deviation judgment unit 14, the anomaly detection unit 15, and the simplified load judgment unit 16.
[0044] The normal model update unit 17 generates or updates a normal model based on the spindle load data and position coordinate data included in the machining process data, if no abnormality is detected in the simplified load determination step by the simplified load determination unit 16 (normal model generation step, normal model update step).
[0045] Specifically, when the process identification unit 12 determines that the process has changed to a different processing step, the normal model update unit 17 refers to the determination information storage unit 18, and if the determination result from the simplified load determination unit 16 is normal, it updates the normal model based on the processing process data of that processing step.
[0046] The normal model update unit 17 generates or updates the relationship between time and load in the normal model based on the spindle load data in which no abnormalities were detected. Furthermore, the normal model update unit 17 generates or updates the relationship between time and machining position in the normal model based on the position coordinate data in which no abnormalities were detected.
[0047] For example, the normal model update unit 17 excludes the spindle load data with the largest degree of difference from the spindle load data that was not found to be abnormal in the simplified load determination step by the simplified load determination unit 16 and a predetermined number of spindle load data from the normal model, and generates a normal model based on the remaining predetermined number of spindle load data. The same applies to position coordinate data.
[0048] According to this embodiment, by using a normal model that represents the relationship between time and load when no abnormality was detected by the simplified load judgment during past machining processes, abnormality detection becomes easier even in machining processes with limited experience. Furthermore, since abnormality detection is performed based on the spindle load, it is not necessary to install high-precision sensors in the machining area of the machine tool.
[0049] Conventional machining anomaly detection technologies often use machine learning to create a normal model and then detect anomalies by comparing the actual data to this normal model. However, this method has the problem that it requires a large amount of machining data to create a normal model. In addition, it is extremely difficult to intentionally generate sudden anomalies, and in supervised learning, it may not even be possible to prepare training data in the first place. In the case of unsupervised learning, if training is done on data without anomalies, the system may automatically classify variations within the normal range, leading to over-detection. There are also methods that can determine anomalies using only the target data without using machine learning, but in machining, where there are countless processes depending on the part being processed, it is not possible to completely estimate the normal range in the target process using only data, and measures such as limiting the target process in advance are necessary.
[0050] In contrast, this embodiment combines load validation of the target data alone with comparison with past performance data, thereby shortening the time (number of processing cycles) required for anomaly detection to function and enabling application to a wide range of processes. Since the determination of whether or not to adopt the data as normal processing performance data is also performed automatically based on the validation of the data alone, anomaly detection can be started without prior preparation even when a new process is implemented on a machine tool where anomaly detection is in operation and there is no prior processing history.
[0051] Figures 2 and 3 are flowcharts showing an example of the procedure for the anomaly detection method implemented in the anomaly detection device 1. The control unit 10 of the anomaly detection device 1 executes the information processing shown in these figures according to the program.
[0052] The control unit 10 starts detecting abnormalities at a predetermined interval (for example, a 0.5-second interval) (S11).
[0053] First, the control unit 10 acquires the current time processing process data from the data acquisition device 3 (S12, processing data acquisition step, processing as the processing data acquisition unit 11).
[0054] Next, the control unit 10 identifies the machining process currently being performed (hereinafter also simply referred to as "process") based on the main program number, subprogram number, and tool number included in the machining process data for the current time (S13, process identification step, processing as process identification unit 12).
[0055] Next, the control unit 10 compares the currently processed process with the process from the previous cycle to determine if the process has changed (S14).
[0056] If there is no process in the previous cycle, or if the process currently being processed is different from the process in the previous cycle (i.e., the process in the previous cycle has been completed), the control unit 10 proceeds to S15. On the other hand, if the process currently being processed is the same as the process in the previous cycle, the control unit 10 proceeds to S17.
[0057] Specifically, the machining process data for the current time is compared with the machining process data from the previous cycle. If any of the main program number, subprogram number, or tool number are different, the process is considered to have changed. If they are all the same, the process is considered to be continuing.
[0058] Furthermore, if a tool change (referring to a change to a different type of tool, and distinct from replacement with a new tool) occurs during a period in which the same main program and subprogram are running, resulting in multiple discontinuous periods with the same tool number, each will be considered a separate process, even if the combination of the main program, subprogram, and tool number is the same.
[0059] Furthermore, restrictions may be placed on the main program number, subprogram number, and tool number to be targeted for anomaly detection. If the identified process is one that falls outside the scope of the detection, the anomaly detection for that time period may be terminated, and the process may move on to anomaly detection for the next machining process data.
[0060] In S14, if there is no process from the previous cycle, or if the process currently being processed is different from the process from the previous cycle, the control unit 10 determines whether or not a normal model corresponding to the process currently being processed exists in the normal model storage unit 19 (S15).
[0061] If a normal model corresponding to the process currently being processed exists (S15: YES), the control unit 10 selects that normal model (S16, normal model selection step, processing as normal model selection unit 13). On the other hand, if a normal model corresponding to the process currently being processed does not exist (S15: NO), the control unit 10 proceeds to S24.
[0062] In this embodiment, the normal model is a model that combines a series of processing process data from the start timing to the end timing of up to N (e.g., 5) processes of the same process that was previously performed, where no abnormality was detected by the simplified load judgment. N is not particularly limited as long as it is a positive integer of 2 or more.
[0063] In S14, if the process currently being processed is the same as the process one cycle prior, or after selecting a normal model in S16, the control unit 10 extracts normal model data (load and processing position) from the selected normal model in which the elapsed time from the start of the process is the same as the process currently being processed (S17).
[0064] As shown in Figure 3, the control unit 10 then calculates the amount of misalignment and determines whether the calculated amount of misalignment is below a threshold (S18-S19, misalignment determination step, processing as the misalignment determination unit 14). Details of the calculation of the amount of misalignment (S18) will be described later.
[0065] If the amount of positional misalignment exceeds the threshold (S19: NO), the control unit 10 notifies a designated terminal, such as a terminal held by the operator, of a positional misalignment alarm (S20, notification step), and then proceeds to S24.
[0066] If the amount of misalignment is below the threshold (S19: YES), the control unit 10 determines whether there is a load abnormality and determines whether the load abnormality determination result is normal or not (S21-S22, abnormality detection step, processing as the abnormality detection unit 15). Details of the load abnormality determination (S21) will be described later.
[0067] If the load abnormality determination result is found to be abnormal (S22: NO), the control unit 10 notifies a designated terminal, such as a terminal held by the operator, of the load abnormality alarm (S23, notification step), and then proceeds to S24.
[0068] If the load abnormality detection result is "no abnormality" (S22: YES), the control unit 10 stores the acquired processing process data in memory (S24). The control unit 10 also stores all data from the start of the process (processing process data, calculated values, and detection results, etc.) in memory (S25).
[0069] The control unit 10 repeatedly executes the processes S12 to S25 described above until a predetermined cycle is completed, and then terminates the abnormality detection (S26).
[0070] Furthermore, the control unit 10 performs a simplified load determination based on the processing process data in parallel with the abnormality detection (S31, simplified load determination step, processing as the simplified load determination unit 16), and stores the simplified load determination result in memory (S32). Details of the simplified load determination (S31) will be described later.
[0071] In S14, if the process currently being processed is different from the process one cycle prior (i.e., the process one cycle prior has been completed), the control unit 10 checks the simplified load determination result of the completed process (S33).
[0072] If the simplified load assessment results for all completed processes are OK (S33: All OK), the control unit 10 updates the normal model of the completed processes (S34, normal model update step, processing as the normal model update unit 17). Details of the normal model update (S34) will be described later.
[0073] If the simplified load judgment result for a completed process includes an NG (S33: NG is included), or after the completion of the normal model update (S34), the control unit 10 outputs the data of the completed process as an abnormal judgment log (S35) and deletes the data of the completed process from memory (S36).
[0074] Figure 4 is a flowchart showing a specific example of the procedure for calculating the amount of positional displacement (S18). Figure 5 is a graph showing an example of positional coordinate data when a positional displacement actually occurs.
[0075] In this embodiment, the Euclidean distance in spatial coordinates is calculated as the positional displacement. Specifically, first, the control unit 10 acquires the latest tool coordinate data from the machining process data (S41). Next, the control unit 10 calculates the elapsed time from the start of the target process to the time when the latest tool coordinate data was acquired (S42).
[0076] Next, the control unit 10 extracts tool coordinate data from the normal model at approximately the same elapsed time (for example, n points before and after) (S43). In order to correct for discrepancies in data acquisition timing, the tool coordinate data extracted from the normal model consists of the data corresponding to the same elapsed time and the data from the n points before and after it.
[0077] Next, the control unit 10 calculates the Euclidean distance between the latest tool coordinate data and the extracted tool coordinate data of the normal model (S44). Then, the control unit 10 outputs the positional displacement amount, using the minimum value among the calculated Euclidean distances as the positional displacement amount at that time (S45, S46).
[0078] If the calculated displacement exceeds a threshold, it is determined that the machining position has shifted, and a displacement alarm, distinct from the occurrence of a machining abnormality, is sent to the operator (S19, S20). By including this displacement detection, it is possible to distinguish data deviations caused by operator intervention in machine operation, thereby suppressing false positives.
[0079] Figure 5 shows time-series data of the coordinates of one axis of a machine tool during the same process. The horizontal axis represents the elapsed time from the start of the process. According to this, the coordinates begin to shift around 3000 seconds into the process. By detecting such shifts, it is possible to distinguish differences due to variations in machining position from machining abnormalities.
[0080] Figures 6 to 9 are flowcharts showing specific procedure examples for load abnormality detection (S21). Figure 10 is a graph showing an example of the discrepancy between motor load and normal model. Figures 11 to 14 are graphs showing examples of feature quantities. In this embodiment, four feature quantities are used: load discrepancy degree, cumulative discrepancy degree, randomness frequency, and randomness frequency discrepancy degree.
[0081] As shown in Figure 6, first, the control unit 10 acquires the spindle load data from the start of the target process to the present time, and uses this as the current data (S51).
[0082] Next, the control unit 10 calculates the elapsed time from the start of the target process to the current time (S52). Then, the control unit 10 extracts the spindle load data from the start of the process to the same elapsed time in the normal model and uses this as standard data (S53).
[0083] Next, the control unit 10 calculates the absolute value of the difference between the current data and the standard data for the most recent n points (S54). Next, the control unit 10 calculates the correction value 1 (S55). The correction value 1 is expressed by the following formula 1. The correction value 1 is a value that emphasizes the absolute value of the difference as the load of the normal model decreases.
[0084]
number
[0085] Furthermore, after calculating the data (S51), the control unit 10 calculates a correction value 2 (S56). The correction value 2 is expressed by the following formula 2. The correction value 2 is a value that emphasizes the absolute value of the difference, to the greater the load at the current time exceeds the maximum load from the start of the process to immediately before the current time.
[0086]
number
[0087] Next, the control unit 10 calculates and outputs the load deviation (S57, S58). The load deviation is expressed by the following formula 3. Next, the control unit 10 calculates the maximum value of the load deviation for the most recent 120 points and sets this as the maximum load deviation (S59).
[0088] In other words, the load deviation is calculated by multiplying the absolute difference between the process load and the load of the normal model by correction value 1 and correction value 2. The load deviation can be used to determine whether a sudden change in load is occurring.
[0089]
number
[0090] Furthermore, after calculating the standard data (S53), the control unit 10 calculates the difference between the current data and the standard data, each with the average values of the most recent n points (S61).
[0091] Next, the control unit 10 calculates and outputs the cumulative deviation using the correction value 1 and the cumulative deviation from the previous cycle (S62, S63). The cumulative deviation is expressed by the following formula 4. Next, the control unit 10 calculates the maximum value of the cumulative deviation for the most recent 1200 points and sets this as the maximum cumulative deviation (S64).
[0092] In other words, the cumulative deviation is calculated by calculating the difference between the process load and the load of the normal model, multiplying it by a correction value of 1, and adding the value obtained by multiplying the cumulative deviation calculated one cycle earlier by the integration coefficient of 0.99. Unlike the load deviation, the cumulative deviation does not take the absolute value of the difference, but also takes into account the value up to the previous cycle, thereby being able to represent the trend of increase or decrease in load.
[0093]
number
[0094] As shown in Figure 7, after calculating the standard data (S53), the control unit 10 calculates the absolute value of the difference between the standard data and the data from 0.5 seconds (1 cycle) ago (S65). Next, the control unit 10 defines a discrete probability distribution of the absolute value of the difference, using the 60 most recent data points as the population (S66).
[0095] Furthermore, after calculating the current data (S51), the control unit 10 calculates the absolute value of the difference between the current data and the data from 0.5 seconds (1 cycle) ago (S67). Next, the control unit 10 defines a discrete probability distribution of the absolute value of the difference, using the 60 most recent data points as the population (S68).
[0096] Next, the control unit 10 calculates the Kullback-Leibler distance (KLD) between the discrete probability distributions of the standard data and the current data (S69).
[0097] Next, the control unit 10 calculates and outputs the randomness deviation (S70, S71). The randomness deviation is expressed by the following formula 5. Next, the control unit 10 calculates the maximum value of the randomness deviation for the most recent 1200 points and sets this as the maximum randomness deviation (S72).
[0098] The randomness frequency deviation is a value that compares the range of load fluctuations with that of the normal model. The amount of fluctuation for each data interval in the most recent 60 points is calculated, and the proportion of data intervals with a fluctuation amount of n is taken as the probability distribution C(n) and S(n) for the processed interval and the normal model, respectively. The Kullback-Leibler distance (a measure of the difference between probability distributions) between these two probability distributions is then calculated. The randomness frequency deviation can be used to determine whether the range of load fluctuations is larger than under normal conditions.
[0099]
number
[0100] As shown in Figure 8, after calculating the absolute value of the difference (S67), the control unit 10 calculates and outputs the single randomness frequency of the absolute value of the difference for the 60 most recent data points (S73, S74). The single randomness frequency is expressed by the following formula 6. Next, the control unit 10 calculates the maximum value of the single randomness frequency for the most recent 1200 points and sets this as the maximum single randomness frequency (S75).
[0101] In other words, the single randomness frequency is calculated by determining the amount of variation in each data interval over the most recent 60 points of the process load, and then using the ratio of the number of data intervals that vary above a certain value to the total number of data points. The single randomness frequency can represent the range of variation in the load of the target data.
[0102]
number
[0103] As shown in Figure 9, whether or not an anomaly has occurred is evaluated by combining four feature quantities: load deviation, cumulative deviation, randomness frequency, and randomness frequency deviation. By appropriately combining AND conditions, OR conditions, threshold size, etc., to determine whether or not a threshold has been exceeded, it becomes possible to detect various anomaly states.
[0104] The following is an example of the determination. First, the control unit 10 determines whether the conditions are met: maximum load deviation > 100, maximum cumulative deviation > 20, and maximum randomness deviation > 0 or maximum single randomness >> 0 (S76). If these conditions are met (S76: YES), the control unit 10 notifies "abnormal (alarm level: 2)" (S77).
[0105] If the above conditions are not met (S76: NO), the control unit 10 determines whether the conditions are met: maximum load deviation > 30, maximum cumulative deviation > 80, and maximum randomness deviation > 2 or maximum single randomness > 0.03 (S78). If these conditions are met (S78: YES), the control unit 10 notifies "abnormal (alarm level: 2)" (S79).
[0106] If the above conditions are not met (S78: NO), the control unit 10 determines whether the conditions of maximum load deviation > 40 and maximum randomness deviation > 0 or maximum single randomness > 0 are met (S80). If these conditions are met (S80: YES), the control unit 10 notifies "Confirmation required (Alarm level: 1)" (S81).
[0107] If the above conditions are not met (S80: NO), the control unit 10 notifies "No abnormality (alarm level: 0)" (S82).
[0108] Figure 10 shows an example of motor load and normal model data when a discrepancy occurs. The motor load represents the ratio (%) of the current motor power consumption to the maximum rated output. Figures 11 to 14 show each feature quantity during the processing shown in Figure 10. Figures 11 to 14 show that the timing of the increase in value differs for each feature quantity.
[0109] Figure 15 is a flowchart showing a specific example of the procedure for simplified load determination (S31).
[0110] First, the control unit 10 acquires spindle load data for the most recent n points (S91). n is an integer greater than or equal to 2, for example, 10.
[0111] Next, the control unit 10 calculates the average value of the spindle load data for the most recent n points (S92), and also calculates the root mean square of the spindle load data for the most recent n points (S93).
[0112] Next, the control unit 10 calculates the absolute value of the difference between the average value and the root mean square as a simplified load determination index (S94).
[0113] Furthermore, the control unit 10 acquires the spindle rotation speed at the nearest m point (S95) and calculates a correction value (S96). Details of the correction value calculation (S96) will be described later.
[0114] The control unit 10 calculates the absolute value of the difference (S94) and the correction value (S96), and then multiplies the absolute value of the difference by the correction value, and uses the resulting value as the determination value (S97).
[0115] Next, the control unit 10 determines whether the judgment value is below a threshold (S98).
[0116] If the judgment value is below the threshold (S98: YES), the control unit 10 outputs an "OK" judgment result (S99). On the other hand, if the judgment value exceeds the threshold (S98: NO), the control unit 10 outputs an "NG" judgment result (S100).
[0117] Figure 16 is a flowchart showing a specific example of the procedure for calculating the correction value (S96).
[0118] First, the control unit 10 determines whether the spindle rotation speed values at the nearest m point are all 0 (S101). If the spindle rotation speed values at the nearest m point are all 0 (S101: YES), the control unit 10 outputs a correction value of "0" (S102).
[0119] On the other hand, if the spindle speed values at the most recent m point are not all 0 (S101: NO), the control unit 10 determines whether the spindle speed values at the most recent m point have changed (S103). If the spindle speed values at the most recent m point have not changed (S103: YES), the control unit 10 outputs a correction value of "1" (S104).
[0120] On the other hand, if the spindle speed at the most recent m point is changing (S103:NO), the control unit 10 calculates the maximum absolute value of the difference in spindle speed between each point at the most recent m point and sets this as the maximum change (S105). The control unit 10 also calculates the minimum value of the spindle speed at the most recent m point and sets this as the minimum value (S106).
[0121] Next, the control unit 10 calculates a correction value using the maximum change and the minimum value (S107). The correction value is expressed by the following formula 7.
[0122]
number
[0123] The root mean square represents the degree of dispersion of values, and when calculated using a group of values that are relatively similar, it will yield a value close to the mean. Therefore, in the simplified load assessment (S31), the moment when the absolute value of the difference between the mean and the root mean square becomes large is detected as the moment when the load has changed rapidly compared to the recent trend.
[0124] On the other hand, another time when the load changes rapidly is when the motor's rotational speed changes. Normally, the motor's rotational speed does not change during machining; it only changes when accelerating from a standstill or decelerating to stop. These changes are within the range of normal operation.
[0125] Therefore, using spindle speed data, at the moment the rotational speed changes, the simplified load determination index is multiplied by a correction value calculated from the spindle speed data, thereby correcting the simplified load determination index to a smaller value according to the amount of change in rotational speed.
[0126] The simplified load assessment (S31) allows for the detection of data that is clearly abnormal without needing to compare it with a normal model. By excluding this data, a highly reliable normal model can be created even with limited processing data. Furthermore, because it can identify obvious abnormalities, there is no need to provide correct data as in supervised learning in machine learning.
[0127] Figure 17 shows an example of the relationship between motor load and a simplified load determination index when an abnormality occurs. Similar to Figure 10, the motor load represents the ratio (%) of the current motor power consumption to the maximum rated output.
[0128] The figure shows that the simplified load assessment index increases when an anomaly occurs, but in other areas, even when the load increases, the simplified load assessment index does not change significantly. This allows for the identification of clear anomalies.
[0129] Figures 18 and 19 are flowcharts illustrating specific procedure examples for a normal model update (S34).
[0130] As shown in Figure 18, first, the control unit 10 acquires all the data of the completed process (S111). Next, the control unit 10 determines whether or not a normal model of the completed process exists (S112).
[0131] If a normal model exists for the completed process (S112: YES), the control unit 10 acquires the normal model for the completed process (S113).
[0132] Next, the control unit 10 determines whether the number of actual data points constituting the normal model is n or more (S114). n is an integer of 2 or more, for example, 5.
[0133] If the number of actual data points constituting the normal model is n or more (S114: YES), the control unit 10 performs an update of the normal model as described below.
[0134] Specifically, the control unit 10 calculates the average value of the spindle load for the current data and the past n performance data, totaling n+1 data points, for each elapsed time since the start of the process (S115). Next, the control unit 10 calculates the square of the difference between each of the n+1 data points and their average values for each elapsed time since the start of the process (S116).
[0135] Furthermore, the control unit 10 calculates the average value of the tool coordinates of the current data and the past n records, totaling n+1 records, for each elapsed time since the start of the process (S117). Next, the control unit 10 calculates the square of the difference between each of the n+1 records and their respective average values for each elapsed time since the start of the process (S118).
[0136] In this embodiment, the mean was calculated as an example of a standard value, but the method is not limited to this; for example, the median, maximum value, or minimum value may also be used as a standard value.
[0137] As shown in Figure 19, the control unit 10 then sums up the squared differences for each of the n+1 data points and uses this as the difference score (S119). Next, the control unit 10 selects n data points from the n+1 data points, excluding the one with the largest difference score (S120).
[0138] Next, the control unit 10 calculates the average values of the spindle load and tool coordinates for each of the n selected items over time to generate a normal model (S121). Then, the control unit 10 outputs the generated normal model (average values over time) and the selected actual data (S124).
[0139] If a normal model does not exist for a completed process (S112:NO), or if the number of actual data points constituting the normal model is less than n (S114:NO), the control unit 10 saves the data of the completed process as new actual data in the normal model and outputs it (S123, S124).
[0140] Since the repeatability of machining processes is expected to be very high when performed with the same NC program, and the number of abnormal processes is expected to be very small compared to normal processes, this update method can be used to avoid abnormal data remaining in the normal model.
[0141] Furthermore, when the number of updates is low, abnormal data may be temporarily included, and there is a possibility that normally processed data may be mistaken for an anomaly. Therefore, the decision of whether to update the normal model will be made independently of the anomaly detection results, and only data that is clearly judged to be abnormal in the simplified load assessment will be excluded from updating.
[0142] Although embodiments of the present invention have been described above, the present invention is not limited to the embodiments described above, and various modifications are of course possible for those skilled in the art. [Explanation of Symbols]
[0143] 1 Anomaly detection device, 2 Machine tool, 3 Data acquisition device, 10 Control unit, 11 Machining data acquisition unit, 12 Process identification unit, 13 Normal model selection unit, 14 Position deviation determination unit, 15 Anomaly detection unit, 16 Simple load determination unit, 17 Normal model update unit, 18 Judgment information storage unit, 19 Normal model storage unit
Claims
1. Acquisition step of acquiring spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor, A selection step to select a normal model that represents the relationship between time and load under normal conditions, corresponding to the processing step identified by the process identification data, An anomaly detection step that detects an anomaly in the machining process using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, Equipped with, The aforementioned normal model represents the relationship between time and load in cases where no abnormality was detected by the simplified load detection method, which determines abnormalities based on load variations, during past processing steps. Anomaly detection method.
2. The system further includes a simplified load determination step for determining abnormalities based on the load variation in the aforementioned spindle load data. The anomaly detection method according to claim 1.
3. The simplified load determination step uses the error between the average value and the root mean square of a predetermined number of recent points in the spindle load data as a simplified load determination index to determine an abnormality. The anomaly detection method according to claim 2.
4. The acquisition step further acquires spindle speed data representing the rotational speed of the spindle, The simplified load determination step involves correcting the simplified load determination index to a smaller value in the section where the rotational speed of the main spindle changes. The anomaly detection method according to claim 3.
5. If no abnormality is detected in the simplified load determination step, the system further includes an update step to update the normal model based on the spindle load data. The anomaly detection method according to claim 2.
6. The normal model is generated based on a predetermined number of spindle load data, The update step involves removing the spindle load data with the largest degree of difference from the spindle load data for which an abnormality was not determined in the simplified load determination step and a predetermined number of spindle load data for the normal model, and generating the normal model based on the remaining predetermined number of spindle load data. The anomaly detection method according to claim 5.
7. The acquisition step further acquires position coordinate data representing the machining position during the machining process, The aforementioned normal model further includes the relationship between time and processing position under normal conditions, The system further includes a position deviation determination step, which involves comparing the position coordinate data with the normal model to determine the position deviation of the processing position. The anomaly detection method according to claim 1.
8. The system further includes a notification step in which a notification is sent to a predetermined terminal when an anomaly is detected by the anomaly detection step or when a positional misalignment is determined by the positional misalignment determination step. The anomaly detection method according to claim 7.
9. The system further includes a step of identifying the processing step based on the process identification data. The anomaly detection method according to claim 1.
10. An acquisition step for acquiring spindle load data representing the load on the spindle during a machining process of a machine tool equipped with a spindle that is driven by a motor and on which a tool or workpiece is mounted, A simplified load determination step that determines an abnormality based on the load variation in the aforementioned spindle load data, If no abnormality is detected in the simplified load determination step, a generation step is performed to generate a normal model representing the relationship between time and load under normal conditions, based on the spindle load data. A method for generating a normal model, comprising the following features.
11. An acquisition unit that acquires spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle on which a tool or workpiece is mounted and which is driven by a motor, A selection unit that selects a normal model representing the relationship between time and load under normal conditions, corresponding to the processing step identified by the process identification data, An abnormality detection unit that detects abnormalities in the machining process using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, Equipped with, The aforementioned normal model represents the relationship between time and load in cases where no abnormality was detected by the simplified load detection method, which determines abnormalities based on load variations, during past processing steps. Anomaly detection device.
12. To acquire spindle load data representing the load on the spindle during a machining process and process identification data for identifying the machining process of a machine tool equipped with a spindle that is driven by a motor and on which a tool or workpiece is mounted, Select a normal model that represents the relationship between time and load under normal conditions, corresponding to the processing step identified by the process identification data, and Using one or more feature quantities calculated based on the difference between the spindle load data and the normal model, abnormalities in the machining process are detected. Have the computer run it, The aforementioned normal model represents the relationship between time and load in cases where no abnormality was detected by the simplified load detection method, which determines abnormalities based on load variations, during past processing steps. program.