Software calibration method and device, electronic equipment and storage medium

By listening and real-time update of variable values ​​of parameter configuration files, the problem of low efficiency of software calibration based on configuration files is solved, and efficient calibration without restarting the software is achieved.

CN119536784APending Publication Date: 2025-02-28CHONGQING CHANGAN AUTOMOBILE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311114639.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-08-30
Publication Date
2025-02-28

AI Technical Summary

Technical Problem

Software calibration based on configuration files is inefficient and requires restarting the software to load the modified configuration files.

Method used

By listening to the modification events of the parameter configuration file, the parameter information in the target memory area is read and updated in real time, and the latest variable value is returned to the target software so that calibration is performed without restarting the software.

Benefits of technology

It realizes that the latest parameter variable values ​​are obtained without restarting the target software, thereby improving the efficiency of software calibration, and solving the problem of inefficiency in traditional methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The invention relates to a software calibration method and device, electronic equipment and a storage medium. The method comprises the following steps: monitoring a parameter configuration file, and obtaining a monitoring event trigger signal; under the condition that the monitoring event trigger signal indicates that the parameter configuration file is modified, reading a current variable value corresponding to each current variable name in the parameter configuration file; and according to the current variable value corresponding to each current variable name, updating the historical parameter information in the target memory area to obtain the current parameter information in the target memory area, determining a target latest variable value corresponding to the target variable name, and returning the target latest variable value corresponding to the target variable name to the target software. And calibrating the target software according to the target latest variable value corresponding to the target variable name. The technical problem of low efficiency of software calibration based on configuration files in related technologies is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of software technology, and in particular to a software calibration method and device, electronic equipment and storage medium. Background Art

[0002] When developing autonomous driving software algorithms, it is necessary to modify some parameters and observe the program running effect after the parameters are modified until the program performance reaches the expected level. This process is called algorithm calibration or parameter adjustment.

[0003] In the related art, the traditional configuration file-based implementation method is to load the configuration file and read the relevant parameters when the program starts, as program initialization or runtime parameters. The disadvantage of this method is that the program must be restarted every time the configuration file is modified, which leads to the technical problem of low efficiency of configuration file-based software calibration.

[0004] It can be seen that there is a technical problem in the related art that software calibration based on configuration files is inefficient. Summary of the invention

[0005] One of the purposes of the present invention is to provide a software calibration method to solve the technical problem of low efficiency of software calibration based on configuration files in the prior art; the second purpose is to provide a software calibration device; the third purpose is to provide an electronic device; and the fourth purpose is to provide a storage medium.

[0006] In order to achieve the above object, the technical solution adopted by the present invention is as follows:

[0007] A software calibration method, comprising:

[0008] Monitoring a parameter configuration file to obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software;

[0009] When the monitoring event trigger signal indicates that the parameter configuration file has been modified, reading and obtaining a current variable value corresponding to each current variable name in the parameter configuration file;

[0010] According to the current variable value corresponding to each current variable name, the historical parameter information in the target memory area is updated to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name;

[0011] The target latest variable value corresponding to the target variable name is determined from the current parameter information, and the target latest variable value corresponding to the target variable name is returned to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

[0012] The method of this embodiment obtains the current variable value corresponding to each current variable name when the parameter configuration file has been modified, obtains the current parameter information in the target memory area, and returns the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name; thereby, the target software can obtain the latest target latest variable value corresponding to the target variable name required for calibration without restarting the target software, which solves the technical problem of low efficiency of configuration file-based software calibration caused by the need to restart the software after modifying the configuration file in the related art so that it can load the variable value in the modified configuration file.

[0013] Optionally, as in the aforementioned software calibration method, before monitoring the parameter configuration file and obtaining the monitoring event trigger signal, the method further includes:

[0014] The parameter configuration file is configured according to a preset parameter configuration format, wherein the parameter configuration format is used to indicate the correspondence between variable names and variable values ​​in the parameter configuration file.

[0015] The method of this embodiment provides an implementation method capable of configuring a parameter configuration file that satisfies the parameter configuration format.

[0016] Optionally, as in the aforementioned software calibration method, before monitoring the parameter configuration file to obtain the monitoring event trigger signal, the method further includes:

