Program creation assistance program, program creation assistance device, program creation assistance method, and program creation assistance system
The program creation support system addresses inefficiencies in programming by generating a model set and enabling easy switching of parameter combinations and processing methods, enhancing efficiency in program creation and modification.
Patent Information
- Application Number
- PCT/JP2024/024277
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-07-04
- Publication Date
- 2026-01-08
AI Technical Summary
Existing programming methods require defining multiple functions and methods with different argument counts for varying input and output features, leading to complex and inefficient program creation and modification processes, especially in machine learning applications where internal processing parameters differ.
A program creation support system that generates a model set combining multiple models with different parameters into a single file and allows easy switching of parameter combinations and processing methods within a target program, using a model set generation unit and program component generation unit to facilitate efficient program creation and modification.
This approach simplifies the process of switching model parameters and processing methods, reducing labor hours and improving efficiency in program creation and modification, particularly in debugging and control program development.
Smart Images

Figure JP2024024277_08012026_PF_FP_ABST
Abstract
Description
Program creation support program, program creation support device, program creation support method, and program creation support system
[0001] The present disclosure relates to a program creation support program, a program creation support device, a program creation support method, and a program creation support system.
[0002] Generally, in programming languages such as C and Python, processes that are written repeatedly or that can be separated into a single function are modularized and defined as functions, or classes are created and their methods are defined, thereby improving readability, reusability, and maintainability.
[0003] Recent technological innovations have led to the emergence of processes in which the parameters used in internal processing differ depending on the input and output content, even when using the same calculation method. For example, when generating a learning model using machine learning, the parameters used in internal processing may differ because the input and output features differ, but the learning method algorithm may be the same. In this case, using conventional methods, it is necessary to define multiple functions and methods with different numbers of arguments, even if the internal processing flow is the same, resulting in programs that are difficult to read.
[0004] Patent Literature 1 discloses a method that uses machine learning to determine the possibility of an abnormality occurring in a monitored object. The learning model employed in this method has multiple algorithms for determining abnormalities, and the algorithm to be used can be specified from the input value of a function block used in the program, and the algorithm can be switched according to predetermined conditions.
[0005] Japanese Patent Application Laid-Open No. 2020-101904
[0006] The technology described in Patent Document 1 uses a single learning model that has been trained only on data (supervised data) from when no abnormalities occur in the monitored object to determine when an abnormality has occurred. In this case, the feature values used for the determination are fixed, and the parameters input to the learning model cannot be easily switched to other ones. If a change is desired, the learning model must be re-created. This increases the man-hours required for creating and modifying the program, resulting in poor efficiency.
[0007] The present disclosure has been made to solve the above-mentioned problems, and aims to reduce the number of steps and improve efficiency in creating and modifying programs.
[0008] To achieve the above object, a program according to the present disclosure causes a computer to function as a model set generation unit and a program component generation unit. The model set generation unit generates a model that processes input parameters and outputs values, and generates a model set that combines multiple models that perform similar processing but with different parameters into a single file. The program component generation unit generates program components that add models to a target program, associates the model set, and generates program components that enable switching between combinations of parameters and processing methods for the added models.
[0009] According to the present disclosure, when creating and modifying a program, it becomes easy to switch the combination of model parameters and processing methods to be added to the target program, thereby reducing labor hours and improving efficiency.
[0010] FIG. 1 shows an example of the configuration of a program creation support system according to an embodiment. FIG. 2 shows an example of learning data for supervised learning aimed at anomaly detection according to an embodiment. FIG. 3 shows an example of learning data for supervised learning aimed at calculating tension values of a conveyor according to an embodiment. FIG. 4 shows an example of a learning model creation screen for supervised learning according to an embodiment. FIG. 5 shows an example of a learning model creation screen on which a learning method and feature values for supervised learning according to an embodiment are set. FIG. 6 shows an example of a learning model for supervised learning according to an embodiment. FIG. 7 shows an example of a learning model for supervised learning according to an embodiment. FIG. 8 shows an example of a learning model creation screen in which a learning method and feature values for supervised learning according to an embodiment are set and there are default settings for input. FIG. 9 shows an example of a learning model for supervised learning in which there are default settings for input according to an embodiment. FIG. 1 shows an example of a learning model. FIG. 1 shows an example of a learning model creation screen when a learning method and feature values for unsupervised learning according to an embodiment are set and there are default settings for the input. FIG. 1 shows an example of a learning model for unsupervised learning when there are default settings for the input according to an embodiment. FIG. 1 shows an example of an evaluation pattern creation screen for a learning model for unsupervised learning according to an embodiment. FIG. 1 shows a model evaluation result screen in which the performance of a learning model for unsupervised learning according to an embodiment is evaluated. FIG. 1 shows an example of an evaluation pattern creation screen for a learning model for supervised learning according to an embodiment. FIG. 1 shows a model evaluation result screen in which the performance of a learning model for supervised learning according to an embodiment is evaluated. FIG. 1 shows an example of a control program creation screen according to an embodiment. FIG. 1 shows an example of a control program creation screen during simulation according to an embodiment. FIG. 1 shows an example of a learning model selection screen according to an embodiment. Flowchart showing program part generation processing according to an embodiment. Flowchart showing control program generation processing according to an embodiment. FIG. 1 shows an example of a hardware configuration of a program creation support device according to an embodiment.
[0011] Hereinafter, a program, a program creation support device, a program creation support method, and a program creation support system according to the present embodiment will be described in detail with reference to the drawings. Note that identical or corresponding parts in the drawings are denoted by the same reference numerals. In this embodiment, an example will be described in which the parameters are feature quantities and the model is a learning model.
[0012] The configuration of a program creation support system 100 according to an embodiment will be described with reference to FIG. 1. The program creation support system 100 includes a program creation support device 1 that generates program components usable in a control program executed by a control device 2, a control device 2 that controls an external device 4 and collects feature data related to the external device 4, and a collected data storage unit 3 that stores the feature data collected by the control device 2. While one external device 4 is shown in the figure, multiple external devices 4 may be used. The external device 4 includes, for example, a camera, a sensor, etc., and the control device 2 collects feature data related to the external device 4 from the camera, sensor, etc. Hereinafter, the feature data collected by the control device 2 will be referred to as collected data. The control program is an example of a target program.
[0013] The program creation support device 1 is, for example, a personal computer on which an engineering tool is installed. The program creation support device 1 includes a learning model set generation unit 11 that generates a learning model based on collected data and generates a learning model set that combines multiple learning models using similar learning methods but with different features into a single file; a learning model set storage unit 12 that stores the generated learning model set; an evaluation pattern generation unit 13 that generates an evaluation pattern for evaluating the performance of the learning models included in the learning model set; a program evaluation unit 14 that evaluates the performance of the learning models based on the evaluation pattern; and a component model set storage unit 15 that stores a component model set that combines selected learning models from the evaluated learning models into a single file. The program creation support device 1 also includes a program component generation unit 16 that generates program components that add learning models to a control program, associate the component model set with the component model set, and switch the combination of features and learning methods; and a control program generation unit 17 that generates a control program using the program components. The learning method is an example of a processing method. The learning model set generation unit 11 is an example of a model set generation unit.
[0014] The control device 2 is, for example, a programmable logic controller (PLC). The control device 2 includes data collection units 211 to 21n (n≧1) that collect feature quantity data related to the external device 4, and program execution units 221 to 22m (m≧1) that execute a control program generated by the programming support device 1. The data collection units 211 to 21n of the control device 2 collect sensor data, manufacturing data, timestamps, etc. from the external device 4 and store them as collected data in the collected data storage unit 3. The program execution units 221 to 22m download and execute the control program generated by the programming support device 1 to control the external device 4.
[0015] The learning model set generation unit 11 of the program creation support device 1 generates a learning model based on the collected data stored in the collected data storage unit 3. Since the collected data cannot be used for learning as is, the learning model set generation unit 11 performs preprocessing to convert the collected data into data for learning by converting the data format and deleting unnecessary information.
[0016] First, a case where a learning model for supervised learning is generated will be described. Specific examples of learning data for supervised learning are shown in FIGS. 2A and 2B. FIG. 2A is an example of learning data for supervised learning intended for anomaly detection. FIG. 2B is an example of learning data for supervised learning intended for calculation of conveyor tension values. Learning data for supervised learning is data consisting of a set of input and output, and is in a text format such as a CSV (Comma Separated Values) file. In FIG. 2A, "state" is the output, and other feature values are the input. In FIG. 2B, "tension" is the output, and other feature values are the input.
[0017] 1, the learning model set generation unit 11 displays a learning model creation screen that accepts learning model settings by the user. The learning model set generation unit 11 generates a learning model based on the settings input to the learning model creation screen.
[0018] Here, the learning model creation screen for supervised learning will be described with reference to Fig. 3. In the example shown in Fig. 3, the learning model creation screen has a "Learning Method" item for setting the learning method of the learning model the user wants to create, and a "Features" item for setting the input and output. The learning model creation screen also has a "File to Generate" item for setting the name of the file to be generated, an "Import" button for loading the learning data, a "Start Generation" button for starting generation of the learning model, and a "Cancel" button for canceling generation of the learning model.
[0019] As shown in Figure 3, various supervised learning methods can be set in the "Learning Method" item. The "Learning Method" item has a button that pops up a learning method detail selection screen where detailed setting items for each learning method (learning time, number of learning times, and prefix of the learning model to be generated) can be specified. Note that the detailed setting items are not limited to these and may include other conditions for the learning method.
[0020] In the case of supervised learning, the "feature" item has input and output items. The input and output items have a "default" check box. If the "default" check box is enabled, that item will be included as a feature by default when generating a learning model, and a learning model that does not use the feature of that item will not be generated. Learning models will be generated for all possible combinations of the features and learning methods set for the input and output. Depending on the data format, there may be cases where the learning process cannot be performed using the method specified in "learning method" and a learning model will not be generated; however, for convenience, this embodiment will be described assuming that a learning model can be generated using the specified learning method and feature.
[0021] Next, a method for generating a learning model for supervised learning will be described using FIGS. 4 and 5. FIG. 4 shows an example of a learning model creation screen in which the learning method and feature values for supervised learning are set. In the "Learning Method" section of the learning model creation screen, multiple regression, K-nearest neighbor method, random forest, and deep learning are set for Learning Method 1 to Learning Method 4, respectively. In the "Feature Value" section, feed rate, acceleration, total operating time, and total operating distance are set for Input 1 to Input 4, respectively, and tension is set for Output 1. Note that supervised learning requires at least one input and one output, so tension for Output 1 is automatically set to the default.
[0022] When the "Import" button is pressed, the learning model set generation unit 11 searches the header of the CSV file and reads the learning data for the feed rate, acceleration, total operating time, and total operating distance corresponding to inputs 1 to 4, and the learning data for tension corresponding to output 1. When the "Start generation" button is pressed, the learning model set generation unit 11 starts learning using a learning method corresponding to learning method 1 to learning method 4, based on the read learning data.
[0023] When settings are made on the learning model creation screen as shown in Figure 4, a learning model like that shown in Figure 5 is generated. Learning models are generated for multiple regression, K-nearest neighbor algorithm, random forest, and deep learning, with all possible combinations of feed speed, acceleration, total driving time, and total driving distance as input and tension as output. In the figure, used features are indicated with an "O" and unused features with an "X." The tension of output 1 is set to the default, so all output tensions are marked with an "O."
[0024] Theoretically, all combinations of the generated learning model are as follows. In the case of supervised learning, one or more inputs and outputs are required, so when the number of inputs is M (M≧1) and the number of outputs is L (L≧1), the cases where there is no input or no output are excluded. Therefore, the total number of combinations for the input is 2 M -1 way, the total combination of outputs is 2 L -1 combinations. And the total combinations of input and output are (2 M -1) x (2 L If N learning methods are used, the number of models that are ultimately generated is N × (2 M -1) x (2 L -1).
[0025] The learning model set generation unit 11 generates a learning model set by collecting the generated learning models for supervised learning into one file, and stores the file in the learning model set storage unit 12. The learning model set with the file name AI_Sample1 shown in Fig. 5 is a collection of learning models for supervised learning aimed at calculating the tension value of a conveyor.
[0026] The generation of a learning model for supervised learning when default settings are set for inputs will be described using Figures 6 and 7. On the learning model creation screen shown in Figure 6, similar to the example in Figure 4, multiple regression, K-nearest neighbor method, random forest, and deep learning are set for Learning Method 1 to Learning Method 4, respectively, in the "Learning Method" section, and feed rate, acceleration, total operating time, and total operating distance are set for Input 1 to Input 4, respectively, in the "Features" section. Furthermore, tension is set as the default for Output 1. In the example in Figure 6, the feed rate for Input 1 and the acceleration for Input 2 are also set as defaults.
[0027] When settings are made on the learning model creation screen as shown in Figure 6, a learning model like that shown in Figure 7 is generated. Learning models are generated for multiple regression, K-nearest neighbor algorithm, random forest, and deep learning, with the input being all possible combinations of feed speed and acceleration, and the total driving time and total driving distance, and the output being tension. Since the tension of output 1 is set to the default, all output tensions are marked "○". Furthermore, since the feed speed of input 1 and the acceleration of input 2 are set to the default, all feed speeds and accelerations are marked "○", as shown by the bold lines in the figure.
[0028] Theoretically, all combinations of the generated learning model are as follows. The number of default settings for input is D (1≦D≦M), and the number of default settings for output is E (1≦E≦L). In the case of supervised learning, one or more inputs and outputs are required, so when the number of inputs is M (M≧1) and the number of outputs is L (L≧1), the number of inputs is 2. M-D As a result, the output is 2 L-E Therefore, there are 2 combinations of input and output. M-D ×2 L-E If N learning methods are used, the total number of models generated is N x 2. M-D ×2 L-E This becomes:
[0029] Next, a case where a learning model for unsupervised learning is generated will be described. FIG. 8 shows a specific example of learning data for unsupervised learning. FIG. 8 is an example of learning data for unsupervised learning aimed at anomaly detection. The learning data for unsupervised learning is input-only data, and is in a text format such as a CSV file. The learning data in FIG. 8 is data in which various feature quantities under normal conditions (correct answers) are input.
[0030] Here, the learning model creation screen for unsupervised learning will be explained using FIG. 9. As shown in FIG. 9, the learning method for unsupervised learning can be set in the "Learning Method" item. In the case of unsupervised learning, only input is required, so the output item in the "Features" item is not used. Learning models are generated for all possible combinations of the features set in the input and the learning method. The rest of the configuration is the same as the learning model creation screen shown in FIG. 3.
[0031] Next, a method for generating a learning model for unsupervised learning will be described with reference to FIGS. 10 and 11. FIG. 10 shows an example of a learning model creation screen on which a learning method and feature values for unsupervised learning are set. The Mahalanobis-Taguchi method (MT method), autoencoder, and similar waveform recognition are set as learning methods 1 to 3 in the "Learning Method" field on the learning model creation screen, respectively. Furthermore, vibration sensor: speed, vibration sensor: acceleration, current, and temperature are set as inputs 1 to 4 in the "Feature Value" field, respectively. Vibration sensor: speed and vibration sensor: acceleration are the speed and acceleration detected by the vibration sensor, respectively.
[0032] When the "Import" button is pressed, the learning model set generation unit 11 searches the header of the CSV file and reads the learning data of the vibration sensor: speed, vibration sensor: acceleration, current, and temperature corresponding to input 1 to input 4. When the "Start generation" button is pressed, the learning model set generation unit 11 starts learning with a learning method corresponding to learning method 1 to learning method 3 based on the read learning data.
[0033] When the settings are made on the learning model creation screen as shown in Fig. 10, a learning model as shown in Fig. 11 is generated. Learning models are generated for the MT method, autoencoder, and similar waveform recognition, each with inputs consisting of all possible combinations of vibration sensor: speed, vibration sensor: acceleration, current, and temperature.
[0034] Theoretically, all combinations of the generated learning model are as follows: In the case of unsupervised learning, one or more inputs are required, so when the number of inputs is M (M≧1), the total number of combinations of inputs is 2, excluding the case where there is no input. M -1. If N learning methods are used, the number of models ultimately generated is N × (2 M -1).
[0035] The learning model set generation unit 11 generates a learning model set by collecting the generated learning models for unsupervised learning into one file, and stores the file in the learning model set storage unit 12. The learning model set with the file name AI_Sample2 shown in Fig. 11 is a collection of learning models for unsupervised learning aimed at anomaly detection.
[0036] The generation of a learning model for unsupervised learning when default settings are set for inputs will be described using Figures 12 and 13. On the learning model creation screen shown in Figure 12, as in the example of Figure 10, the MT method, autoencoder, and similar waveform recognition are set for Learning Method 1 to Learning Method 3, respectively, in the "Learning Method" section, and vibration sensor: speed, vibration sensor: acceleration, current, and temperature are set for Input 1 to Input 4, respectively, in the "Feature Quantity" section. Also, in the example of Figure 12, the vibration sensor: speed for Input 1 and the vibration sensor: acceleration for Input 2 are set as defaults.
[0037] When settings are made on the learning model creation screen as shown in Fig. 12, a learning model like that shown in Fig. 13 is generated. Learning models are generated for the MT method, autoencoder, and similar waveform recognition, with the inputs being all combinations of vibration sensor: speed and vibration sensor: acceleration, and current and temperature. Since input 1 vibration sensor: speed and input 2 vibration sensor: acceleration are set to the default, vibration sensor: speed and vibration sensor: acceleration are all marked with a circle, as shown by the bold line in the figure.
[0038] Theoretically, all combinations of the generated learning model are as follows: The number of default settings for input is D (1≦D≦M). In the case of unsupervised learning, there is no output and one or more inputs are required, so when the number of inputs is M (M≧1), the input is 2. M-D Therefore, if N learning methods are used, the total number of models generated is N x 2 M-D This becomes:
[0039] Returning to Fig. 1, the evaluation pattern generation unit 13 performs a test to evaluate the performance of a learning model included in the learning model set stored in the learning model set storage unit 12, and generates an evaluation pattern for evaluating the test results. The program evaluation unit 14 evaluates the performance of the learning model using the evaluation pattern generated by the evaluation pattern generation unit 13. The evaluation pattern generation unit 13 displays a model evaluation pattern creation screen that accepts a user's setting of an evaluation pattern for the learning model. The evaluation pattern generation unit 13 generates a model evaluation pattern for evaluating the performance of the target learning model based on the settings input to the evaluation pattern creation screen.
[0040] Here, an evaluation pattern creation screen for a learning model for unsupervised learning will be described with reference to FIG. 14 . In the example shown in FIG. 14 , the evaluation pattern creation screen has an “Evaluation Target Model Set” field where the user sets a learning model set including the learning model to be evaluated, a “Test Data” field where the user sets test data to be input to the learning model, and an “Evaluation Target Selection” field where the user sets the learning method for the learning model to be evaluated. AI_Sample2, a learning model set for unsupervised learning aimed at anomaly detection, is set in the “Evaluation Target Model Set” field. The “Evaluation Target Selection” field has a button that pops up a judgment criterion evaluation index selection screen on which the user can specify test judgment criteria and evaluation indexes for the test results for each learning method. The judgment criterion evaluation index selection screen shown in FIG. 14 allows the user to set a threshold for determining an anomaly, the accuracy rate, F-measure, LogLoss, AUC, RMSE, R2, MAE, MAPE, precision, and recall. 14, an evaluation pattern is set to evaluate the accuracy rate, F-score, LogLoss, and AUC of the MT method. When the "Start evaluation" button is pressed, evaluation of the performance of the learning model begins.
[0041] The program evaluation unit 14 evaluates the performance of the learning model using the evaluation pattern set on the evaluation pattern creation screen. As shown in FIG. 14 , the evaluation pattern creation screen is set, and when the "Start Evaluation" button is pressed, the program evaluation unit 14 inputs test data Test1.csv into the MT method learning models MT_model_01, MT_model_02, MT_model_03, and MT_model_04, and performs an anomaly detection test. The example in FIG. 14 shows a graph of the anomaly detection test results for MT_model_01, MT_model_02, MT_model_03, and MT_model_04. Anomalies were detected in MT_model_01, MT_model_02, and MT_model_04, but no anomaly was detected in MT_model_03. The program evaluation unit 14 calculates and evaluates the accuracy rate, F-measure, LogLoss, and AUC of the test results of the learning model that detected the anomaly.
[0042] Upon completing the evaluation of the performance of the learning model, the program evaluation unit 14 displays a model evaluation result screen as shown in FIG. 15 . In the example shown in FIG. 15 , the model evaluation result screen displays the accuracy rate, F-measure, LogLoss, and AUC values for MT_model_01, MT_model_02, and MT_model_04. MT_model_03, which did not detect any abnormalities, is excluded from the evaluation. The model evaluation result screen has check boxes that allow the user to select a learning model to be adopted in a component model set, which is a collection of learning models used for program components. In the example shown in FIG. 15 , MT_model_04 is selected. The model evaluation result screen includes a "Decide" button that confirms the selection of the learning model. When the "Decide" button is pressed, the program evaluation unit 14 confirms the selection of the learning model and closes the model evaluation result screen.
[0043] Next, the evaluation pattern creation screen for a learning model of supervised learning will be described with reference to FIG. 16 . In the example of the evaluation pattern creation screen shown in FIG. 16 , AI_Sample1, a learning model set of supervised learning for the purpose of calculating conveyor tension values, is set in the "Model Set to be Evaluated" field. The judgment criterion evaluation index selection screen shown in FIG. 16 allows the user to set the error tolerance between the test data and the output value of the learning model, the accuracy rate, F-value, LogLoss, AUC, RMSE, R2, MAE, MAPE, precision, and recall. In the example of FIG. 16 , evaluation patterns for evaluating the RMSE, R2, MAE, and MAPE of multiple regression and random forest are set. Pressing the "Start Evaluation" button starts evaluation of the performance of the learning model.
[0044] The program evaluation unit 14 evaluates the performance of the learning model using the evaluation pattern set on the evaluation pattern creation screen. As shown in FIG. 16 , the evaluation pattern creation screen is configured. When the "Start Evaluation" button is pressed, the program evaluation unit 14 inputs test data Test2.csv into the multiple regression learning models Multi_model_01, Multi_model_02, and Multi_model_03 and the random forest learning model RF_model_01, and performs a conveyor tension value calculation test. The example in FIG. 16 shows a graph of the test results of conveyor tension value calculation for Multi_model_01, Multi_model_02, and Multi_model_03. Although a graph is not shown, a conveyor tension value calculation test is also performed on RF_model_01. The program evaluation unit 14 calculates and evaluates the RMSE, R2, MAE, and MAPE of the test results of each learning model.
[0045] When the program evaluation unit 14 completes the evaluation of the performance of the learning models, it displays a model evaluation result screen as shown in FIG. 17. In the example shown in FIG. 17, the model evaluation result screen displays the RMSE, R2, MAE, and MAPE values of Multi_model_01, Multi_model_02, Multi_model_03, and RF_model_01. Here, all learning models are evaluated, but learning models whose errors between the test data and the output values of the learning models are equal to or greater than a set threshold are excluded from the evaluation. In the example shown in FIG. 17, Multi_model_01, Multi_model_02, and RF_model_01 are selected as learning models to be adopted in the component model set.
[0046] 15 and 17, the user selects a learning model to be adopted in the component model set on the model evaluation result screen, but this is not limiting. The program evaluation unit 14 may adopt a learning model with a high evaluation value as the component model set in accordance with a predetermined condition. The predetermined condition is, for example, a condition that a learning model with an evaluation value equal to or greater than a threshold value is adopted as the component model set.
[0047] Returning to FIG. 1 , the program evaluation unit 14 generates a component model set that combines the learning models selected on the model evaluation result screen into a single file and stores it in the component model set storage unit 15. The program component generation unit 16 generates program components that add learning models to a control program, associate the component model sets stored in the component model set storage unit 15, and enable switching between combinations of feature quantities and learning methods for the learning models to be added. The control program generation unit 17 displays a control program creation screen that accepts the creation of control programs that can use program components. The control program generation unit 17 generates a control program based on the content entered on the control program creation screen.
[0048] The control program creation screen will be described with reference to FIGS. 18 and 19 . In the example of the control program creation screen shown in FIG. 18 , program components of the component model set are displayed in the left area (indicated by a dashed line in the figure). Here, the file name of the learning model set from which the component model set was extracted is used as the program component name. A user can add a program component to a control program by dragging and dropping the program component name onto the right area where the control program is written. When the program component name is dragged and dropped, the program component is added to the control program, and a program component setting screen is displayed that allows switching the combination of feature values and learning models. The operation of adding a program component to a control program is not limited to dragging and dropping the program component name. For example, the program component setting screen may be displayed by clicking the program component name while the location in the control program where the program component is to be added is active.
[0049] 19, when the user switches the combination of feature quantities and learning models on the program component setting screen, the control program generation unit 17 performs a simulation and displays a program component monitor screen in the area below that displays the values of each feature quantity during the simulation. Initially setting a program component learning method and feature quantities when they have not yet been set is also included in the term "switching."
[0050] The user can switch between the learning method and feature values of the program component on the program component setting screen. At this time, the user may select the learning method and feature values, or may select the learning model. In the example of the program component setting screen shown in Figure 19, AI_Sample1 is a component model set extracted from a learning model set generated with Speed, Acceleration, and Tension set to default, so these feature values are not selectable.
[0051] The feature values and learning methods of program parts can also be switched on the program part monitor screen, and the settings are linked to the program part setting screen. The user switches between the learning methods and feature values of program parts, checks the program part monitor screen, and decides which learning method and feature value to use.
[0052] 19, the control program creation screen includes a "Model Selection" button for selecting a learning model for the program component, and a "Complete" button for completing the creation of the control program. When the "Model Selection" button is pressed, the control program generation unit 17 displays a learning model selection screen for accepting the selection of a learning model for the program component.
[0053] The learning model selection screen will be described with reference to FIG. 20 . In the example of the learning model selection screen shown in FIG. 20 , the user has selected Multi_model_02, K_model_02, and K_model_04 as learning models for the program components of AI_Sample1, Random_model_01 and Random_model_05 as learning models for the program components of AI_Sample2, and GB_model1, AE_model1, and WFR_model as learning models for the program components of AI_Sample3. The learning model selection screen includes a “Cancel” button for canceling the selection of a learning model and a “Decide” button for confirming the selection of the learning model for the program component. When the “Decide” button is pressed, the control program generation unit 17 confirms the selection of the learning model for each program component and closes the learning model selection screen. The selected learning model and the corresponding program parts are collected into one file. A single file can contain multiple collections of selected learning models and corresponding program parts.
[0054] Returning to FIG. 19, when the "Complete" button is pressed on the control program creation screen, the control program generation unit 17 generates a control program based on the content entered on the control program creation screen.
[0055] Returning to FIG. 1 , the control program generation unit 17 downloads the generated control program to the control device 2. At this time, the control program generation unit 17 downloads a file that summarizes the program parts corresponding to the selected learning model along with the control program to the control device 2. The program execution units 221 to 22m of the control device 2 execute the control program using the file that summarizes the program parts corresponding to the selected learning model. Note that after the control device 2 downloads the control program, the user may be configured to be able to change the learning model of the program parts in the control program on the learning model selection screen displayed by the control program generation unit 17. In this case, the control program generation unit 17 downloads a file that summarizes the program parts corresponding to the learning model changed on the learning model selection screen to the control device 2. The control device 2 switches the learning model of the corresponding program part in the control program using the downloaded file that summarizes the program parts corresponding to the changed learning model.
[0056] Here, the program component generation process executed by the program creation support device 1 will be described with reference to FIG. 21. The program component generation process shown in FIG. 21 starts, for example, when a program component generation instruction is input to the program creation support device 1. The learning model set generation unit 11 of the program creation support device 1 displays a learning model creation screen that accepts the user's settings for the learning model (step S11). If no operation to start the generation of the learning model is performed (step S12; NO), the process repeats step S12 and waits for an operation to start the generation of the learning model. If an operation to start the generation of the learning model is performed (step S12; YES), the learning model set generation unit 11 generates a learning model based on the settings input to the learning model creation screen (step S13). The examples of the learning model creation screen for supervised learning shown in FIG. 3 and the learning model creation screen for unsupervised learning shown in FIG. 9 have a "Learning Method" item for setting the learning method for the learning model the user wants to create, a "Features" item for setting the input and output, a "File to Generate" item for setting the name of the file to be generated, an "Import" button for loading learning data, a "Start Generation" button for starting generation of the learning model, and a "Cancel" button for canceling generation of the learning model.
[0057] 21 , the learning model set generation unit 11 generates a learning model set by combining the generated learning models into a single file (step S14) and stores the file in the learning model set storage unit 12. For example, the learning model set with the file name AI_Sample1 shown in FIG. 5 is a collection of learning models for supervised learning aimed at calculating the tension value of a conveyor. The learning model set with the file name AI_Sample2 shown in FIG. 11 is a collection of learning models for unsupervised learning aimed at anomaly detection.
[0058] Returning to FIG. 21 , the evaluation pattern generation unit 13 displays a model evaluation pattern creation screen that accepts the user's setting of an evaluation pattern for a learning model (step S15). If no operation to start evaluation is performed (step S16; NO), the process repeats step S16 and waits for an operation to start evaluation. If an operation to start evaluation is performed (step S16; YES), the evaluation pattern generation unit 13 generates a model evaluation pattern for evaluating the performance of a target learning model based on the settings entered on the evaluation pattern creation screen (step S17). The examples of the evaluation pattern creation screen for a learning model for unsupervised learning shown in FIG. 14 and the evaluation pattern creation screen for a learning model for supervised learning shown in FIG. 16 include an "Evaluation Target Model Set" field for setting a learning model set including the target learning model that the user wants to evaluate, a "Test Data" field for setting test data to be input into the learning model, and an "Evaluation Target Selection" field for setting a learning method for the target learning model that the user wants to evaluate. The "Evaluation Target Selection" field also includes a button that pops up a criterion / evaluation index selection screen that allows the user to specify test criterion and evaluation index for the test result for each learning method.
[0059] Returning to FIG. 21 , the program evaluation unit 14 evaluates the performance of the learning model using the evaluation pattern generated by the evaluation pattern generation unit 13 (step S18). Upon completing the evaluation of the performance of the learning model, the program evaluation unit 14 displays a model evaluation result screen (step S19). In the example of the model evaluation result screen for the learning model of unsupervised learning shown in FIG. 15 , MT_model_04 is selected as the learning model to be adopted in the component model set. In the example of the model evaluation result screen for the learning model of supervised learning shown in FIG. 17 , Multi_model_01, Multi_model_02, and RF_model_01 are selected as the learning models to be adopted in the component model set. In the examples shown in FIGS. 15 and 17 , the model evaluation result screen includes a “Decide” button for confirming the selection of the learning model. When the “Decide” button is pressed, the program evaluation unit 14 confirms the selection of the learning model and closes the model evaluation result screen.
[0060] 21 , if no operation to confirm the selection of a learning model is performed (step S20; NO), the process repeats step S20 and waits for an operation to confirm the selection of a learning model. If an operation to confirm the selection of a learning model is performed (step S20; YES), the program evaluation unit 14 generates a component model set that combines the learning models selected on the model evaluation result screen into a single file (step S21) and stores the file in the component model set storage unit 15. The program component generation unit 16 associates the component model sets stored in the component model set storage unit 15 to generate program components that can switch combinations of feature amounts and learning methods (step S22), and then terminates the process.
[0061] Next, the control program generation process executed by the programming support device 1 will be described with reference to FIG. 22 . The control program generation process shown in FIG. 22 starts, for example, when a control program generation instruction is input to the programming support device 1. The control program generation unit 17 of the programming support device 1 displays a control program creation screen that accepts the creation of a control program that can use program components (step S31). In the example of the control program creation screen shown in FIG. 18 , program components of a component model set are displayed in the left area. In the example of FIG. 18 , program components can be added to the control program by dragging and dropping the program component name onto the right area where the control program is written.
[0062] Returning to FIG. 22 , if no operation to add a program component is performed (step S32; NO), the process repeats step S32 and waits for an operation to add a program component. If an operation to add a program component is performed (step S32; YES), the control program generation unit 17 adds a program component to the control program and displays a program component setting screen on which the combination of feature quantities and learning models can be switched (step S33). If no operation to switch the combination of feature quantities and learning models is performed on the program component setting screen (step S34; NO), the process repeats step S34 and waits for an operation to switch the combination of feature quantities and learning models. If an operation to switch the combination of feature quantities and learning models is performed (step S34; YES), the control program generation unit 17 performs a simulation and displays a program component monitor screen that displays the values of each feature quantity during the simulation (step S35). In the example of the control program creation screen in FIG. 19 , the feature quantities and learning methods of the program components can also be switched on the program component monitor screen, and the settings on the program component setting screen are linked.
[0063] Returning to FIG. 22 , if no operation to display the learning model selection screen is performed (step S36; NO), the control program generation unit 17 repeats step S36 and waits for an operation to display the learning model selection screen. If an operation to display the learning model selection screen is performed (step S36; YES), the control program generation unit 17 displays a learning model selection screen that accepts the selection of a learning model for the program component (step S37). If no operation to confirm the selection of a learning model for the program component is performed (step S38; NO), the control program generation unit 17 repeats step S38 and waits for an operation to confirm the selection of a learning model for the program component. If an operation to confirm the selection of a learning model for the program component is performed (step S38; YES), the control program generation unit 17 determines the learning model for the program component (step S39) and closes the learning model selection screen. The program components corresponding to the selected learning model are combined into one file. In the example shown in FIG. 20 , the learning model selection screen includes a “Cancel” button that cancels the selection of a learning model and a “Confirm” button that confirms the selection of a learning model for the program component. When the "OK" button is pressed, the control program generation unit 17 determines the learning model for the program part and closes the learning model selection screen.
[0064] 22, if the creation of the control program is not complete (step S40; NO), the process returns to step S32, and steps S32 to S40 are repeated. If the creation of the control program is complete (step S40; YES), the control program generation unit 17 generates a control program based on the content entered on the control program creation screen (step S41). The control program generation unit 17 downloads the generated control program to the control device 2 (step S42), and ends the process. In step S42, the control program generation unit 17 downloads to the control device 2 a file that includes the control program and the program parts corresponding to the selected learning model.
[0065] According to the program creation support device 1 of the embodiment, when creating and modifying a control program, it is easy to switch the combination of the feature values of the learning model and the learning method to be added to the control program, thereby reducing the number of steps and improving efficiency. In particular, when debugging a control program, it is even more effective because it is easy to switch the combination of the feature values of the learning model and the learning method in the control program.
[0066] The hardware configuration of the program creation support device 1 will be described with reference to Fig. 23. As shown in Fig. 23, the program creation support device 1 includes a temporary storage unit 101, a storage unit 102, a calculation unit 103, an input unit 104, a transmission / reception unit 105, and a display unit 106. The temporary storage unit 101, the storage unit 102, the input unit 104, the transmission / reception unit 105, and the display unit 106 are all connected to the calculation unit 103 via a BUS.
[0067] The calculation unit 103 is, for example, a CPU (Central Processing Unit). The calculation unit 103 executes the processes of the learning model set generation unit 11, the evaluation pattern generation unit 13, the program evaluation unit 14, the program component generation unit 16, and the control program generation unit 17 of the program creation support device 1 in accordance with the control program stored in the storage unit 102.
[0068] The temporary storage unit 101 is, for example, a random-access memory (RAM). The temporary storage unit 101 loads the control program stored in the storage unit 102 and is used as a work area for the calculation unit 103.
[0069] The storage unit 102 is a non-volatile memory such as a flash memory, a hard disk, a DVD-RAM (Digital Versatile Disc - Random Access Memory), or a DVD-RW (Digital Versatile Disc - Rewritable). The storage unit 102 pre-stores a program for causing the calculation unit 103 to perform processing of the programming support device 1, and also supplies data stored by this program to the calculation unit 103 in accordance with instructions from the calculation unit 103, and stores data supplied from the calculation unit 103. The learning model set storage unit 12 and the component model set storage unit 15 of the programming support device 1 are configured in the storage unit 102.
[0070] The input unit 104 is an interface device that connects input devices such as a keyboard, a pointing device, and a voice input device to the BUS. Information input by a user is supplied to the calculation unit 103 via the input unit 104. The input unit 104 functions as the learning model set generation unit 11, the evaluation pattern generation unit 13, the program evaluation unit 14, and the control program generation unit 17.
[0071] The transmitting / receiving unit 105 is a network termination device or a wireless communication device connected to the network, and a serial interface or a LAN (Local Area Network) interface connected thereto. When the control program generation unit 17 of the programming support device 1 is configured to transmit a control program to the control device 2, the transmitting / receiving unit 105 functions as the control program generation unit 17. When the learning model set generation unit 11 of the programming support device 1 is configured to receive collected data from the collected data storage unit 3, the transmitting / receiving unit 105 functions as the learning model set generation unit 11.
[0072] The display unit 106 is a display device such as an LCD (Liquid Crystal Display), an organic EL (Electroluminescence) display, etc. The display unit 106 functions as the learning model set generation unit 11, the evaluation pattern generation unit 13, the program evaluation unit 14, and the control program generation unit 17.
[0073] The processing of the learning model set generation unit 11, learning model set memory unit 12, evaluation pattern generation unit 13, program evaluation unit 14, component model set memory unit 15, program component generation unit 16, and control program generation unit 17 of the program creation support device 1 shown in Figure 1 is executed by the control program processing using the temporary memory unit 101, calculation unit 103, memory unit 102, input unit 104, transmission / reception unit 105, display unit 106, etc. as resources.
[0074] Furthermore, the above hardware configuration and flowchart are merely examples and can be changed and modified as desired.
[0075] The core processing components of the program creation support device 1, such as the calculation unit 103, temporary storage unit 101, storage unit 102, input unit 104, transmission / reception unit 105, and display unit 106, can be realized using an ordinary computer system rather than a dedicated system. For example, the program creation support device 1 that executes the above-described processes may be configured by storing and distributing a computer-readable recording medium such as a flexible disk, CD-ROM (Compact Disc - Read Only Memory), or DVD-ROM (Digital Versatile Disc - Read Only Memory), and installing the computer program on a computer. Alternatively, the program creation support device 1 may be configured by storing the computer program in a storage device of a server device on a communication network, such as the Internet, and downloading it to an ordinary computer system.
[0076] In addition, when the functions of the program creation support device 1 are realized by sharing the functions between an OS (Operating System) and an application program, or by collaboration between an OS and an application program, only the application program portion may be stored on a recording medium or storage device.
[0077] It is also possible to superimpose a computer program on a carrier wave and provide it via a communication network. For example, the computer program may be posted on a bulletin board system (BBS) on the communication network and provided via the communication network. The computer program may then be started and executed under the control of an OS in the same way as other application programs, thereby enabling the above-mentioned processing to be performed.
[0078] In the above embodiment, the program creation support device 1 includes the learning model set generation unit 11, the learning model set storage unit 12, the evaluation pattern generation unit 13, the program evaluation unit 14, the component model set storage unit 15, the program component generation unit 16, and the control program generation unit 17. However, the configuration is not limited to this, and the evaluation pattern generation unit 13, the program evaluation unit 14, and the component model set storage unit 15 may be omitted. In this case, the program component generation unit 16 associates the learning model sets stored in the learning model set storage unit 12 and generates program components that can switch combinations of feature amounts and learning methods. The user can exclude learning models with low performance by checking the program component monitor screen.
[0079] In the above embodiment, the program creation support device 1 includes the control program generating unit 17, but the present invention is not limited to this, and the control program generating unit 17 may be included in an external device or system.
[0080] In the above embodiment, the program creation support device 1 includes the learning model set storage unit 12 and the component model set storage unit 15. However, this is not limiting, and the learning model set storage unit 12 and the component model set storage unit 15 may be provided in an external device or system. Furthermore, the program creation support device 1 or the control device 2 may include the collected data storage unit 3.
[0081] In the above embodiment, the learning model set generation unit 11 of the program creation support device 1 performs preprocessing to convert the collected data into learning data by converting the data format and deleting unnecessary information, but this is not limited to this, and this preprocessing may be performed by the data collection units 211 to 21n of the control device 2, and the learning data may be stored in the collected data storage unit 3.
[0082] In the above embodiment, supervised learning and unsupervised learning have been described as examples of similar learning methods with different feature amounts, but the present invention is not limited to this. For example, similar learning methods with different feature amounts may include reinforcement learning.
[0083] In the above embodiment, the program creation support device 1 displays a learning model creation screen, a model evaluation pattern creation screen, a control program creation screen, and a learning model selection screen and accepts direct input from a user, but this is not limited to this. For example, the program creation support device 1 may transmit the learning model creation screen, the model evaluation pattern creation screen, the control program creation screen, and the learning model selection screen to a user terminal used by the user for display. In this case, the user inputs information on each screen displayed on the user terminal, and the user terminal transmits the input information to the program creation support device 1.
[0084] Although the preferred embodiments have been described in detail above, the present invention is not limited to the above-described embodiments, and various modifications and substitutions can be made to the above-described embodiments without departing from the scope of the claims.
[0085] It should be noted that the present disclosure allows various embodiments and modifications without departing from the broad spirit and scope of the present disclosure. Furthermore, the above-described embodiments are intended to explain the disclosure and do not limit the scope of the present disclosure. That is, the scope of the present disclosure is defined by the claims, not the embodiments. Various modifications made within the scope of the claims and within the meaning of the disclosure equivalent thereto are considered to be within the scope of the present disclosure.
[0086] 1 Program creation support device, 2 Control device, 3 Collected data storage unit, 4 External device, 11 Learning model set generation unit, 12 Learning model set storage unit, 13 Evaluation pattern generation unit, 14 Program evaluation unit, 15 Component model set storage unit, 16 Program component generation unit, 17 Control program generation unit, 100 Program creation support system, 101 Temporary storage unit, 102 Storage unit, 103 Calculation unit, 104 Input unit, 105 Transmission / reception unit, 106 Display unit, 211 to 21n Data collection unit, 221 to 22m Program execution unit.
Claims
1. A program creation support program that causes a computer to function as: a model set generation unit that generates a model that processes input parameters and outputs a value, and generates a model set that combines multiple models that perform similar processing but with different parameters into a single file; and a program component generation unit that generates program components that add the models to a target program, associating the model set and enabling the combination of parameters and processing methods of the models to be added to be switched.
2. The program creation support program according to claim 1, wherein the model set generation unit receives settings related to the generation of the model, including settings for parameters and similar processing methods, generates the model for all possible combinations of parameters and processing methods based on the input settings related to the generation of the model, and generates the model set in a single file.
3. A program creation assistance program as claimed in claim 1 or 2, wherein the computer is further caused to function as an evaluation pattern generation unit that generates an evaluation pattern for evaluating the performance of the model included in the model set, and a program evaluation unit that evaluates the performance of the model based on the evaluation pattern, and the program component generation unit generates the program components by associating a component model set that groups together, into a single file, models included in the model set whose evaluation by the program evaluation unit satisfies predetermined conditions.
4. The program creation support program described in claim 3, wherein the evaluation pattern generation unit accepts specification of the model to be evaluated, test criteria for evaluating the performance of the model, and evaluation indicators for the test results, and generates the evaluation pattern based on the specified contents.
5. A program creation support program as described in any one of claims 1 to 4, further causing the computer connected to a control device that executes a control program that controls an external device to function as a control program generation unit that generates the control program, wherein the program component generation unit generates the program components that add the model to the control program, and the control program generation unit generates the control program using the program components.
6. The program creation support program according to claim 5, wherein the control program generation unit receives a selection of the model of the program component, and generates the control program using the program component to which the selected model is added.
7. A program creation support program as described in claim 5 or 6, wherein when the control program generation unit switches the combination of parameters and processing methods of the model to be added in the program component, it performs a simulation using the switched parameters and processing method and displays the values of each parameter during the simulation.
8. A program creation support program as described in any one of claims 1 to 7, wherein the model set generation unit generates a learning model that learns from input features and outputs values, and generates a learning model set that combines multiple learning models that perform similar learning but have different features into a single file, and the program component generation unit associates the learning model set and generates the program component that can switch the combination of the features and learning method of the learning model to be added.
9. A program creation support device comprising: a model set generation unit that generates a model that processes input parameters and outputs a value, and generates a model set that combines multiple models that perform similar processing but with different parameters into a single file; and a program component generation unit that generates program components that add the models to a target program, associating the model set with the program components and that enable switching between combinations of parameters and processing methods for the models to be added.
10. A program creation support method comprising: a step executed by a program creation support device of generating a model that processes input parameters and outputs a value, and generating a model set that combines multiple models that perform similar processing but with different parameters into a single file; and a step of generating a program component that adds the model to a target program, associating the model set and enabling switching of combinations of parameters and processing methods for the model to be added.
11. A programming support system comprising a control device that executes a control program for controlling an external device, and a programming support device that generates the control program, wherein the control device includes: a program execution unit that executes the control program; and a data collection unit that collects data related to the external device, wherein the programming support device includes: a model set generation unit that generates a model that processes input parameters and outputs a value based on the data related to the external device collected by the data collection unit, and generates a model set that combines a plurality of models that perform similar processing with different parameters into a single file; a program component generation unit that generates program components that add the models to the control program, associating the model set and enabling switching of combinations of parameters and processing methods for the models to be added; and a control program generation unit that generates the control program using the program components.
Citation Information
Patent Citations
Software reuse assisting device
JP2001188673A
Apparatus and method for generating program, program, and program medium
JP2009176076A
Development support device of information control software
JP2012230583A