Object function test method and device based on model construction, equipment and medium

By obtaining object metadata and attribute information of heterogeneous devices, building functional testing models and conducting tests, the problem of cumbersome and low efficiency of functional testing caused by the large number of devices and a wide variety of devices is solved, and flexible and efficient functional testing is achieved.

CN119938427APending Publication Date: 2025-05-06DAWNING CLOUD COMPUTING TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311411823.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-27
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

In discrete manufacturing, the number of heterogeneous equipment is huge and diverse, making it cumbersome and complex to build functional testing models for each device, low testing efficiency and inflexible testing in combination with requirements or scenarios.

Method used

By obtaining the object metadata and attribute information of the object to be constructed, the object virtual model is determined, and a functional test model is constructed based on the attribute information, the object metadata is input into the functional test model for testing, and the functional test results are obtained. Optionally, the service metadata associated with the target functional service is selected for functional testing based on the scene information to be tested or the preset scene information.

Benefits of technology

It realizes flexible construction of functional testing models for objects to be constructed for different functional testing needs, improves the efficiency and flexibility of functional testing, and ensures the accuracy and reusability of functional testing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119938427A_ABST
    Figure CN119938427A_ABST
Patent Text Reader

Abstract

The invention discloses an object function test method and device based on model construction, equipment and a medium. The method comprises the steps of obtaining object metadata and object attribute information of a to-be-constructed object of a model construction demand side; determining an object virtual model of the to-be-constructed object; according to the object attribute information, constructing a function test model of the to-be-constructed object based on the object virtual model; and inputting the object metadata into a function test model for function test to obtain a function test result output by the function test model. According to the embodiment of the invention, the test efficiency and the test flexibility of the object function test are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of industrial Internet technology, and in particular to a method, device, equipment and medium for object function testing based on model building. Background Art

[0002] With the continuous improvement of productivity and technology, the scale of discrete manufacturing industry has been expanding, the scale of equipment has been growing, and the types, quantity and functions of production equipment have increased significantly. The operating efficiency and functional realization of an enterprise's equipment or system are directly related to the economic development of the enterprise. Therefore, unified equipment management, intelligent simulation and functional testing of heterogeneous equipment of different enterprises have become urgent problems to be solved in the equipment-intensive discrete manufacturing industry.

[0003] At present, the way to perform functional testing or intelligent simulation on enterprise equipment is to build a functional test model corresponding to the equipment, and use the equipment data access model to realize intelligent simulation and functional testing. However, the equipment owned by different enterprises is heterogeneous and the number and types of equipment are huge. If a corresponding functional test model is built for each device, the functional testing process of the device will be cumbersome and complicated, resulting in low test efficiency and inability to perform flexible testing in combination with needs or scenarios. Summary of the invention

[0004] The present invention provides a method, device, equipment and medium for object function testing based on model construction, so as to improve the test efficiency and test flexibility of object function testing.

[0005] According to one aspect of the present invention, a method for testing object functions based on model building is provided, the method comprising:

[0006] Obtain object metadata and object attribute information of the object to be built from the model building demander;

[0007] Determining an object virtual model of the object to be constructed;

[0008] According to the object attribute information, based on the object virtual model, construct a functional test model of the object to be constructed;

[0009] The object metadata is input into the functional test model to perform a functional test, and a functional test result output by the functional test model is obtained.

[0010] Optionally, constructing a functional test model of the object to be constructed based on the object virtual model according to the object attribute information includes:

[0011] Selecting a target functional service from at least one pre-built reference functional service according to the object attribute information;

[0012] The target functional service is bound to the object virtual model to obtain a functional test model corresponding to the object to be constructed.

[0013] The above technical solution selects the target functional service from at least one pre-built reference functional service according to the object attribute information, and binds the target functional service to the object virtual model to obtain the functional test model corresponding to the object to be constructed, thereby realizing the accurate construction of the functional test model and the comprehensiveness and flexibility of the functional testing of the constructed functional test model.

[0014] Optionally, before inputting the object metadata into the functional test model to perform a functional test and obtaining a functional test result output by the functional test model, the method further includes:

[0015] If the scenario information to be tested fed back by the model building demander is monitored, then according to the scenario information to be tested, service metadata associated with the target functional service is selected from the object metadata of the object to be built;

[0016] Accordingly, the step of inputting the object metadata into the functional test model for functional testing to obtain the functional test result output by the functional test model includes:

[0017] The service metadata is input into the functional test model to perform functional testing, and a functional test result output by the functional test model is obtained.

[0018] The above-mentioned technical solution realizes targeted selection of object metadata by selecting service metadata associated with the target functional service from the object metadata of the object to be constructed according to the test scenario information fed back by the model construction demander when monitoring the test scenario information, and realizes accurate determination of the service metadata associated with the target functional service in combination with the scenario information.

[0019] Optionally, the method further includes:

[0020] If the test scenario information fed back by the model construction demander is not monitored, the test scenario information associated with the object to be constructed is selected from at least one preset scenario information, and based on the test scenario information, the service metadata associated with the target functional service is selected from the object metadata of the object to be constructed.