[0017] Requesting in the configurator to call a monitoring instance creation interface of the Linux system, requesting to create a monitoring instance, and obtaining a file descriptor fed back by the Linux system, wherein the monitoring instance is used to monitor the parameter configuration file;

[0018] If the file descriptor indicates that the monitoring instance is successfully created, execute the next step;

[0019] When the file descriptor indicates that the creation of the monitoring instance fails, the next step is stopped, and a request is made to call the monitoring instance creation interface of the Linux system in the configurator again to request the creation of the monitoring instance again.

[0020] The method of this embodiment provides an implementation mode that can create a monitoring instance for monitoring a parameter configuration file, and can recreate it when the creation fails, thereby ensuring the implementation of monitoring the parameter configuration file.

[0021] Optionally, as in the aforementioned software calibration method, monitoring the parameter configuration file to obtain the monitoring event trigger signal includes:

[0022] By calling the file adding interface of the Linux system, the parameter configuration file is determined as the file to be monitored;

[0023] The monitoring event triggering information of the parameter configuration file is obtained by calling the information saving interface of the Linux system.

[0024] The method of this embodiment provides an implementation manner for obtaining monitoring event triggering information of a parameter configuration file.

[0025] Optionally, as in the aforementioned software calibration method, determining the target latest variable value corresponding to the target variable name from the current parameter information, and returning the target latest variable value corresponding to the target variable name to the target software includes:

[0026] Determine the target current variable value corresponding to the target variable name from the current parameter information;

[0027] By executing a variable value conversion operation, the target current variable value is converted into the target latest variable value of the target parameter type;

[0028] The target latest variable value corresponding to the target variable name is returned to the target software.

[0029] The method of this embodiment converts the target latest variable value into a specified variable value of a target parameter type, and then returns the specified variable value corresponding to the target variable name to the target software, so that the specified variable value obtained by the target software is a parameter type supported by the target software.

[0030] Optionally, as in the aforementioned software calibration method, after determining the target latest variable value corresponding to the target variable name from the current parameter information, the method further includes:

[0031] If the variable value conversion operation is not successfully executed, an error code is returned.

[0032] The method of this embodiment returns an error code when the variable value conversion operation is not successfully executed, so that the user can obtain the failure situation of the variable value conversion operation in time and make improvements in time.

[0033] Optionally, as in the aforementioned software calibration method, after updating the historical parameter information in the target memory area according to the current variable value corresponding to each current variable name to obtain the current parameter information in the target memory area, the method further includes:

[0034] From the current parameter information, query whether there is a target variable name;

[0035] In the case where the target variable name exists in the current parameter information, executing a jump operation for jumping to the target latest variable value corresponding to the target variable name determined from the current parameter information;

[0036] If the target variable name does not exist in the current parameter information, an error code is returned.

[0037] The method of this embodiment executes the jump operation for jumping to the target latest variable value corresponding to the target variable name determined from the current parameter information only when the target variable name exists in the target memory area, thereby ensuring that the target software can be calibrated by the target latest variable value corresponding to the target variable name, and returns an error code when the target variable name does not exist in the target memory area, so that the user can promptly discover that the target variable name does not exist, and then promptly adjust the parameter configuration file or the target variable name, so that the calibration of the target software can be effectively implemented.

[0038] According to another aspect of the embodiment of the present application, a software calibration device is also provided, including:

[0039] A monitoring module, used to monitor a parameter configuration file and obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software;

[0040] A reading module, configured to read and obtain a current variable value corresponding to each current variable name in the parameter configuration file when the monitoring event trigger signal indicates that the parameter configuration file has been modified;

[0041] An updating module, configured to update the historical parameter information in the target memory area according to the current variable value corresponding to each current variable name, so as to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name;

[0042] The return module is used to determine the target latest variable value corresponding to the target variable name from the current parameter information, and return the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

[0043] According to another aspect of the embodiments of the present application, there is also provided an electronic device, including a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; wherein the memory is used to store a computer program; and the processor is used to execute the method steps in any of the above embodiments by running the computer program stored in the memory.

[0044] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the method steps in any of the above embodiments when executed.

[0045] Beneficial effects of the present invention:

[0046] By obtaining the current variable value corresponding to each current variable name when the parameter configuration file has been modified, the current parameter information in the target memory area is obtained, and the target latest variable value corresponding to the target variable name is returned to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name; thereby, the target software can obtain the latest target latest variable value corresponding to the target variable name required for calibration without restarting the target software, which solves the technical problem of low efficiency of configuration file-based software calibration caused by the need to restart the software after modifying the configuration file in the related technology so that it can load the variable value in the modified configuration file. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] Figure 1 is a flowchart of an optional software calibration method according to an embodiment of the present application;

[0048] Figure 2 is a flowchart of an optional software calibration method according to an application example of the present application;

[0049] Figure 3 is a structural block diagram of an optional software calibration device according to an embodiment of the present application;

[0050] Figure 4 It is a structural block diagram of an optional electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0051] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0052] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0053] According to one aspect of an embodiment of the present application, a software calibration method is provided. Optionally, in this embodiment, the above-mentioned software calibration method can be applied to a hardware environment consisting of a terminal and a server. The server is connected to the terminal via a network, and can be used to provide services (such as advertising push services, application services, etc.) to the terminal or a client installed on the terminal. A database can be set on the server or independently of the server to provide data storage services for the server.

[0054] The above network may include but is not limited to at least one of the following: wired network, wireless network. The above wired network may include but is not limited to at least one of the following: wide area network, metropolitan area network, local area network, and the above wireless network may include but is not limited to at least one of the following: WIFI (Wireless Fidelity), Bluetooth. The terminal may not be limited to a PC, a mobile phone, a tablet computer, etc.

[0055] The software calibration method of the embodiment of the present application can be executed by a server, a terminal, or a server and a terminal together. The terminal can also execute the software calibration method of the embodiment of the present application by a client installed thereon.

[0056] Taking the software calibration method in this embodiment executed by the server as an example, Figure 1 A software calibration method provided in an embodiment of the present application includes the following steps:

[0057] Step S101, monitoring a parameter configuration file to obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software.

[0058] The software calibration method in this embodiment can be applied to the scenario of online calibration of software, for example, when developing an autonomous driving software algorithm, some parameters are modified to calibrate the autonomous driving software algorithm. In the embodiment of this application, the software calibration method is described above by taking the calibration of the autonomous driving algorithm software as an example. For other types of software, the software calibration method is also applicable if there is no contradiction.

[0059] Specifically, the parameter configuration file may be monitored through a specified interface to obtain a monitoring event trigger signal.

[0060] The monitoring event trigger signal may be a signal for indicating whether the parameter configuration file has been modified and closed, that is, for indicating whether the parameter configuration file has been modified and is not currently in a modification state.

[0061] Step S102, when the monitoring event trigger signal indicates that the parameter configuration file has been modified, read and obtain the current variable value corresponding to each current variable name in the parameter configuration file.

[0062] Specifically, when the monitoring event trigger signal indicates that the parameter configuration file has been modified, it means that the target software needs to be calibrated with new parameters. Therefore, the parameter configuration file can be read and the current variable value corresponding to each current variable name can be obtained.

[0063] Furthermore, a parameter configuration file may contain multiple parameters. Therefore, when the parameter configuration file is modified, it may be that a parameter is added, a parameter is reduced, the variable value of one or more parameters among all parameters (i.e., the variable value corresponding to one or more variable names) is adjusted, etc. Therefore, the current variable name is the variable name of the parameter existing in the current parameter configuration file, and the current variable value uniquely corresponds to a current variable name.

[0064] Step S103, according to the current variable value corresponding to each current variable name, the historical parameter information in the target memory area is updated to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name.

[0065] Specifically, after obtaining the current variable value corresponding to the current variable name, in order to enable the target software to obtain the latest current variable value corresponding to each current variable name; in this embodiment, the historical parameter information in the target memory area is updated according to the current variable value corresponding to each current variable name.

[0066] Optionally, after reading the current variable value corresponding to each current variable name, the historical parameter information can be directly overwritten through the one-to-one correspondence between all current variable names and current variable values, thereby obtaining the current parameter information in the target memory area.

[0067] The target memory area may be a memory area from which the target software can directly obtain parameter names and parameter values.

[0068] Step S104, determining the target latest variable value corresponding to the target variable name from the current parameter information, and returning the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

[0069] Specifically, after the historical parameter information is updated to obtain the current parameter information according to the current variable value corresponding to each current variable name in the target memory area, the target latest variable value corresponding to the target variable name can be determined in the current parameter information.

