Data processing method and device for batch complex expressions, electronic equipment, readable storage medium and chip
By designing a data processing method for batch complex expressions in an enterprise-level data analysis system, using the electrical connection between the expression operation task scheduling management module and the data interaction access module, the problem of insufficient efficiency and scalability of large-scale data processing is solved, and efficient batch expression calculation and data processing is achieved.
Patent Information
- Application Number
- CN202411830946.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-12
- Publication Date
- 2025-03-11
- Estimated Expiration
- 2044-12-12
AI Technical Summary
The efficiency and scalability of large-scale data processing processes in enterprise-level data analysis systems are insufficient, and it is difficult for the existing technology to effectively process complex expressions and large-scale data calculations.
A data processing method for batch complex expressions is designed. Through the electrical connection between the expression operation task scheduling management module and the data interaction access module, the syntax tree analysis of expressions, hierarchical sorting and the determination of arithmetic logical operation queues are realized, and batch expression calculation tasks are efficiently performed.
It improves the efficiency and logic of batch expression calculation processing, reduces redundant calculations and unnecessary input and output operations, and enhances the scalability and computing efficiency of the system.
Smart Images

Figure CN119597430A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method, device, electronic device, readable storage medium and chip for processing data of batch complex expressions. Background Art
[0002] There are often various data types and presentation forms in enterprise-level data analysis systems. It is usually necessary to convert these data into expressions and process them into the presentation form required by users or staff. This usually requires calculation and processing of different types of data according to large-scale expression rules, and expression rules are not just ordinary arithmetic and logical operations, but also nested variables and complex function operations. At present, Java source code interpreters (BeanShell, Bsh) are usually used as functional modules to calculate expressions, but this processing method is often only applicable to word operations or small-scale operations. It is not convenient to support multiple expressions input and multiple results output at the same time. In addition, due to the strong coupling relationship with Java code and insufficient expansion functions, it is difficult to meet the performance requirements and computing efficiency requirements of calculating a large number of expressions at the same time in large-scale data processing. Summary of the invention
[0003] The purpose of the embodiments of the present invention is to provide a method, device, electronic device, readable storage medium and chip for processing data of batch complex expressions, which can solve the problems of insufficient efficiency and scalability of large-scale data processing in enterprise-level data analysis systems.
[0004] In view of this, an embodiment of the first aspect of the present invention provides a method for processing data of batch complex expressions.
[0005] An embodiment of a second aspect of the present invention provides a data processing device.
[0006] An embodiment of a third aspect of the present invention provides a computing system.
[0007] An embodiment of a fourth aspect of the present invention provides an electronic device.
[0008] An embodiment of a fifth aspect of the present invention provides a readable storage medium.
[0009] An embodiment of the sixth aspect of the present invention provides a chip.
[0010] In order to achieve the above-mentioned purpose, an embodiment of the first aspect of the present invention provides a data processing method for batch complex expressions, which is used in a computing system. The computing system includes: an expression computing task scheduling management module and a data interactive access module. The expression task scheduling management module and the data interactive access module are electrically connected. The data processing method for batch complex expressions includes: obtaining a batch expression data set, which includes at least one expression; determining a syntax tree corresponding to the expression; hierarchically sorting the syntax tree according to the expression computing task scheduling management module to determine a computing task layer, which includes a first task layer and at least one secondary task layer; inputting the computing task layer into a data interactive access module cache; extracting the computing task layer from the data interactive access module, and determining an arithmetic logic operation queue according to the hierarchical order; performing operations corresponding to at least one expression according to the arithmetic logic operation queue, determining the operation result, and inputting the operation result into the data interactive access module for storage.
[0011] The data processing method for batch complex expressions proposed by the present invention is applied to the computing system of enterprise-level data analysis. The computing system mainly includes an expression computing task scheduling management module and a data interactive access module. The expression task scheduling management module and the data interactive access module are electrically connected, that is, the execution process of the data access module depends on the output of the expression task scheduling management module. The expression computing task scheduling management module is mainly used to parse the expression topological relationship network generated by the module, and perform vertex activity network (Activity OnVertex, AOV) hierarchical sorting on the topological relationship network of at least one expression; the data interactive access module is mainly used to cache the write-back data of each module in the computing system, and store the data using data structures such as queues, stacks, hash tables, etc. according to the different needs of the corresponding modules. A set of specific expression definition specifications (Domain Specific Language, DSL) is defined by the computing system, batch expressions are parsed, an abstract syntax analysis tree corresponding to the expression is generated, the topological relationship of the batch expression is determined according to the abstract syntax analysis tree, thereby determining the reference relationship between at least one expression in the batch expression and the corresponding expression, and batch computing tasks are processed in batches and hierarchical operations. Specifically, a batch expression data set input by the caller into the system is obtained from the operation system, and the batch expression data set includes at least one expression that needs to be calculated; based on the syntax parsing technology, at least one expression received by the operation system is parsed into an abstract syntax tree (abstract syntax code, AST), that is, a syntax tree corresponding to the expression, AST is a tree representation of the abstract syntax structure of the source code, and each node on the tree represents a structure in the source code, that is, a variable or parameter in the expression; the variables or parameters in the abstract syntax tree are hierarchically sorted according to AOV through the expression operation task scheduling management module, and the execution order of the calculation tasks of the variables or parameters in at least one expression, that is, the operation task layer, is determined. Among them, the operation task layer is divided into a first task layer and at least one secondary task layer according to the execution order. The variables or parameters corresponding to the expressions in the first task layer do not need to rely on other expressions for calculation, and as independent expressions, they need to correspond to the operation logic of the expressions; the secondary task layer includes at least one upper task layer and at least one lower task layer. The variables or parameters in the upper task layer depend on the operation results of the expressions in the lower task layer during the operation process; after determining the operation task layer, the operation task layer results are cached in the data interaction access module in hierarchical order for use by subsequent operation tasks.Determine the logical order corresponding to the first task layer, at least one upper task layer and at least one lower task from the calculation task layer cached in the data interaction access module, that is, the hierarchical order, and determine the arithmetic logic operation queue according to the hierarchical order, and execute the calculation logic corresponding to the expression according to the order of the queue, that is, perform calculation operations or call function operations on the expressions one by one according to the arithmetic logic operation queue, each calculation operation will read the corresponding calculation result from the result temporary storage stack, and when the current expression operation is executed, the result will be stored in the result record hash table of the data interaction access module, and all execution results will be returned to the caller.
[0012] Among them, at least one expression to be calculated in the batch expression data set may be an expression that is interrelated and corresponds to the same solution, or may be an independent expression that corresponds to multiple solutions and is not interrelated with each other.
[0013] It can be understood that by generating an expression topological relationship network through the expression operation task scheduling management module and performing AOV hierarchical sorting on the topological relationship network of at least one expression, expression calculation tasks can be run in batches, redundant calculation processes can be eliminated, and repeated calculation of the same operation logic can be avoided, thereby improving the logic of the operation system in the process of batch expression operation processing; and the data of each module in the operation system is cached or written back through the data interaction access module, and the data in the data interaction access module is extracted when the expression operation is required, thereby reducing unnecessary input / output (I / O) operations in the expression calculation process, thereby improving the efficiency of expression operation.
[0014] In the above technical solution, determining the syntax tree corresponding to the expression includes: determining parameter call information corresponding to the expression; determining the variable reference relationship of at least one parameter in the expression according to the parameter call information; determining the operation queue corresponding to the expression according to the variable reference relationship; caching the variable reference relationship and the operation queue corresponding to the expression in a data interaction access module; and determining the syntax tree according to the variable reference relationship and the operation queue.
[0015] In this technical solution, parsing one or more received expressions into an AST abstract syntax tree specifically includes: determining the call information corresponding to the variables or parameters in at least one expression, that is, the calling situation of the variables or parameters in the expression in other expressions in the batch expression data set, for example: the result parameter in the expression is used as the variable of other expressions in the batch expression data set, that is, the result parameter in the expression is called by the corresponding expression, and the operation system determines the reference relationship between the variables or parameters in each expression according to the parameter calling information; and determines the operation operation queue corresponding to the expression, that is, the operation logic corresponding to the parameters or variables included in the expression and the function operations required; determines the AST abstract syntax tree corresponding to the batch expression data set according to the variable reference relationship between at least one expression and the operation operation queue corresponding to the expression.
[0016] In the above technical scheme, the syntax tree is hierarchically sorted according to the expression operation task scheduling management module, and determining the operation task layer includes: obtaining the syntax tree; determining the topological relationship parameters corresponding to the syntax tree; determining at least one single expression and a sub-expression queue corresponding to the single expression according to the topological relationship parameters; determining the first task layer according to at least one single expression; determining at least one secondary task layer according to the sub-expression queue; and determining the operation task layer according to the first task layer and at least one secondary task layer.
[0017] In this technical solution, the topological relationship network of expressions in the syntax tree, that is, the topological relationship parameters, is determined according to the AST abstract syntax tree, and at least one expression is sorted in AOV layers according to the topological relationship parameters, and the operation task layer is determined according to the variable reference relationship between the expressions in the batch expression data set, wherein a single expression indicates that the expression has no reference relationship with other expressions in the batch expression data set, that is, the variables or parameters in the single expression are not associated with the variables or parameters in other expressions, the single expression corresponds to the first task layer, and the expressions in the first task layer do not need to rely on other expressions in the batch expression data set for calculation; the variables or parameters of the expressions in the sub-expression queue are all associated with other expressions in the batch expression data set, that is, the calculation of the expressions in the sub-expression queue depends on the calculation results of other expressions in the batch expression data set, and at least one expression in the sub-expression queue corresponds to the secondary task layer, and the operation task layer is determined according to the secondary task layer and the first task layer.
[0018] It can be understood that by dividing batch computing tasks into layers and rationally arranging the computing tasks of the computing system, redundant computing processes can be eliminated and operating efficiency can be improved.
[0019] In the above technical scheme, the operation task layer is extracted from the data interaction access module, and the arithmetic logic operation queue is determined according to the hierarchical order, including: determining the single expression in the first task layer as the first operation priority; determining the first sub-expression and the second sub-expression in the sub-expression queue according to the operation operation queue, and the second sub-expression includes the result of the first sub-expression; determining at least one first sub-expression as the second operation priority, and at least one second sub-expression as the third operation priority; determining the arithmetic logic operation queue according to the hierarchical order, and the hierarchical order includes the first operation priority, the second operation priority and the third operation priority.
[0020] In this technical solution, by logically sorting the expressions in the operation task layer, the calculation task is arranged to determine the arithmetic logic operation queue corresponding to the batch expression data set. Specifically, firstly, a single expression that is not associated with other expressions in the batch expression data set is calculated, that is, the single expression in the first task layer is determined as the first operation priority; the first sub-expression and the second sub-expression in the sub-expression queue are determined according to the expression variable reference relationship corresponding to the operation operation queue, that is, the result parameter of the first sub-expression is the variable or parameter in the second sub-expression, or the result parameter of the first sub-expression is related to the variable or parameter in the second sub-expression, and the operation of the second sub-expression depends on the result of the first sub-expression, and the operation logic of at least one first sub-expression is determined to be before the operation logic of at least one second sub-expression, and the operation priority of the first sub-expression is higher than the operation priority of the second sub-expression, that is, at least one first sub-expression is determined to be the second operation priority, and at least one second sub-expression is determined to be the third operation priority, and the arithmetic logic operation queue is determined according to the logical hierarchy order of the first operation priority, the second operation priority and the third operation priority, and the system will execute the corresponding operation logic according to the order of the queue to improve the operation logic.
[0021] In the above technical scheme, an operation corresponding to at least one expression is performed according to an arithmetic logic operation queue, and determining the operation result includes: obtaining an arithmetic logic operation queue corresponding to the expression from a data interaction access module; determining at least one function processing method in the arithmetic logic operation queue; determining a function call type corresponding to the function processing method, the function call type includes a first call type and a second call type; determining application parameters corresponding to the first call type; determining external interface parameters corresponding to the second call type; and determining the operation result according to the application parameters and the external interface parameters.
[0022] In this technical solution, the arithmetic logic operation queue corresponding to the expression is obtained in the data interactive access module, the corresponding operation logic is executed in the order of the queue, the function in each expression is processed, and the operation result of the batch expression data set input by the caller is determined. In the process of determining the operation operation queue, the operation logic and the function operation required to be used corresponding to the parameters or variables included in at least one expression in the batch expression data set have been determined, and the function processing method required to be used for the batch expression data set is determined according to the function operation required to be used for the expression determined in the logic operation queue, and the corresponding function processing module is determined to exist in the system according to the function processing method. When the corresponding function processing module exists in the system, the function call type is determined to be the first call type; when the corresponding function processing module does not exist in the system, the function call type is determined to be the second call type, and the external interface is required to obtain the corresponding function processing module to process the function. That is, the form of the corresponding function processing module is obtained through the external interface, the factory mode of function processing is determined, and the corresponding function processing module can be configured for different operation logics, so as to improve the scalability of the operation business, achieve high cohesion and low coupling, and enable the operation system to adapt to multiple business scenarios.
[0023] An embodiment of the second aspect of the present invention provides a data processing device, which includes: an acquisition unit, used to acquire a batch expression data set, the batch expression data set including at least one expression; a parsing unit, used to determine a syntax tree corresponding to the expression; a sorting unit, used to hierarchically sort the syntax tree according to the expression operation task scheduling management module, and determine the operation task layer; a cache unit, used to input the operation task layer into the data interaction access module cache; a logic unit, used to extract the operation task layer from the data interaction access module, and determine the arithmetic logic operation queue according to the hierarchical order; a processing unit, used to perform operations corresponding to at least one expression according to the arithmetic logic operation queue, determine the operation result, and input the operation result into the data interaction access module for storage.
[0024] According to the data processing device provided by the present invention, a data processing method for batch complex expressions is implemented, and expression parsing, parameter reference extraction, external interface function extraction, computing task planning and execution are realized, so that the execution efficiency and scalability of the data processing method for batch expressions are improved, in order to make the data processing method clearer. Specifically, the batch expression data set input into the system by the caller is obtained through the acquisition unit; the parsing unit parses at least one expression received by the operation system into an abstract syntax tree (abstract syntax code, AST), that is, a syntax tree corresponding to the expression based on the syntax parsing technology; the sorting unit determines the execution order of the computing tasks of the variables or parameters in at least one expression by hierarchically sorting the variables or parameters in the abstract syntax tree, that is, the computing task layer. The cache unit caches or writes back the data of each module in the operation system, and extracts the data in the data interaction access module when the expression operation needs it; the logic unit arranges the calculation tasks to determine the arithmetic logic operation queue corresponding to the batch expression data set by logically sorting the expressions in the operation task layer; the processing unit executes the corresponding operation logic according to the arithmetic logic operation queue corresponding to the expression in the order of the queue, processes the functions in each expression, determines the operation result corresponding to the batch expression data set input by the caller, stores the operation result in the data interaction access module and returns it to the caller.
[0025] The embodiment of the third aspect of the present invention provides a computing system, which includes: an expression parsing front-end module, an expression computing task scheduling management module, an expression computing execution module and a data interactive access module, wherein the expression parsing front-end module and the expression computing task scheduling management module are electrically connected, that is, the execution process of the expression computing task scheduling management module depends on the output of the expression parsing front-end module; the expression computing task scheduling management module and the expression computing execution module are electrically connected, that is, the execution process of the expression computing execution module depends on the output of the expression computing task scheduling management module; the expression computing task scheduling management module and the data interactive access module are electrically connected, that is, the execution process of the data interactive access module depends on the output of the expression computing task scheduling management module; the expression computing execution module and the data interactive access module are electrically connected, that is, the execution process of the data interactive access module depends on the output of the expression computing execution module; the expression parsing front-end module is used to determine a syntax tree corresponding to an expression; the expression computing execution module is used to extract a computing task layer from the data interactive access module and determine an arithmetic logic operation queue according to the hierarchical order; perform operations corresponding to at least one expression according to the arithmetic logic operation queue, determine the operation result, and input the operation result into the data interactive access module for storage; and a data processing device as in the second aspect.
[0026] By decoupling expression parsing and expression scheduling execution through the operation system, expression parsing and computing task execution are separated. That is, the front-end (expression parsing front-end module) and back-end (expression operation task scheduling management module and data interaction access module) of the expression processing business are separated to improve the reusability of the formula parsing end and the computing task execution end. This allows the operation system to adapt to multiple business scenarios and improve the scalability of the operation business. It only needs to add different function processing logic to be integrated, thus achieving full decoupling of data operation and function business logic.
[0027] An embodiment of the fourth aspect of the present invention provides an electronic device, which includes a processor, a memory, and a program or instruction stored in the memory and executable on the processor, and when the program or instruction is executed by the processor, the steps of the method of the first aspect are implemented.
[0028] An embodiment of the fifth aspect of the present invention provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method of the first aspect are implemented.
[0029] An embodiment of the sixth aspect of the present invention provides a chip, the chip includes a processor and a communication interface, the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the steps of the method of the first aspect.
[0030] Additional aspects and advantages of the present invention will become apparent from the following description or may be learned by practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 A schematic flow chart of a method for processing data of complex expressions in batches according to an embodiment of the present application is shown; Figure 2 A partial flow chart of a method for processing data of complex expressions in batches according to an embodiment of the present application is shown; Figure 3 A partial flow chart of a method for processing data of complex expressions in batches according to an embodiment of the present application is shown; Figure 4 A partial flow chart of a method for processing data of complex expressions in batches according to an embodiment of the present application is shown; Figure 5 A partial flow chart of a method for processing data of complex expressions in batches according to an embodiment of the present application is shown; Figure 6 A schematic block diagram of the structure of a data processing device according to an embodiment of the present application is shown; Figure 7A schematic structural block diagram of an electronic device according to an embodiment of the present application is shown; Figure 8 A schematic structural block diagram of a computing system according to an embodiment of the present application is shown; Fig. 9 A schematic diagram of expression parsing according to an embodiment of the present application is shown; Fig.10 A schematic diagram of generating a computing task execution order according to an embodiment of the present application is shown; Fig.11 A schematic diagram of the running order of batch expression operations according to an embodiment of the present application is shown.
[0032] in, Figures 6 to 8 The corresponding relationship between the reference numerals and the component names is as follows: 900: data processing device; 902: acquisition unit; 904: parsing unit; 906: sorting unit; 908: cache unit; 910: editing unit; 912: processing unit; 1000: electronic device; 1109: memory; 1110: processor; 3000: operation system; 3002: expression parsing front-end module; 3004: expression operation task scheduling management module; 3006: expression operation execution module; 3008: data interaction access module. DETAILED DESCRIPTION
[0033] In order to more clearly understand the above-mentioned purposes, features and advantages of the embodiments of the present invention, the embodiments of the present invention are further described in detail below in conjunction with the accompanying drawings and specific implementation methods. It should be noted that the embodiments of the present application and the features in the embodiments can be combined with each other without conflict.
[0034] In the following description, many specific details are set forth to facilitate a full understanding of the present application. However, the embodiments of the present invention may also be implemented in other ways different from those described herein. Therefore, the scope of protection of the present application is not limited to the specific embodiments disclosed below.
[0035] The following is combined with Figures 1 to 11 , through specific embodiments and their application scenarios, the data processing method, device, electronic device, readable storage medium and chip for batch complex expressions provided in the embodiments of the present application are described in detail.
[0036] This embodiment provides a method for processing data of batch complex expressions, which is used in a computing system. The computing system includes: an expression computing task scheduling management module and a data interactive access module. The expression task scheduling management module and the data interactive access module are electrically connected, such as Figure 1 As shown, the data processing method for batch complex expressions includes: Step S100: obtaining a batch expression data set, wherein the batch expression data set includes at least one expression; Step S102: Determine a syntax tree corresponding to the expression; Step S104: hierarchically sorting the syntax tree according to the expression operation task scheduling management module to determine an operation task layer, where the operation task layer includes a first task layer and at least one secondary task layer; Step S106: inputting the computing task layer into the data interactive access module cache; Step S108: extracting the operation task layer from the data interactive access module, and determining the arithmetic logic operation queue according to the layer order; Step S110: performing an operation corresponding to at least one expression according to the arithmetic logic operation queue, determining the operation result, and inputting the operation result into the data interactive access module for storage.
[0037] The data processing method for batch complex expressions proposed by the present invention is applied to the computing system of enterprise-level data analysis. The computing system mainly includes an expression computing task scheduling management module and a data interactive access module. The expression computing task scheduling management module and the data interactive access module are electrically connected. The expression computing task scheduling management module is mainly used to analyze the expression topological relationship network generated by the module, and perform vertex activity network (AOV) hierarchical sorting on the topological relationship network of at least one expression; the data interactive access module is mainly used to cache the write-back data of each module in the computing system, and store the data using data structures such as queues, stacks, and hash tables according to the different needs of the corresponding modules. A set of specific expression definition specifications (Domain Specific Language, DSL) is defined by the computing system, batch expressions are parsed, an abstract syntax analysis tree corresponding to the expression is generated, the topological relationship of the batch expression is determined according to the abstract syntax analysis tree, thereby determining the reference relationship between at least one expression in the batch expression and the corresponding expression, and batch computing tasks are processed in batches and hierarchical operations. Specifically, a batch expression data set input by the caller into the system is obtained from the operation system, and the batch expression data set includes at least one expression that needs to be calculated; based on the syntax parsing technology, at least one expression received by the operation system is parsed into an abstract syntax tree (abstract syntax code, AST), that is, a syntax tree corresponding to the expression, AST is a tree representation of the abstract syntax structure of the source code, and each node on the tree represents a structure in the source code, that is, a variable or parameter in the expression; the variables or parameters in the abstract syntax tree are hierarchically sorted according to AOV through the expression operation task scheduling management module, and the execution order of the calculation tasks of the variables or parameters in at least one expression, that is, the operation task layer, is determined. Among them, the operation task layer is divided into a first task layer and at least one secondary task layer according to the execution order. The variables or parameters corresponding to the expressions in the first task layer do not need to rely on other expressions for calculation, and as independent expressions, they need to correspond to the operation logic of the expressions; the secondary task layer includes at least one upper task layer and at least one lower task layer. The variables or parameters in the upper task layer depend on the operation results of the expressions in the lower task layer during the operation process; after determining the operation task layer, the operation task layer results are cached in the data interaction access module in hierarchical order for use by subsequent operation tasks.Determine the logical order corresponding to the first task layer, at least one upper task layer and at least one lower task from the calculation task layer cached in the data interaction access module, that is, the hierarchical order, and determine the arithmetic logic operation queue according to the hierarchical order, and execute the calculation logic corresponding to the expression according to the order of the queue, that is, perform calculation operations or call function operations on the expressions one by one according to the arithmetic logic operation queue, each calculation operation will read the corresponding calculation result from the result temporary storage stack, and when the current expression operation is executed, the result will be stored in the result record hash table of the data interaction access module, and all execution results will be returned to the caller.
[0038] Among them, at least one expression to be calculated in the batch expression data set may be an expression that is interrelated and corresponds to the same solution, or may be an independent expression that corresponds to multiple solutions and is not interrelated with each other.
[0039] It can be understood that by generating an expression topological relationship network through the expression operation task scheduling management module and performing AOV hierarchical sorting on the topological relationship network of at least one expression, expression calculation tasks can be run in batches, redundant calculation processes can be eliminated, and repeated calculation of the same operation logic can be avoided, thereby improving the logic of the operation system in the process of batch expression operation processing; and the data of each module in the operation system is cached or written back through the data interaction access module, and the data in the data interaction access module is extracted when the expression operation is required, thereby reducing unnecessary input / output (I / O) operations in the expression calculation process, thereby improving the efficiency of expression operation.
[0040] In one embodiment, optionally, Figure 2 As shown, determining the syntax tree corresponding to the expression includes: Step S1022: Determine parameter call information corresponding to the expression; Step S1024: determining a variable reference relationship of at least one parameter in the expression according to the parameter call information; Step S1026: determining the operation queue corresponding to the expression according to the variable reference relationship; Step S1028: Cache the variable reference relationship and the operation queue corresponding to the expression into the data interactive access module; Step S1030: Determine a syntax tree according to the variable reference relationship and the calculation operation queue.
[0041] In this technical solution, parsing one or more received expressions into an AST abstract syntax tree specifically includes: determining the call information corresponding to the variables or parameters in at least one expression, that is, the calling situation of the variables or parameters in the expression in other expressions in the batch expression data set, for example: the result parameter in the expression is used as the variable of other expressions in the batch expression data set, that is, the result parameter in the expression is called by the corresponding expression, and the operation system determines the reference relationship between the variables or parameters in each expression according to the parameter calling information; and determines the operation operation queue corresponding to the expression, that is, the operation logic corresponding to the parameters or variables included in the expression and the function operations required; determines the AST abstract syntax tree corresponding to the batch expression data set according to the variable reference relationship between at least one expression and the operation operation queue corresponding to the expression.
[0042] In a specific embodiment, the received batch expressions are parsed into an AST abstract syntax tree such as Fig. 9 As shown in the figure, a batch expression data set is obtained, where the batch expressions include: [D]=IF([A]>=[B],[A]+[B],[B]+[C]);[A]=([A1]+[A2]+[A3]);[B]=([A]+[A2]+[A3]);[B1]=([A1]+[A2]+[A3]);[C]=([A]+[B]+[C1]);[A1]=UDEF_INST("","","AA1");[A2]=UDEF_INST("","","AA2");[A3]=UDEF_INST("","","AA3");[C1]=UDEF_INST("","","CC1") and other function expressions. The expression parsing front-end module is used to parse the expression and determine the variable reference relationship structure, that is, variable A is referenced by variable D, variable A is referenced by variables B and C, and variable The relationship between variable B being referenced by variables D and variable C, variable A1 being referenced by variables A and variable B1, variable A3 being referenced by variables A and variable B1, variable A2 being referenced by variables A and variable B1, and variable C1 being referenced by variable C; and determining the function operation queue required for variable D, the operation operation queue including: operation function IdxNodeOp, operation function IdxNodeOp, operation function AddNodeOp, operation function IdxCa1NodeOp, operation function IdxCa1NodeOp, operation function AddNodeOp, operation function FunctionCa1NodeOp and operation function AssignNodeOp; determining the AST abstract syntax tree corresponding to the batch expression data set through the variable reference relationship between at least one expression and the operation operation queue corresponding to the expression.
[0043] In one embodiment, optionally, Figure 3 As shown, the syntax tree is hierarchically sorted according to the expression operation task scheduling management module, and the operation task layer is determined to include: Step S1042: Obtain a syntax tree; Step S1044: determining topological relationship parameters corresponding to the syntax tree; Step S1046: determining at least one single expression and a sub-expression queue corresponding to the single expression according to the topological relationship parameters; Step S1048: determining a first task layer according to at least one single expression; Step S1050: determining at least one secondary task layer according to the sub-expression queue; Step S1052: Determine a computing task layer according to the first task layer and at least one secondary task layer.
[0044] In this technical solution, the topological relationship network of expressions in the syntax tree, that is, the topological relationship parameters, is determined according to the AST abstract syntax tree, and at least one expression is sorted in AOV layers according to the topological relationship parameters, and the operation task layer is determined according to the variable reference relationship between the expressions in the batch expression data set, wherein a single expression indicates that the expression has no reference relationship with other expressions in the batch expression data set, that is, the variables or parameters in the single expression are not associated with the variables or parameters in other expressions, the single expression corresponds to the first task layer, and the expressions in the first task layer do not need to rely on other expressions in the batch expression data set for calculation; the variables or parameters of the expressions in the sub-expression queue are all associated with other expressions in the batch expression data set, that is, the calculation of the expressions in the sub-expression queue depends on the calculation results of other expressions in the batch expression data set, and at least one expression in the sub-expression queue corresponds to the secondary task layer, and the operation task layer is determined according to the secondary task layer and the first task layer.
[0045] It can be understood that by dividing batch computing tasks into layers and rationally arranging the computing tasks of the computing system, redundant computing processes can be eliminated and operating efficiency can be improved.
[0046] In a specific embodiment, the computing task execution order generates a topological relationship network and corresponding topological relationship parameters such as Fig.10As shown, according to the AST abstract syntax tree, the AOV graph analysis results show that: variable A1 is referenced by variable B1 and variable A; variable A2 is referenced by variable B1, variable A and variable B; variable A3 is referenced by variable B1, variable A and variable B; variable A is referenced by variable D, variable C and variable B; variable B is referenced by variable D and variable C; variable C1 is referenced by variable C. Among them, variables A1, variable A2, variable A3 and variable C1 do not rely on other expressions in the batch expression data set for calculation, and are single expressions, that is, corresponding to the first task layer. Variables A, variable B1, variable B, variable D, and variable C all reference variables or parameters in other expressions, as sub-expression queues, divided into secondary task layers, and according to the reference relationship, variables A and variable B1 are determined to be the second-level task layer, variable B is the third-level task layer, and variables D and variable C are the fourth-level task layer.
[0047] In one embodiment, optionally, Figure 4 As shown, the operation task layer is extracted from the data interactive access module, and the arithmetic logic operation queue is determined according to the hierarchical order, including: Step S1082: Determine that the single expression in the first task layer is the first operation priority; Step S1084: determining the first sub-expression and the second sub-expression in the sub-expression queue according to the operation queue, wherein the second sub-expression includes the result of the first sub-expression; Step S1086: Determine that at least one first sub-expression is of the second operation priority, and at least one second sub-expression is of the third operation priority; Step S1088: Determine the arithmetic logic operation queue according to the hierarchical order.
[0048] In this technical solution, by logically sorting the expressions in the operation task layer, the calculation task is arranged to determine the arithmetic logic operation queue corresponding to the batch expression data set. Specifically, firstly, a single expression that is not associated with other expressions in the batch expression data set is calculated, that is, the single expression in the first task layer is determined as the first operation priority; the first sub-expression and the second sub-expression in the sub-expression queue are determined according to the expression variable reference relationship corresponding to the operation operation queue, that is, the result parameter of the first sub-expression is the variable or parameter in the second sub-expression, or the result parameter of the first sub-expression is related to the variable or parameter in the second sub-expression, and the operation of the second sub-expression depends on the result of the first sub-expression, and the operation logic of at least one first sub-expression is determined to be before the operation logic of at least one second sub-expression, and the operation priority of the first sub-expression is higher than the operation priority of the second sub-expression, that is, at least one first sub-expression is determined to be the second operation priority, and at least one second sub-expression is determined to be the third operation priority, and the arithmetic logic operation queue is determined according to the logical hierarchy order of the first operation priority, the second operation priority and the third operation priority, and the system will execute the corresponding operation logic according to the order of the queue to improve the operation logic.
[0049] In one embodiment, optionally, Figure 5 As shown, performing an operation corresponding to at least one expression according to the arithmetic logic operation queue, and determining the operation result includes: Step S1102: Obtaining the arithmetic logic operation queue corresponding to the expression from the data interaction access module; Step S1104: determining at least one function processing mode in the arithmetic logic operation queue; Step S1106: determining a function call type corresponding to the function processing mode, where the function call type includes a first call type and a second call type; Step S1108: Determine application parameters corresponding to the first call type; Step S1110: determining external interface parameters corresponding to the second call type; Step S1112: Determine the calculation result according to the application parameters and the external interface parameters.
[0050] In this technical solution, the arithmetic logic operation queue corresponding to the expression is obtained in the data interactive access module, the corresponding operation logic is executed in the order of the queue, the function in each expression is processed, and the operation result of the batch expression data set input by the caller is determined. In the process of determining the operation operation queue, the operation logic and the function operation required to be used corresponding to the parameters or variables included in at least one expression in the batch expression data set have been determined, and the function processing method required to be used for the batch expression data set is determined according to the function operation required to be used for the expression determined in the logic operation queue, and the corresponding function processing module is determined to exist in the system according to the function processing method. When the corresponding function processing module exists in the system, the function call type is determined to be the first call type; when the corresponding function processing module does not exist in the system, the function call type is determined to be the second call type, and the external interface is required to obtain the corresponding function processing module to process the function. That is, the form of the corresponding function processing module is obtained through the external interface, the factory mode of function processing is determined, and the corresponding function processing module can be configured for different operation logics, so as to improve the scalability of the operation business, achieve high cohesion and low coupling, and enable the operation system to adapt to multiple business scenarios.
[0051] like Figure 6 As shown, an embodiment of the present invention provides a data processing device 900, which includes: an acquisition unit 902, used to acquire a batch expression data set, wherein the batch expression data set includes at least one expression; a parsing unit 904, used to determine a syntax tree corresponding to the expression; a sorting unit 906, used to hierarchically sort the syntax tree according to the expression operation task scheduling management module, and determine the operation task layer; a cache unit 908, used to input the operation task layer into the data interaction access module cache; a logic unit 910, used to extract the operation task layer from the data interaction access module, and determine the arithmetic logic operation queue according to the hierarchical order; a processing unit 912, used to perform an operation corresponding to at least one expression according to the arithmetic logic operation queue, determine the operation result, and input the operation result into the data interaction access module for storage.
[0052] The data processing device 900 provided according to the present invention implements a data processing method for batch complex expressions, realizes expression parsing, parameter reference extraction, external interface function extraction, computing task planning and execution, thereby improving the execution efficiency and scalability of the data processing method for batch expressions, in order to make the data processing method clearer. Specifically, the acquisition unit 902 acquires the batch expression data set input into the system by the caller; the parsing unit 904 parses at least one expression received by the operation system into an abstract syntax tree based on the syntax parsing technology, that is, the syntax tree corresponding to the expression; the sorting unit 906 determines the execution order of the calculation tasks of the variables or parameters in at least one expression, that is, the operation task layer, by hierarchically sorting the variables or parameters in the abstract syntax tree; the cache unit 908 caches or writes back the data of each module in the operation system, and extracts the data in the data interaction access module when the expression operation is required; the logic unit 910 arranges the calculation tasks to determine the arithmetic logic operation queue corresponding to the batch expression data set by logically sorting the expressions in the operation task layer; the processing unit 912 executes the corresponding operation logic according to the arithmetic logic operation queue corresponding to the expression in the order of the queue, processes the functions in each expression, determines the operation result corresponding to the batch expression data set input by the caller, stores the operation result in the data interaction access module and returns it to the caller.
[0053] like Figure 8As shown, an embodiment of the present invention provides a computing system 3000, and the computing system 3000 includes: an expression parsing front-end module 3002, an expression computing task scheduling management module 3004, an expression computing execution module 3006 and a data interactive access module 3008, the expression parsing front-end module 3002 and the expression computing task scheduling management module 3004 are electrically connected, that is, the execution process of the expression computing task scheduling management module depends on the output of the expression parsing front-end module; the expression computing task scheduling management module 3004 and the expression computing execution module 3006 are electrically connected, that is, the execution process of the expression computing execution module depends on the output of the expression computing task scheduling management module; the expression computing task scheduling management module 3004 and the data interactive access module The mutual access modules 3008 are electrically connected, that is, the execution process of the data interactive access module depends on the output of the expression operation task scheduling management module; the expression operation execution module 3006 and the data interactive access module 3008 are electrically connected, that is, the execution process of the data interactive access module depends on the output of the expression operation execution module; the expression parsing front-end module 3002 is used to determine the syntax tree corresponding to the expression; the expression operation execution module 3006 is used to extract the operation task layer from the data interactive access module, and determine the arithmetic logic operation queue according to the hierarchical order; perform the operation corresponding to at least one expression according to the arithmetic logic operation queue, determine the operation result, and input the operation result to the data interactive access module for storage; such as the above-mentioned data processing device 900.
[0054] By decoupling expression parsing and expression scheduling execution through the computing system 3000, parsing expressions and executing computing tasks are separated, that is, the front end (expression parsing front end module 3002) and the back end (expression computing task scheduling management module 3004 and data interaction access module 3008) of the expression processing business are separated, thereby improving the reusability of the formula parsing end and the computing task execution end, allowing the computing system 3000 to adapt to multiple business scenarios and improve the scalability of the computing business. It only needs to add different function processing logics to be integrated, thereby achieving full decoupling of data computing and function business logic.
[0055] The expression parsing front-end module 3002 includes: lexical analysis (based on AST syntax analysis), syntax analysis (based on AST syntax analysis), syntax error checking analysis, reference extraction between expressions, generation of expression topological relationships, cell reference extraction, generation of intermediate expressions of cell area indicators, operation logic sequence extraction, custom function extraction and generation of arithmetic logic operation queue. The expression parsing front-end module 3002, based on syntax parsing technology, parses one or more received expressions into an AST abstract syntax tree, extracts the operation logic model and the relationship model of references between expressions according to the syntax tree, generates an arithmetic logic operation queue and an expression topological relationship network and caches them in the cache of the data interaction module; The expression calculation task scheduling management module 3004 includes: calling query custom functions to obtain data, topological sorting of expression calculation task scheduling, calling expression calculations one by one according to the hierarchical order, and managing and controlling calculation tasks. The expression calculation task scheduling management module 3004 is used to perform AOV hierarchical sorting on the expression topological relationship network generated by the parsing module, and sort the calculation task layer. The first layer of tasks does not need to rely on other calculations, and the upper layer calculation tasks rely on the lower layer calculation results. After calling the execution module in hierarchical order, the final results collected are cached in the calculation result cache of the data interaction module for use by subsequent layers of calculation tasks. The time complexity of this method is analyzed as follows: Assuming that there are n calculation parameters and e reference relationships, each calculation expression needs to be pushed and popped during the sorting process, so the time required is O(n). After each node is pushed into the stack, the relationship referenced by the calculation needs to be accessed. This is executed e times. In summary, the time complexity of this method is O(n+e). When all tasks are completed, the calculation results are collected and returned to the caller. This module will also convert the custom interface functions collected by the parser front end into SQL or noSQL database query statements, use the external data interface to perform batch queries on the statements and save them to the custom result cache of the data interaction module. The purpose of this is to reduce unnecessary I / O operations during calculations and improve efficiency. The expression operation execution module 3006 includes: an arithmetic operation module, a logic operation module, a single-task calculation intermediate result stack cache and a numerical conversion module, and can call at least one processing module in the external data through the factory mode, for example: a calculation function processing module, the calculation function processing module includes its own unified calculation function abstract factory, unified calculation function interface and IF calculation function implementation and other functions; a custom function processing module, the custom function processing module includes its own unified custom function abstract factory, unified custom function interface and UDEF_INST calculation function implementation and other functions, and the expression operation execution module can configure the corresponding operation processing module for different operation logics. The expression operation execution module 3006, according to the expression assignment variable name passed in by the scheduling module to the cache of the data interaction module, obtains the arithmetic logic operation queue generated by the expression parsing module, and executes the corresponding operation logic in the order of the queue, wherein the function processing method uses the factory mode, and the purpose of doing so is to achieve the design purpose of high cohesion and low coupling for the scalability of the business; The data interaction access module 3008 includes: report parameter collection and user-filled data access, expression collection and write-back, custom function data query and result cache, global variable calculation result cache and parsing result cache. The data interaction access module 3008 is used to cache the expression parsing module (i.e., expression parsing front-end module), the task scheduling module (i.e., expression calculation task scheduling management module) and the expression calculation execution module to exchange data and realize the function of writing back the calculation result with the caller. According to different needs, data structures such as queues, stacks, and hash tables are used respectively, and appropriate data structures are provided according to needs to improve the efficiency of data access.
[0056] In a specific embodiment, the data processing method for batch complex expressions proposed by the present invention is combined with a matching computing system to realize expression parsing, parameter reference extraction, external interface function extraction, computing task planning and execution, so that the execution efficiency and scalability of the data processing method for batch expressions are improved. In order to make the data processing method clearer, combined with Fig.11The running sequence diagram of the batch expression operation shown is used to specifically illustrate: according to the running order, the data processing method includes: 1. Batch expression input; 2. Batch expression string; 3. Return reference relationship, operation queue, external interface collection; 4. Record operation queue Hash table; 5. Return execution status; 6. AOV reference sorting; 7. Call external data interface; 8. Cache interface return data; 9. Return execution status; 10. Execute expression tasks in hierarchical order; 11. Execute single expression operation; 12. Get sub-expression queue; 13. Return the expression operation queue; 14. Get reference parameters or external interface results; 15. Return results; 16. Save operation results; 17. Return execution status; 18. Return execution status; 19. Collect batch expression calculation results; 20. Return batch expression calculation results; 21. Return batch results.
[0057] Specifically, the first step (i.e. Fig.11 As shown in 1): The calculation expression caller inputs the batch expression to be calculated into the expression calculation scheduling management module of the calculation system; the second step (i.e. Fig.11 2 to 3): the expression operation scheduling management module transmits the input expression to the expression parsing front-end module, and the expression parsing front-end module extracts the parameter call information and the operation operation queue and external interface function of each expression from the batch expression, and returns the result to the expression operation scheduling management module; the third step (i.e. Fig.11 4 to 5): the expression operation scheduling management module stores the operation operation queue data parsed by the expression parsing front-end module into the data interactive access module for subsequent use; the fourth step (i.e. Fig.11 6): The expression calculation task scheduling management module will return the parameters in the second step to the expression calculation scheduling management module and reference the AOV relationship diagram for hierarchical sorting. If the batch expression parameters currently being calculated have a circular dependency, it will prompt the calculation expression caller that a circular dependency exception has occurred. The fifth step (i.e. Fig.11 7 to 9): The expression operation task scheduling management module calls external data to obtain batches of external operation data at one time, and stores the obtained data in the data interactive access module to reduce the I / O in subsequent operations. This interface can be used to call external data by extending other interfaces; Step 6 (i.e. Fig.1110 to 18): The expression calculation task scheduling management module calls the expression calculation execution module to perform the expression calculation function in a hierarchical order. First, it needs to access the data interaction module to obtain the expression calculation queue, and then perform calculation operations or call function operations one by one according to the calculation queue. Each calculation operation will read the result of the calculation in the result temporary storage stack. When the current expression calculation is completed, the result is stored in the result record hash table of the data interaction module; Step 7 (i.e. Fig.11 19 to 21): When all expressions are executed, the expression operation task scheduling management module obtains all execution results from the data interaction access module and returns them to the calculation expression caller.
[0058] like Figure 7 As shown, an embodiment of the present application also provides an electronic device 1000, including a processor 1110, a memory 1109, and a program or instruction stored in the memory 1109 and executable on the processor 1110. When the program or instruction is executed by the processor 1110, the various processes of the embodiment of the above-mentioned batch complex expression data processing method are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0059] Optionally, processor 1110 is used to obtain a batch expression data set, which includes at least one expression; determine a syntax tree corresponding to the expression; hierarchically sort the syntax tree according to the expression operation task scheduling management module, and determine the operation task layer, which includes a first task layer and at least one secondary task layer; input the operation task layer into the data interaction access module cache; extract the operation task layer from the data interaction access module, and determine the arithmetic logic operation queue according to the hierarchical order; perform operations corresponding to at least one expression according to the arithmetic logic operation queue, determine the operation result, and input the operation result into the data interaction access module for storage.
[0060] Optionally, processor 1110 is also used to determine parameter call information corresponding to the expression; determine the variable reference relationship of at least one parameter in the expression based on the parameter call information; determine the operation queue corresponding to the expression based on the variable reference relationship; cache the variable reference relationship and the operation queue corresponding to the expression in the data interaction access module; determine the syntax tree based on the variable reference relationship and the operation queue.
[0061] Optionally, processor 1110 is also used to obtain a syntax tree; determine topological relationship parameters corresponding to the syntax tree; determine at least one single expression and a sub-expression queue corresponding to the single expression based on the topological relationship parameters; determine a first task layer based on at least one single expression; determine at least one secondary task layer based on the sub-expression queue; and determine an operation task layer based on the first task layer and at least one secondary task layer.
[0062] Optionally, processor 1110 is also used to determine that a single expression in the first task layer is the first operation priority; determine the first sub-expression and the second sub-expression in the sub-expression queue according to the operation operation queue, and the second sub-expression includes the result of the first sub-expression; determine at least one first sub-expression as the second operation priority, and at least one second sub-expression as the third operation priority; determine the arithmetic logic operation queue according to the hierarchical order, and the hierarchical order includes the first operation priority, the second operation priority and the third operation priority.
[0063] Optionally, processor 1110 is further used to obtain an arithmetic logic operation queue corresponding to an expression from a data interaction access module; determine at least one function processing method in the arithmetic logic operation queue; determine a function call type corresponding to the function processing method, the function call type including a first call type and a second call type; determine application parameters corresponding to the first call type; determine external interface parameters corresponding to the second call type; and determine a calculation result based on the application parameters and the external interface parameters.
[0064] The embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, each process of the above-mentioned batch complex expression data processing method embodiment is implemented, and the same technical effect can be achieved. In order to avoid repetition, it is not repeated here. In addition, the data storage capacity and data processing speed corresponding to the batch complex expression data processing method in the present application are improved by a readable storage medium.
[0065] A readable storage medium may be a tangible device that can retain and store instructions for use by an instruction execution device. A computer-readable storage medium may be an electronic storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the above devices, but is not limited thereto. A non-exhaustive list of more specific examples of computer-readable storage media includes: portable computer floppy disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), static random access memory (SRAM), portable compact disk read-only memory (CD-ROM), digital versatile disk (DVD), memory card, floppy disk, encoding mechanical device (such as a punched card or a groove with a raised structure with instructions recorded) and any suitable combination of the above devices. The computer-readable storage medium used herein should not be understood as a transmission signal itself, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium, or an electrical signal transmitted through a wire, etc.
[0066] The processor is the processor in the electronic device in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0067] The embodiment of the present application further provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled to the processor, the processor is used to run a program or instruction, implement the various processes of the above-mentioned batch complex expression data processing method embodiment, and can achieve the same technical effect, to avoid repetition, no further description is given here. In addition, the chip is used to improve the data processing speed corresponding to the batch complex expression data processing method in the present application.
[0068] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0069] According to the data processing method, device, electronic device, readable storage medium and chip for batch complex expressions provided by the present invention, the parsing, scheduling, execution and data access functions of batch expressions are divided into various execution modules for design, so that the efficiency of batch expression calculation and business expansion capabilities are greatly improved.
[0070] In the present invention, the terms "first", "second", and "third" are used for descriptive purposes only and should not be understood as indicating or implying relative importance; the term "plurality" refers to two or more, unless otherwise clearly defined. The terms "installed", "connected", "connected", "fixed", etc. should be understood in a broad sense. For example, "connected" can be a fixed connection, a detachable connection, or an integral connection; "connected" can be a direct connection or an indirect connection through an intermediate medium. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0071] In the description of the present invention, it is necessary to understand that the directions or positional relationships indicated by terms such as “upper”, “lower”, “left”, “right”, “front” and “back” are based on the directions or positional relationships shown in the accompanying drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or unit referred to must have a specific direction, be constructed and operated in a specific orientation, and therefore, cannot be understood as a limitation on the present invention.
[0072] In the description of this specification, the description of the terms "one embodiment", "some embodiments", "specific embodiments", etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.
[0073] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for processing data of batch complex expressions, characterized in that: Used in a computing system, the computing system includes: an expression computing task scheduling management module and a data interactive access module, the expression computing task scheduling management module and the data interactive access module are electrically connected, and the data processing method for batch complex expressions includes: Acquire a batch expression data set, wherein the batch expression data set includes at least one expression; determining a syntax tree corresponding to the expression; According to the expression operation task scheduling management module, the syntax tree is hierarchically sorted to determine an operation task layer, wherein the operation task layer includes a first task layer and at least one secondary task layer; Inputting the computing task layer into the data interaction access module cache; Extracting the operation task layer from the data interactive access module, and determining the arithmetic logic operation queue according to the hierarchical order; An operation corresponding to at least one of the expressions is performed according to the arithmetic logic operation queue, an operation result is determined, and the operation result is input into the data interactive access module for storage.
2. The data processing method for batch complex expressions according to claim 1, characterized in that: The determining a syntax tree corresponding to the expression comprises: Determining parameter call information corresponding to the expression; Determine a variable reference relationship of at least one parameter in the expression according to the parameter call information; Determine the operation queue corresponding to the expression according to the variable reference relationship; Cache the variable reference relationship and the operation queue corresponding to the expression in the data interactive access module; A syntax tree is determined according to the variable reference relationship and the calculation operation queue.
3. The data processing method for batch complex expressions according to claim 2, characterized in that: The step of hierarchically sorting the syntax tree according to the expression operation task scheduling management module to determine the operation task layer includes: Obtaining the syntax tree; Determining topological relationship parameters corresponding to the syntax tree; Determine at least one single expression and a sub-expression queue corresponding to the single expression according to the topological relationship parameters; Determining a first task layer according to at least one of the single expressions; Determining at least one secondary task layer according to the sub-expression queue; A computing task layer is determined according to the first task layer and at least one of the secondary task layers.
4. The data processing method for batch complex expressions according to claim 3 is characterized in that: The step of extracting the operation task layer from the data interactive access module and determining the arithmetic logic operation queue according to the hierarchical order includes: Determining that the single expression in the first task layer is a first operation priority; Determine a first sub-expression and a second sub-expression in the sub-expression queue according to the operation queue, wherein the second sub-expression includes a result of the first sub-expression; Determine at least one of the first sub-expressions as a second operation priority, and at least one of the second sub-expressions as a third operation priority; An arithmetic logic operation queue is determined according to a hierarchical order, wherein the hierarchical order includes the first operation priority, the second operation priority, and the third operation priority.
5. The method for processing data of complex expressions in batches according to any one of claims 1 to 4, characterized in that: The performing an operation corresponding to at least one of the expressions according to the arithmetic logic operation queue to determine the operation result includes: Obtaining the arithmetic logic operation queue corresponding to the expression from the data interaction access module; Determine at least one function processing mode in the arithmetic logic operation queue; Determine a function call type corresponding to the function processing mode, wherein the function call type includes a first call type and a second call type; determining application parameters corresponding to the first call type; determining external interface parameters corresponding to the second call type; The calculation result is determined according to the application parameter and the external interface parameter.
6. A data processing device, characterized in that: include: An acquisition unit, used for acquiring a batch expression data set, wherein the batch expression data set includes at least one expression; A parsing unit, configured to determine a syntax tree corresponding to the expression; A sorting unit, used to sort the syntax tree in layers according to the expression operation task scheduling management module to determine the operation task layer; A cache unit, used for inputting the computing task layer into the data interactive access module cache; A logic unit, used to extract the operation task layer from the data interactive access module and determine the arithmetic logic operation queue according to the layer order; The processing unit is used to perform an operation corresponding to at least one of the expressions according to the arithmetic logic operation queue, determine the operation result, and input the operation result to the data interactive access module for storage.
7. A computing system, characterized in that: It includes an expression parsing front-end module, an expression operation task scheduling management module, an expression operation execution module and a data interactive access module, wherein the expression parsing front-end module is electrically connected to the expression operation task scheduling management module, the expression operation task scheduling management module is electrically connected to the expression operation execution module, the expression operation task scheduling management module is electrically connected to the data interactive access module, and the expression operation execution module is electrically connected to the data interactive access module; The expression parsing front-end module is used to determine a syntax tree corresponding to the expression; The expression operation execution module is used to extract the operation task layer from the data interactive access module, and determine the arithmetic logic operation queue according to the layer order; perform the operation corresponding to at least one of the expressions according to the arithmetic logic operation queue, determine the operation result, and input the operation result into the data interactive access module for storage; The operation system further comprises the data processing device as claimed in claim 6.
8. An electronic device, characterized in that: It includes a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the data processing method for batch complex expressions as described in any one of claims 1 to 5.
9. A readable storage medium, characterized in that: The readable storage medium stores programs or instructions, and when the programs or instructions are executed by the processor, the steps of the data processing method for batch complex expressions as described in any one of claims 1 to 5 are implemented.
10. A chip, characterized in that: The chip includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the steps of the data processing method for batch complex expressions according to any one of claims 1 to 5.
Citation Information
Patent Citations
Program information issuing method and device, and electronic equipment
CN111880777A
Multi-rule matching method, device and equipment
CN113885880A
Code Generation Tool for Cloud-Native High-Performance Computing
US20220261227A1
Cited By
Finance report data processing system based on domain-specific language
CN121481695A