[0021] The above technical solution selects test scenario information associated with the object to be constructed from at least one preset scenario information, and selects service metadata associated with the target functional service from the object metadata of the object to be constructed based on the test scenario information, thereby realizing the determination of the service metadata associated with the target functional service when the object to be constructed does not feedback the test scenario information. By selecting a working condition scenario that has a strong correlation with the object to be constructed from at least one preset working condition scenario based on the object application or usage scenario of the object to be constructed, the accurate selection of the test scenario information is realized, thereby improving the accurate determination of the service metadata.

[0022] Optionally, the number of services of the target function service is at least two;

[0023] Accordingly, the inputting the service metadata into the functional test model to perform a functional test and obtaining a functional test result output by the functional test model includes:

[0024] The service metadata is input into the functional test model, and each of the target functional services performs a functional test based on its own corresponding service metadata and functional test conditions, to obtain its own test results respectively corresponding to each of the target functional services;

[0025] Generate a functional test result including a self-test result of each of the target functional services.

[0026] The above-mentioned technical scheme inputs the service metadata into the functional test model, and each target functional service performs functional testing based on its own corresponding service metadata and functional test conditions, obtains the self-test results corresponding to each target functional service, and generates functional test results including the self-test results of each target functional service, thereby realizing the determination of the functional test results when at least two target functional services exist in the functional test model. Each target functional service is independently tested based on its own corresponding service metadata and functional test conditions, decoupled from each other, and complementary interference and influence. Each target functional service can be executed in parallel and simultaneously, thereby realizing the comprehensiveness of the test of the functional test results while improving the efficiency of the functional test.

[0027] Optionally, the method further includes:

[0028] Obtaining the number of service calls and service response time of each of the reference function services within a preset time period;

[0029] Determining the service usage rate of the reference function service according to the number of service calls; and

[0030] Determining the service performance of the reference functional service according to the service response time;

[0031] The reference function service is updated according to the service usage rate and the service performance.

[0032] The above technical solution determines the service usage rate of the reference function service according to the number of service calls, determines the service performance of the reference function service according to the service response time, and updates the reference function service according to the service usage rate and service performance, thereby realizing the continuous improvement of the reference function service, thereby ensuring the reliability and availability of the reference function service when it is called, and ensuring the service performance of the reference function service. Reference function services with low usage rates are regularly screened and eliminated to retain reference function services with higher value, thereby reducing the occupation of memory space.

[0033] According to another aspect of the present invention, there is provided an object function testing device based on model construction, comprising:

[0034] The object information acquisition module is used to obtain the object metadata and object attribute information of the object to be constructed of the model construction demander;

[0035] A virtual model determination module, used to determine the object virtual model of the object to be constructed;

[0036] A function model building module, used to build a function test model of the object to be built according to the object attribute information and based on the object virtual model;

[0037] The test result determination module is used to input the object metadata into the functional test model to perform a functional test and obtain a functional test result output by the functional test model.

[0038] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:

[0039] at least one processor; and

[0040] a memory communicatively connected to the at least one processor; wherein,

[0041] The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the object function testing method based on model building described in any embodiment of the present invention.

[0042] According to another aspect of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the object function testing method based on model building described in any embodiment of the present invention when executed.

[0043] The technical solution of the embodiment of the present invention determines the object virtual model of the object to be constructed by obtaining the object metadata and object attribute information of the object to be constructed of the model construction demander, and constructs a functional test model of the object to be constructed based on the object virtual model according to the object attribute information, inputs the object metadata into the functional test model for functional testing, and obtains the functional test results output by the functional test model, thereby realizing flexible construction of functional test models for objects to be constructed with different functional test requirements, and the constructed functional test model has reusability and extensibility. In addition, the functional test requirements of the object to be constructed are determined in combination with the object attribute information of the object to be constructed, and the functional test model is automatically constructed based on the functional test requirements, thereby realizing the flexibility of automated functional testing based on model creation, and performing functional testing on the object to be constructed based on the constructed functional test model, thereby improving the model testing efficiency on the basis of ensuring the accuracy of the functional testing.

[0044] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0046] Figure 1 is a flowchart of an object function testing method based on model building provided according to Embodiment 1 of the present invention;

[0047] Figure 2 is a flow chart of an object function testing method based on model building provided according to Embodiment 2 of the present invention;

[0048] Figure 3A is a flowchart of an object function testing method based on model building provided in accordance with Embodiment 3 of the present invention;

[0049] Figure 3B is a structural diagram of a model building system for functional testing provided in Embodiment 3 of the present invention;

[0050] Figure 4 is a structural schematic diagram of an object function testing device based on model building provided according to a fourth embodiment of the present invention;

[0051] Figure 5It is a structural schematic diagram of an electronic device for implementing the object function testing method based on model building according to an embodiment of the present invention. DETAILED DESCRIPTION

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

[0053] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention 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 interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0054] Embodiment 1

[0055] Figure 1 This is a flowchart of a method for object function testing based on model building provided in the first embodiment of the present invention. This embodiment is applicable to the case where a function test model is built for a device or system, and a function test is performed based on the built function test model. The method can be executed by an object function testing device based on model building. The object function testing device based on model building can be implemented in the form of hardware and / or software. The object function testing device based on model building can be configured in an electronic device. Figure 1 As shown, the method includes:

[0056] S110: Obtain object metadata and object attribute information of the object to be constructed of the party requiring model construction.