[0070] When the target variable name exists among all the current variable names in the current parameter information, the specified current variable name that is consistent with the target variable name can be determined from all the current variable names by matching, and then the target latest variable value is obtained according to the current variable value corresponding to the specified current variable name.

[0071] Then, the target latest variable value corresponding to the target variable name can be determined, and then the target latest variable value corresponding to the target variable name can be returned to the target software, so that the target software can be calibrated according to the target latest variable value corresponding to the target variable name.

[0072] The method of this embodiment obtains the current variable value corresponding to each current variable name when the parameter configuration file has been modified, obtains the current parameter information in the target memory area, and returns the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name; thereby, the target software can obtain the latest target latest variable value corresponding to the target variable name required for calibration without restarting the target software, which solves the technical problem of low efficiency of configuration file-based software calibration caused by the need to restart the software after modifying the configuration file in the related art so that it can load the variable value in the modified configuration file.

[0073] As an optional embodiment, in the aforementioned software calibration method, before monitoring the parameter configuration file in step S101 to obtain the monitoring event trigger signal, the method further includes the following steps:

[0074] A parameter configuration file is configured according to a preset parameter configuration format, wherein the parameter configuration format is used to indicate the correspondence between variable names and variable values ​​in the parameter configuration file.

[0075] Specifically, the parameter configuration file can be configured according to the parameter configuration format of "variable name: variable value". For example, when there are multiple parameters, the data format between the parameters in the parameter configuration file can be: "1. variable name I: variable value a", "2. variable name II: variable value b", "3. variable name III: variable value c", etc.

[0076] The method of this embodiment provides an implementation method capable of configuring a parameter configuration file that satisfies the parameter configuration format.

[0077] As an optional embodiment, in the aforementioned software calibration method, before monitoring the parameter configuration file in step S101 to obtain the monitoring event trigger signal, the method further includes the following steps:

[0078] Step 201: requesting to call the monitoring instance creation interface of the Linux system in the configurator, requesting to create a monitoring instance, and obtaining the file descriptor fed back by the Linux system, wherein the monitoring instance is used to monitor the parameter configuration file;

[0079] Step 202, when the file descriptor indicates that the monitoring instance is successfully created, execute the next step;

[0080] Step 203, when the file descriptor indicates that the creation of the listening instance fails, stop executing the next step, and request to call the listening instance creation interface of the Linux system again in the configurator to request to create the listening instance again.

[0081] Specifically, the Linux system interface inotify_init can be called in the configurator config to request the creation of a monitoring instance, and obtain the file descriptor fd fed back by the Linux system. If fd == -1, the initialization operation fails, that is, the creation of the monitoring instance fails, and the program terminates. If fd! = -1, it means that the initialization is successful, that is, the creation of the monitoring instance is successful, and the next step is executed, that is, the step of monitoring the parameter configuration file and obtaining the monitoring event trigger signal.

[0082] The method of this embodiment provides an implementation mode that can create a monitoring instance for monitoring a parameter configuration file, and can recreate it when the creation fails, thereby ensuring the implementation of monitoring the parameter configuration file.

[0083] As an optional embodiment, as in the aforementioned software calibration method, the step S101 monitors the parameter configuration file to obtain the monitoring event trigger signal, including the following steps:

[0084] Step 301, by calling the file adding interface of the Linux system, the parameter configuration file is determined as the file to be monitored.

[0085] Specifically, the configurator config calls the inotify_add_watch interface (ie, file adding interface) of the Linux system to determine the parameter configuration file as the file to be monitored.

[0086] In addition, the parameter IN_CLOSE_WRITE (ie, monitoring event trigger information) may be set to indicate a trigger signal when the parameter configuration file is written, modified and closed.

[0087] Step 302: Acquire monitoring event triggering information of the parameter configuration file by calling the information saving interface of the Linux system.

[0088] Specifically, a file monitoring thread is created and started in the configurator config, and the monitoring event triggering information (ie, IN_CLOSE_WRITE) of the parameter configuration file is obtained in the thread through the inotify_event interface (ie, the information saving interface).

[0089] The method of this embodiment provides an implementation manner for obtaining monitoring event triggering information of a parameter configuration file.