[0057] Among them, the party that needs model building can be an enterprise or user with model building needs, simulation test needs or functional testing needs; the object to be built is the object for which the functional test model is to be built, for example, the object to be built can be a device or a system.

[0058] The object metadata may be data such as attributes and parameters associated with the object to be constructed. For example, the object metadata may include operating time, operating speed, use cycle, downtime, operating current, fault data, production quantity, speed limit, operating voltage, and rework rate, etc. Different objects to be constructed have different corresponding object metadata.

[0059] Among them, the object attribute information is used to describe the object type, application scenario and implementation function of the object to be constructed. Objects to be constructed with different object attribute information focus on different test items during the functional test. For example, object A to be constructed and object B to be constructed are two devices with different object attributes. The test items focused on by object A to be constructed include test item a, test item b and test item c; the test items focused on by object B to be constructed include test item a, test item d and test item f. Therefore, the test items focused on and tested by objects to be constructed with different object attributes may be different. Among them, the test items can be, for example, current test, voltage test, safety test or reliability test.

[0060] It should be noted that in order to improve data security, the model building demander and at least one management device and management system with functional testing requirements corresponding to the model building demander can pre-register their identities and permissions.

[0061] Exemplarily, before obtaining the object metadata and object attribute information of the object to be built of the model building demander, the identity authentication and user authority verification are performed on the model building demander, and the object authority verification is performed on the object to be built. Specifically, it can be determined whether the model building demander is in a preset user whitelist. If so, it is determined that the model building demander has access rights, and further determined whether the object to be built is in the preset object whitelist. If so, it is determined that the object to be built of the model building demander has functional testing permissions, a communication connection is established with the object to be built of the model building demander, and the object metadata and object attribute information of the object to be built of the model building demander are obtained.

[0062] It is understandable that the number of demanders of the model building demander and the number of objects to be built of the model building demander can be one or more. Therefore, the amount of data in the process of the model building demander uploading object metadata and object attribute information in real time or periodically as a data source is relatively large. Since object metadata is dynamically changing data, object metadata needs to be uploaded periodically or in real time to ensure the immediacy of data; however, object attribute information is fixed or will not change in a short period of time, so object attribute information can be obtained in real time or periodically, and the object attribute information of each object to be built can also be pre-stored locally and updated regularly to reduce data interaction pressure.

[0063] S120: Determine the object virtual model of the object to be constructed.

[0064] The object virtual model may be a simulation model constructed based on model simulation software.

[0065] Exemplarily, a preset model simulation software can be used to model the object to be constructed to obtain a virtual model of the object to be constructed; wherein the object virtual model provides at least one virtual interface that can be used for data interaction with service modules such as different functional tests; the model simulation software can be pre-selected by relevant technical personnel, for example, the model simulation software can be U3D (Universal 3D, 3D game engine).

[0066] Specifically, abstract modeling can be performed based on the object characteristics, components, physical properties, communication methods, behaviors and functions of the object to be constructed, and the resulting object virtual model includes but is not limited to input and output interfaces, control logic, executable operation items and related components. The related components include but are not limited to sensors, actuators, control units, control interfaces, etc. deployed on the object; the physical properties of the object virtual model may include size, weight, material, power supply, communication methods, behaviors and functions, etc. Communication methods include but are not limited to data formats, protocols and transmission methods; behaviors and functions include but are not limited to describing executable actions and functions of the object, such as starting, stopping, adjusting, detecting and alarming, etc.

[0067] S130. Construct a functional test model of the object to be constructed according to the object attribute information and based on the object virtual model.

[0068] Exemplarily, based on the object attribute information, the test items that the object to be constructed focuses on are determined, and based on the virtual interface provided by the object virtual model, functional test modules related to the test items are created on the object virtual model to obtain a functional test model of the object to be constructed that includes at least one functional test module.

[0069] S140: Input the object metadata into the functional test model to perform functional testing, and obtain the functional test results output by the functional test model.

[0070] Exemplarily, the object metadata is input into the functional test model to perform functional testing, and functional test results output by each functional test module of the functional test model based on the object metadata are obtained.

[0071] It should be noted that after using the functional test model to perform functional testing, the functional test model can be verified and tested. Specifically, the verification and testing can be performed through a simulation environment. If the verification and testing of the functional test model pass, the functional test model can be stored, and a functional test model selection can be provided to the model builder so that the model builder can select from the available functional test models based on actual testing requirements.

[0072] In addition, the party that needs to build the model can also authorize the functional test model it has built for use by other parties. For example, if the party that needs to build the model is an enterprise, and the object to be built is a device or system within the enterprise, there may be a situation where different enterprises use the same device or system. For example, a third-party provider provides the same financial analysis system for financial analysis to Enterprise A and Enterprise B respectively. Enterprise A and Enterprise B generate different object metadata in the process of using the same financial analysis system. Therefore, if Enterprise A generates the corresponding functional test model m using the financial analysis system as the object to be built, Enterprise B can obtain the right to use the functional test model m through Enterprise A, and use the functional test model m to perform functional testing on its own financial analysis system.