[0090] As an optional embodiment, as in the aforementioned software calibration method, the step S103 determines the target latest variable value corresponding to the target variable name from the current parameter information, and returns the target latest variable value corresponding to the target variable name to the target software, including the following steps:

[0091] Step 401, determining the target current variable value corresponding to the target variable name from the current parameter information;

[0092] Step 402, converting the target current variable value into the target latest variable value of the target parameter type by performing a variable value conversion operation;

[0093] Step 403, returning the target latest variable value corresponding to the target variable name to the target software.

[0094] Step 404: if the variable value conversion operation is not successfully executed, an error code is returned.

[0095] Specifically, after the user obtains the current parameter information through the interface provided by config, the user needs to specify the target variable name and target parameter type to be obtained. If the target variable name specified by the user is found in config, the variable value conversion operation is performed on the target current variable value corresponding to the target variable name, and the target current variable value is converted to the target latest variable value of the target parameter type specified by the user, and the target latest variable value corresponding to the target variable name is returned to the target software. In this process, if the variable value conversion operation fails to be successfully executed, that is, the conversion fails, an error code is returned.

[0096] The method of this embodiment converts the target latest variable value into a specified variable value of the target parameter type, and then returns the specified variable value corresponding to the target variable name to the target software, so that the specified variable value obtained by the target software is a parameter type supported by the target software.

[0097] As an optional embodiment, as in the aforementioned software calibration method, in step S102, the historical parameter information in the target memory area is updated according to the current variable value corresponding to each current variable name, and after obtaining the current parameter information in the target memory area, the method further includes the following steps:

[0098] Step 501, query whether there is a target variable name from the current parameter information;

[0099] Step 502, when there is a target variable name in the current parameter information, executing a jump operation for jumping to a target latest variable value corresponding to the target variable name determined from the current parameter information;

[0100] Step 503: If the target variable name does not exist in the current parameter information, an error code is returned.

[0101] Specifically, after the user obtains the current parameter information through the interface provided by config, the user needs to specify the target variable name to be obtained. Therefore, it is necessary to query whether the target variable name exists in the current parameter information. If the target variable name specified by the user is found in the current parameter information, a jump operation is executed to jump to the target latest variable value corresponding to the target variable name determined from the current parameter information; conversely, if the target variable name does not exist in the current parameter information, an error code is returned to prompt the user to reconfigure the parameter configuration file, for example, to add the parameters corresponding to the target variable name, or to prompt the user that the target variable name selected is incorrect and another variable name needs to be selected.

[0102] The method of this embodiment executes the jump operation for jumping to the target latest variable value corresponding to the target variable name determined from the current parameter information only when the target variable name exists in the target memory area, thereby ensuring that the target software can be calibrated through the target latest variable value corresponding to the target variable name, and returns an error code when the target variable name does not exist in the target memory area, so that the user can promptly discover that the target variable name does not exist, and then promptly adjust the parameter configuration file or the target variable name, so that the calibration of the target software can be effectively implemented.

[0103] like Figure 2 As shown, an application example of applying any of the above embodiments is provided:

[0104] 1. Predefine the parameter configuration format in the configuration file, and implement the configuration of the parameter configuration file according to the parameter configuration format.

[0105] 2. Read the parameter configuration file, read all variable names and text type values ​​in the parameter configuration file (ie, the current variable value corresponding to each current variable name) according to the parameter configuration format, and save them in the configurator config (ie, the target memory area).

[0106] 3. The user obtains the current parameter information through the interface provided by config. The user needs to specify the target variable name and target parameter type to be obtained. If the target variable name specified by the user is not found in config, an error code is returned; if the corresponding target variable name is found, the text type value (that is, the target current variable value corresponding to the target variable name) is converted to the target latest variable value of the target parameter type (that is, the variable value conversion operation is performed). If the parameter type conversion fails in this process, an error code is returned.

[0107] 4. In the configurator config, call the Linux system interface inotify_init to request the creation of a monitoring instance, and obtain the file descriptor fd fed back by the Linux system. If fd == -1, the initialization operation fails, that is, the creation of the monitoring instance fails, and the program terminates. If fd! = -1, it means that the initialization is successful, that is, the creation of the monitoring instance is successful, and the next step is to monitor the parameter configuration file and obtain the monitoring event trigger signal.