[0073] The technical solution of the embodiment of the present invention determines the object virtual model of the object to be constructed by obtaining the object metadata and object attribute information of the object to be constructed of the model construction demander, and constructs a functional test model of the object to be constructed based on the object virtual model according to the object attribute information, inputs the object metadata into the functional test model for functional testing, and obtains the functional test results output by the functional test model, thereby realizing flexible construction of functional test models for objects to be constructed with different functional test requirements, and the constructed functional test model has reusability and extensibility. In addition, the functional test requirements of the object to be constructed are determined in combination with the object attribute information of the object to be constructed, and the functional test model is automatically constructed based on the functional test requirements, thereby realizing the flexibility of automated functional testing based on model creation, and performing functional testing on the object to be constructed based on the constructed functional test model, thereby improving the model testing efficiency on the basis of ensuring the accuracy of the functional testing.

[0074] Embodiment 2

[0075] Figure 2 This is a flow chart of a method for testing object functions based on model building provided in the second embodiment of the present invention. This embodiment is optimized and improved on the basis of the above technical solutions.

[0076] Furthermore, the step of "building a functional test model of the object to be built according to the object attribute information and based on the object virtual model" is refined into "selecting a target functional service from at least one pre-built reference functional service according to the object attribute information; binding the target functional service to the object virtual model to obtain a functional test model corresponding to the object to be built." to improve the way of building the functional test model.

[0077] Furthermore, before the step of "inputting the object metadata into the functional testing model for functional testing, and obtaining the functional testing results output by the functional testing model", the step of "if the test scenario information fed back by the model construction demander is monitored, then according to the test scenario information, selecting the service metadata associated with the target functional service from the object metadata of the object to be constructed" is added; accordingly, the step of "inputting the object metadata into the functional testing model for functional testing, and obtaining the functional testing results output by the functional testing model" is refined into "inputting the service metadata into the functional testing model for functional testing, and obtaining the functional testing results output by the functional testing model" to improve the method of selecting the service metadata and the method of determining the functional test results.

[0078] It should be noted that for the parts not described in detail in the embodiments of the present invention, reference can be made to the descriptions of other embodiments. Figure 2 As shown, the method comprises the following specific steps:

[0079] S210: Obtain object metadata and object attribute information of the object to be constructed of the model construction demander.

[0080] S220: Determine the object virtual model of the object to be constructed.

[0081] S230: Select a target function service from at least one pre-built reference function service according to the object attribute information.

[0082] Among them, the reference function service can be pre-built by relevant technical personnel. For example, the reference function service can be a reliability function service, an OEE (Overall Equipment Effectiveness) function service, an adaptability function service, a stability function service, a safety function service, an economic function service, and an environmental protection function service. Different reference function services are used to perform different function tests. For example, the safety function service is used to test the safety of a device or system; the stability function service is used to test the stability of a device or system.

[0083] Exemplarily, a target functional service related to the test attribute of the object to be constructed can be selected from at least one pre-built reference functional service according to the object attribute information. The number of target functional services can be one or more. For example, if the object A to be constructed is a robot device for manipulating and grasping objects, the object A to be constructed needs to ensure its own working stability, safety and reliability. Therefore, the object attribute information of the object A to be constructed includes stability attributes, safety attributes and reliability attributes. Therefore, according to the object attribute information of the object A to be constructed, the stability functional service, the safety functional service and the reliability functional service in the reference functional service can be used as the target functional service.

[0084] Optionally, the target functional service can also be selected by the model building demander based on actual needs; illustratively, at least one reference functional service can be provided to the model building demander for selection, and the model building demander selects one or more reference functional services as the target functional service based on the provided reference functional services and actual testing needs.

[0085] Optionally, if the reference functional services provided to the model building demander do not meet the demander's functional testing requirements, a service creation interface is provided to the model building demander, and the model building demander customizes the functional services according to its actual needs to meet the demander's functional testing requirements.

[0086] S240: Bind the target functional service to the object virtual model to obtain a functional test model corresponding to the object to be constructed.

[0087] Exemplarily, the target function service is bound to the object virtual model, that is, the function of the target function service is mapped to the corresponding part of the object virtual model, and a functional test model corresponding to the object to be constructed is generated. Specifically, the target function service can be flexibly associated with the object virtual model by "dragging and dropping" the target function service, thereby realizing the mapping of the model function and obtaining a functional test model with test functions.

[0088] It should be noted that since the same reference function service can be called by the same or different objects to be built by different model construction demanders during the model creation process, the reference function service needs to ensure the reliability, availability and value of its own service.

[0089] In an optional embodiment, the number of service calls and service response time of each reference function service within a preset time period are obtained; the service utilization rate of the reference function service is determined based on the number of service calls; and the service performance of the reference function service is determined based on the service response time; and the reference function service is updated based on the service utilization rate and the service performance.

[0090] The preset time period can be preset by relevant technical personnel according to actual needs, for example, the preset time period can be 3 months. The number of service calls can be the number of times the reference function service is determined as the target function service by the object to be constructed within the preset time period; the service response time can be the average service response time during the process of the reference function service being used as the target function service within the preset time period.

[0091] Exemplarily, for any reference function service, according to the service call times of the reference function service and the total service call times of all reference function services, the call times ratio of the reference function service is determined, and the call times ratio is used as the service utilization rate of the reference function service. According to the service response time of the reference function service, the service performance of the reference function service is determined based on the service response time judgment condition. Specifically, if the service response time of the reference function service is greater than a preset time threshold, it is determined that the service performance of the reference function service is poor; if the service response time of the reference function service is not greater than the preset time threshold, it is determined that the service performance of the reference function service is better. Among them, the time threshold can be pre-set by relevant technical personnel according to actual needs.

[0092] If the service usage rate of the reference function service is lower than the preset usage threshold, it means that the usage frequency of the reference function service is low, and the reference function service can be deleted to reduce the memory space occupied; if the service usage rate of the reference function service is not lower than the preset usage threshold, it is determined whether the service performance of the reference function service is poor. If so, the influencing factors affecting the function service performance are determined, and the reference function service is updated based on the influencing factors; if not, there is no need to update the reference function service.

[0093] Optionally, the reference function service may have a version identification number, and the reference function service before and after each update may be retained to obtain at least one updated version of the reference function service, and different versions of the reference function service may be subsequently obtained based on the version identification number.

[0094] This optional embodiment determines the service usage rate of the reference function service according to the number of service calls, determines the service performance of the reference function service according to the service response time, and updates the reference function service according to the service usage rate and service performance, thereby achieving continuous improvement of the reference function service, thereby ensuring the reliability and availability of the reference function service when it is called, and ensuring the service performance of the reference function service. Reference function services with low usage rates are regularly screened and eliminated to retain reference function services with higher value, thereby reducing the occupation of memory space.

[0095] S250: If the scenario information to be tested fed back by the model construction demander is monitored, then according to the scenario information to be tested, service metadata associated with the target functional service is selected from the object metadata of the object to be constructed.

[0096] Among them, the scenario information to be tested may be an operating condition scenario to be tested, for example, the operating condition scenario to be tested may be a light load operating condition scenario, a shutdown operating condition scenario, an abnormal operating condition scenario, etc.

[0097] It should be noted that different target function services use different object metadata during the testing process, and the object metadata required for the same target function service is also different for different scenarios to be tested.

[0098] Exemplarily, for target function service A, its associated object metadata may include operation data, fault data, maintenance data, operation data, safety monitoring data and environmental monitoring data. Among them, operation data may include speed, load and pressure; fault data may include fault type, fault frequency and fault cause; maintenance data may include maintenance time, maintenance content and replaced parts; operation data may include operator, operation time and operation steps; safety monitoring data may include access control records, sensor data and emergency stop data; environmental monitoring data may include temperature, humidity and vibration. For different working condition scenarios 1 and 2, the metadata required for target function service A in working condition scenario 1 may include speed, fault type, maintenance time, operation time and emergency stop data; the object metadata required for target function service A in working condition scenario 2 may include load, pressure, fault type, maintenance content, operation steps and emergency stop data. Therefore, for different working condition scenarios to be tested, the service metadata corresponding to the scenario can be obtained by the target function service through different combinations of object metadata.

[0099] It is understandable that the model building demander can choose to feedback or not feedback the scene information to be tested, and the specific choice can be made according to the actual test scene requirements of the model building demander. Optionally, if the scene information to be tested fed back by the model building demander is not monitored, the test scene information associated with the object to be built is selected from at least one preset scene information, and based on the test scene information, the service metadata associated with the target functional service is selected from the object metadata of the object to be built.

[0100] The preset scenario information may be preset by relevant technical personnel, and the preset scenario information may be a preset working condition test scenario. The test scenario information associated with the object to be constructed may be a working condition scenario that is strongly associated with the object application or use scenario of the object to be constructed, and the number of working condition scenarios that are strongly associated with the corresponding working condition scenario to be constructed may be one or more.

[0101] For example, if the preset scenario information includes a light load operating condition scenario, a full load operating condition scenario, and a shutdown fault operating condition scenario, etc. If the object application or usage scenario of the object to be constructed is a railway, and the operating condition scenario strongly associated with the application scenario is a shutdown fault operating condition scenario, the shutdown fault operating condition scenario can be determined as the test scenario information associated with the object to be constructed.

[0102] The method of selecting service metadata associated with the target functional service from the object metadata of the object to be constructed according to the test scenario information is the same as the above-mentioned method of selecting service metadata associated with the target functional service from the object metadata of the object to be constructed according to the test scenario information, and will not be repeated in this embodiment.

[0103] The technical solution of this optional embodiment selects test scenario information associated with the object to be constructed from at least one preset scenario information, and selects service metadata associated with the target functional service from the object metadata of the object to be constructed based on the test scenario information, thereby realizing the determination of the service metadata associated with the target functional service when the object to be constructed does not feedback the test scenario information. By selecting a working condition scenario that has a strong correlation with the object to be constructed from at least one preset working condition scenario based on the object application or usage scenario of the object to be constructed, the accurate selection of the test scenario information is realized, thereby improving the accurate determination of the service metadata.

[0104] S260: Input the service metadata into the functional test model to perform functional testing, and obtain the functional test results output by the functional test model.

[0105] It is understandable that the number of target function services associated with the function test model may be one or more. When there are multiple target function services, the service metadata required to be used by different target function services may be the same or different.

[0106] In an optional embodiment, the number of services of the target functional service is at least two; accordingly, the service metadata is input into the functional test model for functional testing, and a functional test result output by the functional test model is obtained, including: inputting the service metadata into the functional test model, and each target functional service performs a functional test based on its own corresponding service metadata and functional test conditions, to obtain its own test result corresponding to each target functional service; generating a functional test result including the self-test result of each target functional service.