[0108] 5. The configurator config calls the inotify_add_watch interface (i.e., file adding interface) of the Linux system to determine the parameter configuration file as the file to be monitored. In addition, the parameter IN_CLOSE_WRITE (i.e., monitoring event trigger information) can be set to indicate the trigger signal when the parameter configuration file is written, modified and closed.

[0109] 6. Create and start a file monitoring thread in the configurator config, and obtain the monitoring event trigger information (i.e., IN_CLOSE_WRITE) of the parameter configuration file through the inotify_event interface (i.e., information saving interface) in this thread. If a monitoring event trigger signal is received, it means that the file has been modified and closed, then reload the parameter configuration file, read the corresponding values ​​of all variable names in the configuration file, and overwrite the original values ​​to obtain the current parameter information.

[0110] 7. The next time the user executes step 3, each parameter in the modified current parameter information can be obtained.

[0111] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.

[0112] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM (Read-Only Memory) / RAM (Random Access Memory), a disk, or an optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0113] According to another aspect of the embodiments of the present application, a software calibration device for implementing the above-mentioned software calibration method is also provided. Figure 3 is a structural block diagram of an optional software calibration device according to an embodiment of the present application, such as Figure 3 As shown, the device may include:

[0114] A monitoring module 1 is used to monitor a parameter configuration file and obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software;

[0115] The reading module 2 is used to read and obtain the current variable value corresponding to each current variable name in the parameter configuration file when the monitoring event trigger signal indicates that the parameter configuration file has been modified;

[0116] An updating module 3 is used to update the historical parameter information in the target memory area according to the current variable value corresponding to each current variable name, so as to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name;

[0117] Return module 4 is used to determine the target latest variable value corresponding to the target variable name from the current parameter information, and return the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

[0118] It should be noted that the monitoring module 1 in this embodiment can be used to execute the above step S101, the reading module 2 in this embodiment can be used to execute the above step S102, the updating module 3 in this embodiment can be used to execute the above step S103, and the returning module 4 in this embodiment can be used to execute the above step S104.

[0119] The device in this embodiment, in addition to the above modules, may also include a module for executing any method in any of the embodiments of the aforementioned software calibration method.

[0120] It should be noted that the above modules and corresponding steps implement the same examples and application scenarios, but are not limited to the contents disclosed in the above embodiments. It should be noted that the above modules, as part of the device, can be run in the implementation of Figure 1 The hardware environment of the method shown may be implemented by software or hardware, wherein the hardware environment includes a network environment.

[0121] According to another aspect of an embodiment of the present application, an electronic device for implementing the above-mentioned software calibration method is also provided. The electronic device may be a server, a terminal, or a combination thereof.

[0122] According to another embodiment of the present application, there is also provided an electronic device, including: Figure 4 As shown, the electronic device may include: a processor 1501 , a communication interface 1502 , a memory 1503 and a communication bus 1504 , wherein the processor 1501 , the communication interface 1502 , and the memory 1503 communicate with each other via the communication bus 1504 .

[0123] Memory 1503, used for storing computer programs;

[0124] The processor 1501 is used to implement the following steps when executing the program stored in the memory 1503:

[0125] Step S101, monitoring a parameter configuration file to obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software.

[0126] Step S102, when the monitoring event trigger signal indicates that the parameter configuration file has been modified, read and obtain the current variable value corresponding to each current variable name in the parameter configuration file.

[0127] Step S103, according to the current variable value corresponding to each current variable name, the historical parameter information in the target memory area is updated to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name.

[0128] Step S104, determining the target latest variable value corresponding to the target variable name from the current parameter information, and returning the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

[0129] Optionally, in this embodiment, the above-mentioned communication bus can be a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The communication interface is used for communication between the above-mentioned electronic device and other devices.

[0130] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0131] The above-mentioned processor can be a general-purpose processor, which can include but not be limited to: CPU (Central Processing Unit), NP (Network Processor), etc.; it can also be DSP (Digital Signal Processor), ASIC (Application Specific Integrated Circuit), FPGA (Field-Programmable Gate Array) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0132] An embodiment of the present application further provides a computer-readable storage medium, the storage medium including a stored program, wherein the method steps of the above method embodiment are executed when the program is run.

[0133] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media that can store program codes, such as a USB flash drive, a ROM, a RAM, a mobile hard disk, a magnetic disk, or an optical disk.