[0107] Among them, different target functional services correspond to different functional test conditions. For example, if the target functional service is a service life functional test service, the corresponding functional test condition can be based on the service metadata to determine whether the use period of the object to be constructed is greater than a preset period threshold. If so, it can be considered that the service life functional test of the object to be constructed has failed; if not, it can be considered that the service life functional test of the object to be constructed has passed.

[0108] Exemplarily, the service metadata is input into the functional testing model, and each target functional service performs functional testing based on its corresponding service data and its own functional testing conditions to obtain its own testing results, and then the self-test results of each target functional service are determined as the functional testing results of the object to be constructed.

[0109] This optional implementation scheme inputs service metadata into a functional test model, and each target functional service performs a functional test based on its own corresponding service metadata and functional test conditions, obtains each target functional service's own test results, and generates a functional test result including each target functional service's own test result, thereby achieving the determination of the functional test results when at least two target functional services exist in the functional test model. Each target functional service is independently tested based on its own corresponding service metadata and functional test conditions, and is decoupled from each other, with complementary interference and influence. Each target functional service can be executed in parallel and simultaneously, thereby achieving the comprehensiveness of the functional test results and improving the functional test efficiency.

[0110] The technical solution of this embodiment selects the target functional service from at least one pre-built reference functional service according to the object attribute information, and binds the target functional service to the object virtual model to obtain the functional test model corresponding to the object to be constructed, thereby realizing the accurate construction of the functional test model and the comprehensiveness and flexibility of the functional test of the constructed functional test model. When monitoring the test scenario information fed back by the model construction demander, the service metadata associated with the target functional service is selected from the object metadata of the object to be constructed according to the test scenario information, thereby realizing the targeted selection of the object metadata, and combining the scenario information to realize the accurate determination of the service metadata associated with the target functional service.

[0111] Embodiment 3

[0112] Figure 3A This is a flow chart of a method for testing object functions based on model building provided in Embodiment 3 of the present invention. This embodiment provides a preferred example based on the above embodiments.

[0113] like Figure 3A As shown, the method comprises the following specific steps:

[0114] S310: Obtain object metadata and object attribute information of the object to be constructed of the model construction demander.

[0115] S320: Determine the object virtual model of the object to be constructed.

[0116] S330: Select a target function service from at least one pre-built reference function service according to the object attribute information.

[0117] S340: Bind the target functional service to the object virtual model to obtain a functional test model corresponding to the object to be constructed.

[0118] S350A: If the scenario information to be tested fed back by the model construction demander is monitored, then service metadata associated with the target functional service is selected from the object metadata of the object to be constructed according to the scenario information to be tested.

[0119] S350B. If the test scenario information fed back by the model construction demander is not monitored, the test scenario information associated with the object to be constructed is selected from at least one preset scenario information, and based on the test scenario information, the service metadata associated with the target functional service is selected from the object metadata of the object to be constructed.

[0120] S360: Input the service metadata into the function test model, and each target function service performs a function test based on its own corresponding service metadata and function test conditions to obtain its own test results.

[0121] S370: Generate a functional test result including a self-test result of each target functional service.

[0122] Figure 3B The structural diagram of a model building system for functional testing provided by an embodiment of the present invention is as follows. The model building system 30 for functional testing includes: a metadata management module 301, a meta-service management module 302, an intelligent object model building module 303, a model overview module 304, an interface management module 305 and a permission management module 306.

[0123] Among them, the metadata management module 301 is used to manage the metadata related to the received data source; the data source is the equipment and projects in the enterprise, etc.; the metadata management module can realize the element data such as production data associated with the enterprise equipment or enterprise project. For example, the element data may include equipment element data, attribute and parameter element data, relationship and topology element data, life cycle element data, knowledge document element data, equipment change element data and production element data, etc. Among them, the equipment element data may include equipment working current data and equipment working voltage data, etc.; the attribute and parameter element data may include equipment size data and equipment color data, etc.; the equipment change element data may include the version number of the equipment iteration update, etc.; the relationship and topology element data may include other equipment related data associated with the equipment, etc.; the life cycle element data may include equipment service life data, etc.; the knowledge document element data may include document data related to the equipment, etc., and the metadata types and specific metadata that can be managed by the metadata management module are not repeated in this embodiment.

[0124] Among them, the meta-service management module 302 can uniformly manage and configure the reference meta-services in the system, and provide flexible, secure, and high-performance meta-service management functions. Meta-service refers to the programmatic encapsulation of metadata for flexible calling by the device intelligent object model. The meta-service management module 302 can support users to customize and register various meta-services in the system, and can set the parameters and permissions of the meta-services in the customized meta-services. The purpose of permission setting is to ensure that only authorized users can call and use meta-services customized by other users. Specifically, the main functions of the meta-service management module 302 include: meta-service definition and registration functions, meta-service configuration and management functions, meta-service calling and integration functions, meta-service security and permission management functions, and meta-service monitoring and performance analysis functions.