[0134] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0135] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.

[0136] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.

[0137] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0138] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution provided in this embodiment.

[0139] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0140] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A software calibration method, characterized in that: include: Monitoring a parameter configuration file to obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software; When the monitoring event trigger signal indicates that the parameter configuration file has been modified, reading and obtaining a current variable value corresponding to each current variable name in the parameter configuration file; According to the current variable value corresponding to each current variable name, the historical parameter information in the target memory area is updated to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name; The target latest variable value corresponding to the target variable name is determined from the current parameter information, and the target latest variable value corresponding to the target variable name is returned to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

2. The software calibration method according to claim 1, characterized in that: Before monitoring the parameter configuration file and obtaining the monitoring event trigger signal, the method further includes: The parameter configuration file is configured according to a preset parameter configuration format, wherein the parameter configuration format is used to indicate the correspondence between variable names and variable values ​​in the parameter configuration file.

3. The software calibration method according to claim 1, characterized in that: Before monitoring the parameter configuration file to obtain the monitoring event trigger signal, the method further includes: Requesting in the configurator to call a monitoring instance creation interface of the Linux system, requesting to create a monitoring instance, and obtaining a file descriptor fed back by the Linux system, wherein the monitoring instance is used to monitor the parameter configuration file; If the file descriptor indicates that the monitoring instance is successfully created, execute the next step; When the file descriptor indicates that the creation of the monitoring instance fails, the next step is stopped, and a request is made to call the monitoring instance creation interface of the Linux system in the configurator again to request the creation of the monitoring instance again.

4. The software calibration method according to claim 1, characterized in that: The monitoring of the parameter configuration file to obtain the monitoring event trigger signal includes: By calling the file adding interface of the Linux system, the parameter configuration file is determined as the file to be monitored; The monitoring event triggering information of the parameter configuration file is obtained by calling the information saving interface of the Linux system.

5. The software calibration method according to claim 1, characterized in that: The step of determining the target latest variable value corresponding to the target variable name from the current parameter information, and returning the target latest variable value corresponding to the target variable name to the target software includes: Determine the target current variable value corresponding to the target variable name from the current parameter information; By executing a variable value conversion operation, the target current variable value is converted into the target latest variable value of the target parameter type; The target latest variable value corresponding to the target variable name is returned to the target software.

6. The software calibration method according to claim 5, characterized in that: After determining the target latest variable value corresponding to the target variable name from the current parameter information, the method further includes: If the variable value conversion operation is not successfully executed, an error code is returned.

7. The software calibration method according to claim 1, characterized in that: After the historical parameter information in the target memory area is updated according to the current variable value corresponding to each current variable name to obtain the current parameter information in the target memory area, the method further includes: From the current parameter information, query whether there is a target variable name; In the case where the target variable name exists in the current parameter information, executing a jump operation for jumping to the target latest variable value corresponding to the target variable name determined from the current parameter information; If the target variable name does not exist in the current parameter information, an error code is returned.

8. A software calibration device, characterized in that: include: A monitoring module, used to monitor a parameter configuration file and obtain a monitoring event trigger signal, wherein the parameter configuration file is used to calibrate the target software; A reading module, configured to read and obtain a current variable value corresponding to each current variable name in the parameter configuration file when the monitoring event trigger signal indicates that the parameter configuration file has been modified; An updating module, configured to update the historical parameter information in the target memory area according to the current variable value corresponding to each current variable name, so as to obtain the current parameter information in the target memory area, wherein the historical parameter information includes one-to-one corresponding historical variable names and historical variable values, and the current parameter information includes the current variable value corresponding to each current variable name; The return module is used to determine the target latest variable value corresponding to the target variable name from the current parameter information, and return the target latest variable value corresponding to the target variable name to the target software, so that the target software is calibrated according to the target latest variable value corresponding to the target variable name.

9. An electronic device comprising a processor, a communication interface, a memory and a communication bus, wherein: The processor, the communication interface and the memory communicate with each other via the communication bus, wherein: The memory is used to store computer programs; The processor is configured to execute the method steps of any one of claims 1 to 7 by running the computer program stored in the memory.

10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, wherein the computer program is configured to execute the method steps described in any one of claims 1 to 7 when run.