[0125] Among them, the intelligent object model construction module 303 can support users or enterprises to manage various types of equipment and project systems for intelligent object models for different functional tests or intelligent simulations, and can support operations such as configuring basic model information, configuring model alarm information, configuring data point status, and binding related meta-services. In addition, the intelligent object model construction module 303 also provides model permission management functions, supporting customized settings of model access rights according to dimensions such as organizations, roles, and individuals; the intelligent object model construction module 303 also supports model customization, and the module provides a visual interface to support users to associate meta-services with models in the form of "drag and drop". Specifically, the main functions of the intelligent object model construction module 303 include: model customization and description functions, model configuration and management functions, model meta-service mapping and metadata docking functions, model verification and verification rule management functions, model evolution and version management functions, and model extension and customization functions.

[0126] The model overview module 304 is used to comprehensively display various aspects of the system information and provide users with a comprehensive overview of the smart object model and meta-services.

[0127] Among them, the interface management module 305 provides communication gateway management, supports functions such as creating gateways, configuring gateways, and binding devices. At the same time, it supports authorization of gateway access rights by department, role, and individual. Users can issue configuration files for the configuration of the communication network management to realize real-time data collection and forwarding of devices to the system platform. In addition, the interface management module 305 also supports the system standard API (Application Programming Interface) interface and other business system docking.

[0128] The authority management module 306 is used to implement department management, role management, user management and system setting management; and to implement authority management of smart object models and meta-services.

[0129] The data source can be the same or different devices or systems of the enterprise. The device can be a device with networking function, but is not limited to the device itself having networking function. It can also be connected to the Internet through the networking tools provided by the interface management module 305 or a gateway with networking function. The networking methods include but are not limited to wired, NB-IOT (Narrow Band Internet of Things), LORA (Long Range Radio), WIFI (Wireless Fidelity) and 4G (the 4th generation mobile communication technology) / 5G (the 5th generation mobile communication technology), etc.

[0130] It should be noted that metadata not only includes real-time status data and reference data of equipment, but also industrial element data associated with equipment in business systems such as enterprise MES (Manufacturing Execution System), ERP (Enterprise Resource Planning) management system, and equipment management.

[0131] Embodiment 4

[0132] Figure 4A schematic diagram of the structure of a model-based object function test device provided in Embodiment 4 of the present invention. The model-based object function test device provided in the embodiment of the present invention can be applied to the case where a function test model is constructed for a device or system, and a function test is performed based on the constructed function test model. The model-based object function test device can be implemented in the form of hardware and / or software, such as Figure 4 As shown, the device specifically includes: an object information acquisition module 401, a virtual model determination module 402, a function model construction module 403 and a test result determination module 404.

[0133] The object information acquisition module 401 is used to acquire the object metadata and object attribute information of the object to be constructed of the model construction demander;

[0134] A virtual model determination module 402 is used to determine the object virtual model of the object to be constructed;

[0135] A function model building module 403 is used to build a function test model of the object to be built according to the object attribute information and based on the object virtual model;

[0136] The test result determination module 404 is used to input the object metadata into the functional test model to perform a functional test and obtain a functional test result output by the functional test model.

[0137] The technical solution of the embodiment of the present invention determines the object virtual model of the object to be constructed by obtaining the object metadata and object attribute information of the object to be constructed of the model construction demander, and constructs a functional test model of the object to be constructed based on the object virtual model according to the object attribute information, inputs the object metadata into the functional test model for functional testing, and obtains the functional test results output by the functional test model, thereby realizing flexible construction of functional test models for objects to be constructed with different functional test requirements, and the constructed functional test model has reusability and extensibility. In addition, the functional test requirements of the object to be constructed are determined in combination with the object attribute information of the object to be constructed, and the functional test model is automatically constructed based on the functional test requirements, thereby realizing the flexibility of automated functional testing based on model creation, and performing functional testing on the object to be constructed based on the constructed functional test model, thereby improving the model testing efficiency on the basis of ensuring the accuracy of the functional testing.

[0138] Optionally, the function model building module 403 includes:

[0139] A function service selection unit, configured to select a target function service from at least one pre-built reference function service according to the object attribute information;

[0140] The function model construction unit is used to bind the target function service to the object virtual model to obtain the function test model corresponding to the object to be constructed.

[0141] Optionally, the device further comprises:

[0142] A first service metadata selection module is used for selecting service metadata associated with the target functional service from the object metadata of the object to be constructed according to the scene information to be tested, if the scene information to be tested fed back by the model construction demander is monitored before the object metadata is input into the functional test model for functional testing and the functional test result output by the functional test model is obtained;

[0143] Accordingly, the test result determination module 404 includes:

[0144] The test result determination unit is used to input the service metadata into the functional test model to perform a functional test and obtain a functional test result output by the functional test model.

[0145] Optionally, the device further comprises:

[0146] The second service metadata determination module is used to select test scenario information associated with the object to be constructed from at least one preset scenario information if the test scenario information fed back by the model construction demander is not monitored, and select service metadata associated with the target functional service from the object metadata of the object to be constructed based on the test scenario information.

[0147] Optionally, the number of services of the target function service is at least two;

[0148] Accordingly, the test result determination module 404 includes:

[0149] A target service test result determination unit, used for inputting the service metadata into the function test model, and each of the target function services performs a function test based on its own corresponding service metadata and function test conditions, to obtain its own test result corresponding to each of the target function services;

[0150] The function test result generating unit is used to generate the function test result including the self-test result of each of the target function services.

[0151] Optionally, the device further comprises:

[0152] A call count acquisition module, used to acquire the service call count and service response time of each reference function service within a preset time period;

[0153] A usage rate determination module is used to determine the service usage rate of the reference function service according to the number of service calls; and

[0154] A service performance determination module, used to determine the service performance of the reference function service according to the service response time;

[0155] A service update module is used to update the reference functional service according to the service usage rate and the service performance.

[0156] The object function testing device based on model building provided in the embodiment of the present invention can execute the object function testing method based on model building provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.

[0157] Embodiment 5

[0158] Figure 5 A schematic diagram of an electronic device 50 that can be used to implement an embodiment of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.

[0159] like Figure 5 As shown, the electronic device 50 includes at least one processor 51, and a memory connected to the at least one processor 51 in communication, such as a read-only memory (ROM) 52, a random access memory (RAM) 53, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 51 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 52 or the computer program loaded from the storage unit 58 to the random access memory (RAM) 53. In the RAM 53, various programs and data required for the operation of the electronic device 50 can also be stored. The processor 51, the ROM 52, and the RAM 53 are connected to each other via a bus 54. An input / output (I / O) interface 55 is also connected to the bus 54.

[0160] A number of components in the electronic device 50 are connected to the I / O interface 55, including: an input unit 56, such as a keyboard, a mouse, etc.; an output unit 57, such as various types of displays, speakers, etc.; a storage unit 58, such as a disk, an optical disk, etc.; and a communication unit 59, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 59 allows the electronic device 50 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0161] The processor 51 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 51 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The processor 51 executes the various methods and processes described above, such as the object function testing method based on model construction.

[0162] In some embodiments, the object function testing method based on model construction can be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 58. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 50 via the ROM 52 and / or the communication unit 59. When the computer program is loaded into the RAM 53 and executed by the processor 51, one or more steps of the object function testing method based on model construction described above can be performed. Alternatively, in other embodiments, the processor 51 can be configured to execute the object function testing method based on model construction in any other appropriate manner (for example, by means of firmware).

[0163] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0164] Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0165] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0166] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).

[0167] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0168] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.

[0169] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.

[0170] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for object function testing based on model building, characterized in that: include: Obtain object metadata and object attribute information of the object to be built from the model building demander; Determining an object virtual model of the object to be constructed; According to the object attribute information, based on the object virtual model, construct a functional test model of the object to be constructed; The object metadata is input into the functional test model to perform a functional test, and a functional test result output by the functional test model is obtained.

2. The method according to claim 1, characterized in that The step of constructing a functional test model of the object to be constructed based on the object virtual model according to the object attribute information includes: Selecting a target functional service from at least one pre-built reference functional service according to the object attribute information; The target functional service is bound to the object virtual model to obtain a functional test model corresponding to the object to be constructed.

3. The method according to claim 2, characterized in that Before inputting the object metadata into the functional test model to perform a functional test and obtaining a functional test result output by the functional test model, the method further includes: If the scenario information to be tested fed back by the model building demander is monitored, then according to the scenario information to be tested, service metadata associated with the target functional service is selected from the object metadata of the object to be built; Accordingly, the step of inputting the object metadata into the functional test model for functional testing to obtain the functional test result output by the functional test model includes: The service metadata is input into the functional test model to perform functional testing, and a functional test result output by the functional test model is obtained.

4. The method according to claim 2, characterized in that: The method further comprises: If the test scenario information fed back by the model construction demander is not monitored, the test scenario information associated with the object to be constructed is selected from at least one preset scenario information, and based on the test scenario information, the service metadata associated with the target functional service is selected from the object metadata of the object to be constructed.

5. The method according to claim 2, characterized in that: The number of services of the target function service is at least two; Accordingly, the inputting the service metadata into the functional test model to perform a functional test and obtaining a functional test result output by the functional test model includes: The service metadata is input into the functional test model, and each of the target functional services performs a functional test based on its own corresponding service metadata and functional test conditions, to obtain its own test results respectively corresponding to each of the target functional services; Generate a functional test result including a self-test result of each of the target functional services.

6. The method according to claim 2, characterized in that The method further comprises: Obtaining the number of service calls and service response time of each of the reference function services within a preset time period; Determining the service usage rate of the reference function service according to the number of service calls; and Determining the service performance of the reference functional service according to the service response time; The reference function service is updated according to the service usage rate and the service performance.

7. An object function testing device based on model construction, characterized in that: include: The object information acquisition module is used to obtain the object metadata and object attribute information of the object to be constructed of the model construction demander; A virtual model determination module, used to determine the object virtual model of the object to be constructed; A function model building module, used to build a function test model of the object to be built according to the object attribute information and based on the object virtual model; The test result determination module is used to input the object metadata into the functional test model to perform a functional test and obtain a functional test result output by the functional test model.

8. The device according to claim 7, characterized in that The functional model building module includes: A function service selection unit, configured to select a target function service from at least one pre-built reference function service according to the object attribute information; The function model construction unit is used to bind the target function service to the object virtual model to obtain the function test model corresponding to the object to be constructed.

9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can perform the object function testing method based on model building according to any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the object function testing method based on model building according to any one of claims 1 to 6 when executed.