An artificial intelligence-based automated operator development method and system

By adopting an AI-based automated operator development method, the problems of information dispersion and reliance on human experience in operator development are solved, realizing an efficient and automated operator development process, improving operator execution efficiency and accuracy, and supporting multi-framework adaptation and flexibility.

CN122173065APending Publication Date: 2026-06-09四川华鲲振宇智能科技有限责任公司

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
四川华鲲振宇智能科技有限责任公司
Filing Date
2026-02-28
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

In the current operator development process, information is scattered and lacks unified organization. Relying on human experience makes it difficult to quickly determine the optimal solution. Code generation and verification are cumbersome and prone to compatibility issues. The lack of standardized testing mechanisms leads to low development efficiency and difficulty in guaranteeing accuracy.

Method used

An AI-based automated operator development method is adopted. Through information collection, parsing and storage, combined with AI algorithms, multiple rounds of parameter optimization and block strategy iteration are performed to generate operator code and documentation. It supports multi-channel uploading and multi-framework adaptation, and realizes full-process automation.

Benefits of technology

It significantly simplifies the development process, improves operator execution efficiency and computational accuracy, reduces resource consumption and transmission latency, enhances development flexibility and maintainability, and supports the efficient deployment of deep learning models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122173065A_ABST
    Figure CN122173065A_ABST
Patent Text Reader

Abstract

This invention discloses an automated operator development method and system based on artificial intelligence, belonging to the field of deep learning operator development. The method first collects relevant information such as operator names, mathematical formulas, and compatible frameworks. After classification, organization, parsing, and storage, it analyzes computational characteristics using artificial intelligence algorithms, optimizes parameters and partitioning strategies, and generates a NumPy-based algorithm demo to verify logic and accuracy. Then, it constructs operator code, test code, and documentation, adapts to deep learning frameworks as needed, compiles and deploys, and completes the closed loop through accuracy verification and optimization guidance. This method automates the entire operator development process, reduces manual intervention, lowers the development threshold, improves operator execution efficiency and computational accuracy, enhances adaptability to multiple hardware and frameworks, and provides strong support for the efficient deployment of deep learning models.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of deep learning operator development, and particularly to an automated operator development method and system based on artificial intelligence. Background Technology

[0002] With the rapid development of artificial intelligence technology, deep learning models are increasingly being applied in various fields such as industry, scientific research, and the internet. As the core computing unit of deep learning models, operators directly affect the model's execution efficiency, deployment flexibility, and computational accuracy, becoming a crucial link in supporting the implementation of deep learning technology. Currently, the operator development field has formed a diversified technological ecosystem, covering various deep learning frameworks, hardware chips with different architectures, and complex application scenario requirements. The industry employs various development models, including manual coding and development assisted by dedicated tools. Developers need to focus on core elements such as the mathematical operation logic of operators, hardware adaptation requirements, and framework calling specifications, while also considering additional requirements such as binary compatibility and scenario adaptability. Furthermore, with the iterative upgrades of chip technology and the continuous updates of framework versions, the demand for multi-hardware compatibility and multi-framework adaptation of operators is constantly increasing, driving operator development technology towards efficiency and standardization. Various auxiliary tools and optimization methods to simplify the development process are also gradually emerging, providing certain technical support for operator development.

[0003] Currently, numerous technical problems remain to be solved in operator development, directly impacting its efficiency and quality. At the information processing level, operator-related names, input / output definitions, mathematical formulas, and adaptation requirements are scattered and lack a unified classification, organization, parsing, and storage mechanism. This makes it difficult to obtain accurate and efficient data support for subsequent data analysis and code generation, increasing redundancy in the development process. At the parameter optimization and block-based strategy design level, existing technologies largely rely on developers' professional experience for manual adjustments, lacking systematic analysis and iterative optimization methods based on artificial intelligence algorithms. This makes it difficult to quickly determine the optimal solution for adapting to the target chip's cache structure and scenario requirements, consuming significant manpower and time costs and failing to guarantee optimal operator performance. At the code generation and verification level, algorithm logic verification, operator code writing, and framework adaptation code development must be completed manually. This process is cumbersome and prone to compatibility issues. Furthermore, the lack of standardized test code and documentation generation mechanisms affects the usability and maintainability of operators. At the level of accuracy verification and debugging, there is a lack of unified error calculation standards and verification processes. When the operator accuracy does not meet the standards, it is difficult to quickly locate the root cause of the problem and obtain a clear debugging path, resulting in blind and inefficient optimization processes. All these problems need to be solved comprehensively through a systematic and automated technical solution. Summary of the Invention

[0004] The purpose of this invention is to overcome one or more shortcomings of the prior art and provide an automated operator development method and system based on artificial intelligence.

[0005] The objective of this invention is achieved through the following technical solution: An automated operator development method based on artificial intelligence is provided, which includes the following steps: S1. Collect operator-related information, including operator name, input / output and attribute definitions, mathematical formulas, adaptation framework, compatible chips, scene limitations and binary compatibility settings. After classifying, organizing and parsing the collected operator-related information, it provides a foundation for subsequent data analysis and code generation. S2. Analyze and verify the collected operator-related information, combine the mathematical formula of the operator with the scenario constraints, analyze the computational characteristics of the operator through artificial intelligence algorithms, perform multiple rounds of parameter optimization and block strategy iterative adjustment, and determine the optimal parameter configuration and block processing logic; S3. Based on the results of parameter optimization and block processing logic, generate a NumPy-based algorithm demo to verify the algorithm logic and accuracy. After successful verification, generate operator code, test code, and documentation. As needed, match the calling specifications of deep learning frameworks to generate compatible API interfaces and calling code. S4. Compile the generated operator code into an executable file or library file according to the corresponding compilation method based on the adaptation requirements. After deployment to the corresponding environment, receive data and benchmarks and calculate the error between the actual output result and the benchmark. Output the accuracy comparison result and verification conclusion according to the preset accuracy error standard. If it fails, give the debugging focus and parameter adjustment path.

[0006] Furthermore, step S1 includes: S1.1. Receive the uploaded operator-related information; S1.2. Parse and store the uploaded operator-related information to provide a foundation for subsequent data analysis and code generation; S1.3. The parsed operator-related information is classified and organized according to core parameters, auxiliary parameters and constraints. An index is created according to the functional association of information names. The indexing rules follow the order of usage frequency to facilitate retrieval and retrieval during subsequent data analysis and code generation.

[0007] Furthermore, step S2 also includes: S2.1. Parse the parameter information of the operator, verify the accuracy and completeness of the parameter information, and mark any missing or contradictory information as abnormal; S2.2. Based on the mathematical formulas and scenario constraints of the operators, analyze the computational characteristics of the operators using machine learning models or deep learning models; S2.3. Based on the computational characteristics obtained from the analysis, multiple rounds of parameter optimization are performed using artificial intelligence algorithms. After each round of optimization, the potential for improving execution efficiency is evaluated. The optimization direction and parameter adjustment items are adjusted according to the evaluation results. At the same time, iterative optimization of the block strategy is carried out. The data block size and partitioning rules are adjusted in combination with the target chip cache structure to eliminate inefficient processing logic and determine the optimal combination of parameters and block strategy.

[0008] Furthermore, step S3 also includes: S3.1. Based on the mathematical formulas, inputs, outputs, and attribute definitions of the operators, generate an algorithm demo based on NumPy to verify the algorithm logic and accuracy, covering both regular and special input scenarios; S3.2. After the algorithm demo verification is passed, the operator code is generated according to the optimal parameter configuration and block strategy. At the same time, the corresponding test code and documentation are generated. The test code includes functional verification, boundary condition testing and abnormal input testing logic. S3.3. If it is necessary to adapt to a specific deep learning framework, generate API interfaces and calling code that are compatible with that deep learning framework; S3.4. When generating framework-compatible API interfaces and calling code, match the calling specifications and data format requirements of the deep learning framework, automatically detect the framework version and adapt to the corresponding interface standard, and ensure that operators can be directly integrated into the framework's computation process. The documentation covers operator usage instructions, parameter configuration guidelines, version compatibility instructions, and troubleshooting steps and solutions for common problems.

[0009] Furthermore, step S4 also includes: S4.1. Select the appropriate compilation method based on whether it is compatible with the deep learning framework, and compile the operator code into an executable file or a library file; S4.2. Deploy the compiled files to the target environment. Before deployment, check the hardware configuration and dependent library versions of the target environment to ensure that the environment meets the running requirements and receive the incoming data and benchmarks. S4.3. Calculate the absolute and relative errors between the actual output of the operator and the benchmark, and output the accuracy comparison results and the conclusion of whether the verification is passed according to the preset accuracy error standard; S4.4. If the verification fails, based on the error type and magnitude analysis results, clarify the key points of debugging and the parameter adjustment path, associate the corresponding operator parameter adjustment items or block strategy block rule links, mark the key optimization points, and provide adjustment suggestions and parameter optimization range for subsequent optimization.

[0010] Furthermore, in step S1, operator-related information is uploaded through a graphical interface or API interface. The graphical interface provides step-by-step information filling templates and real-time format verification prompts to guide users to fill in the information correctly. The API interface supports batch uploading, resuming interrupted uploads, and real-time feedback on upload status, including upload progress percentage, number of successful uploads, number of failed uploads, and the specific reason for each failure.

[0011] Furthermore, in step S2, the computational characteristics of the analyzed operator include computational complexity, memory access pattern, and data parallelism. The impact weight of these characteristics on the execution efficiency of the operator is quantified through machine learning models or deep learning models. Evaluation indicators such as computational efficiency improvement rate and memory usage reduction rate are set to provide data support for parameter optimization and block strategy design. At the same time, the specific technical aspects of characteristic analysis are adjusted in combination with the operator computation type.

[0012] Furthermore, in step S3.2, the generated operator code covers all development scenarios, and selects an appropriate instruction set for the hardware architecture of the target chip, performs instruction rearrangement and redundant instruction removal, and adopts a data block storage strategy to optimize memory layout, reduce data transmission latency and memory usage, and ensure execution on the target chip. At the same time, the generated test code includes performance benchmark test logic, which can output operator execution time and resource usage data. The document also supplements parameter adjustment examples and parameter configuration examples for different scenarios.

[0013] Furthermore, in step S4.1, when there is no need for deep learning framework adaptation, the operator code is compiled into a run package containing executable files and dependent library files. The run package has a built-in environment detection script to detect the operating system version, hardware driver version, and necessary dependent components to ensure installation and operation on the target device. When there is a need for deep learning framework adaptation, the operator code is compiled into a whl package containing Python interfaces and dependent library files. The whl package is compatible with mainstream stable Python versions and automatically configures the framework call path and environment variables after installation, enabling the framework to directly recognize and call the operator.

[0014] In some embodiments, an automated operator development system based on artificial intelligence is provided, which includes an information collection module, a data analysis module, a code generation module, a compilation module, and a precision verification module. The information collection module collects, parses, and stores operator-related information. It also features information format verification, error alerts, information export, and backup functions. When uploaded information is incomplete or formatted incorrectly, it provides real-time feedback to the user and guides them to correct it. It supports exporting information in a specified format. The data analysis module parses and verifies operator-related information. It performs multi-round parameter optimization and block strategy design using artificial intelligence algorithms. It adjusts the direction of parameter optimization and block strategy adjustment based on the hardware characteristics of the target chip and the operator calculation type, and stores optimization process logs for traceability. The code generation module generates algorithm demos, operator code, test code, documentation, and framework adaptation-related code. It automatically adapts to the framework version requirements during framework adaptation and supports code format standardization to ensure compatibility and readability. The compilation module compiles the operator code into corresponding executable files or library files according to adaptation requirements. It supports custom compilation options and outputs compilation process logs for easy troubleshooting of compilation anomalies. The accuracy verification module receives data and benchmarks, calculates absolute and relative errors, and outputs accuracy comparison results and verification conclusions. It can store historical accuracy comparison data and error trend analysis reports to provide a reference for subsequent operator optimization.

[0015] The beneficial effects of this invention are: (1) Relying on the fully automated design of operator information collection, parsing and verification, intelligent optimization, code generation and accuracy verification, manual intervention is greatly reduced, the development process is simplified and the dependence on professional skills is reduced; (2) Artificial intelligence algorithms enable precise iteration of parameters and block strategies, fully adapt to hardware characteristics, significantly improve operator execution efficiency and calculation accuracy, and reduce resource consumption and transmission delay; (3) Supports multi-channel uploading, multi-mode compilation and multi-framework adaptation, with supporting standard documents and auxiliary functions to enhance development flexibility and maintainability, and provide strong support for the efficient deployment of deep learning models. Attached Figure Description

[0016] Figure 1 A flowchart illustrating the steps involved in developing an automated operator based on artificial intelligence. Figure 2 The following is a flowchart illustrating the specific steps of an automated operator development method based on artificial intelligence, provided as an example. Detailed Implementation

[0017] The technical solution of the present invention will be clearly and completely described below with reference to the embodiments. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0018] Example 1 See Figure 1 This embodiment provides a method for developing automated operators based on artificial intelligence, which includes the following steps: S1. Collect operator-related information, including operator name, input / output and attribute definitions, mathematical formulas, adaptation framework, compatible chips, scene limitations and binary compatibility settings. After classifying, organizing and parsing the collected operator-related information, it provides a foundation for subsequent data analysis and code generation. S2. Analyze and verify the collected operator-related information, combine the mathematical formula of the operator with the scenario constraints, analyze the computational characteristics of the operator through artificial intelligence algorithms, perform multiple rounds of parameter optimization and block strategy iterative adjustment, and determine the optimal parameter configuration and block processing logic; S3. Based on the results of parameter optimization and block processing logic, generate a NumPy-based algorithm demo to verify the algorithm logic and accuracy. After successful verification, generate operator code, test code, and documentation. As needed, match the calling specifications of deep learning frameworks to generate compatible API interfaces and calling code. S4. Compile the generated operator code into an executable file or library file according to the corresponding compilation method based on the adaptation requirements. After deployment to the corresponding environment, receive data and benchmarks and calculate the error between the actual output result and the benchmark. Output the accuracy comparison result and verification conclusion according to the preset accuracy error standard. If it fails, give the debugging focus and parameter adjustment path.

[0019] In some embodiments, step S1 includes: S1.1. Receive the uploaded operator-related information; S1.2. Parse and store the uploaded operator-related information to provide a foundation for subsequent data analysis and code generation; S1.3. The parsed operator-related information is classified and organized according to core parameters, auxiliary parameters and constraints. An index is created according to the functional association of information names. The indexing rules follow the order of usage frequency to facilitate retrieval and retrieval during subsequent data analysis and code generation.

[0020] In some embodiments, step S2 further includes: S2.1. Parse the parameter information of the operator, verify the accuracy and completeness of the parameter information, and mark any missing or contradictory information as abnormal; S2.2. Based on the mathematical formulas and scenario constraints of the operators, analyze the computational characteristics of the operators using machine learning models or deep learning models; S2.3. Based on the computational characteristics obtained from the analysis, multiple rounds of parameter optimization are performed using artificial intelligence algorithms. After each round of optimization, the potential for improving execution efficiency is evaluated. The optimization direction and parameter adjustment items are adjusted according to the evaluation results. At the same time, iterative optimization of the block strategy is carried out. The data block size and partitioning rules are adjusted in combination with the target chip cache structure to eliminate inefficient processing logic and determine the optimal combination of parameters and block strategy.

[0021] In some embodiments, step S3 further includes: S3.1. Based on the mathematical formulas, inputs, outputs, and attribute definitions of the operators, generate an algorithm demo based on NumPy to verify the algorithm logic and accuracy, covering both regular and special input scenarios; S3.2. After the algorithm demo verification is passed, the operator code is generated according to the optimal parameter configuration and block strategy. At the same time, the corresponding test code and documentation are generated. The test code includes functional verification, boundary condition testing and abnormal input testing logic. S3.3. If it is necessary to adapt to a specific deep learning framework, generate API interfaces and calling code that are compatible with that deep learning framework; S3.4. When generating framework-compatible API interfaces and calling code, match the calling specifications and data format requirements of the deep learning framework, automatically detect the framework version and adapt to the corresponding interface standard, and ensure that operators can be directly integrated into the framework's computation process. The documentation covers operator usage instructions, parameter configuration guidelines, version compatibility instructions, and troubleshooting steps and solutions for common problems.

[0022] In some embodiments, step S4 further includes: S4.1. Select the appropriate compilation method based on whether it is compatible with the deep learning framework, and compile the operator code into an executable file or a library file; S4.2. Deploy the compiled files to the target environment. Before deployment, check the hardware configuration and dependent library versions of the target environment to ensure that the environment meets the running requirements and receive the incoming data and benchmarks. S4.3. Calculate the absolute and relative errors between the actual output of the operator and the benchmark, and output the accuracy comparison results and the conclusion of whether the verification is passed according to the preset accuracy error standard; S4.4. If the verification fails, based on the error type and magnitude analysis results, clarify the key points of debugging and the parameter adjustment path, associate the corresponding operator parameter adjustment items or block strategy block rule links, mark the key optimization points, and provide adjustment suggestions and parameter optimization range for subsequent optimization.

[0023] In some embodiments, in step S1, operator-related information is uploaded through a graphical interface or API interface. The graphical interface provides step-by-step information filling templates and real-time format verification prompts to guide users to fill in the information correctly. The API interface supports batch uploading, resuming interrupted uploads, and real-time feedback on upload status, including upload progress percentage, number of successful uploads, number of failed uploads, and the specific reason for each failure.

[0024] In some embodiments, in step S2, the computational characteristics of the analyzed operator include computational complexity, memory access pattern, and data parallelism. The impact weight of these characteristics on the execution efficiency of the operator is quantified by machine learning models or deep learning models. Evaluation indicators such as computational efficiency improvement rate and memory usage reduction rate are set to provide data support for parameter optimization and block strategy design. At the same time, the specific technical aspects of characteristic analysis are adjusted in combination with the operator computation type.

[0025] In some embodiments, in step S3.2, the generated operator code covers all development scenarios, and selects an appropriate instruction set for the hardware architecture of the target chip, performs instruction rearrangement and redundant instruction removal, and adopts a data block storage strategy to optimize memory layout, reduce data transmission latency and memory usage, and ensure execution on the target chip. At the same time, the generated test code contains performance benchmark test logic and can output operator execution time and resource usage data. The document supplements parameter adjustment examples and parameter configuration examples for different scenarios.

[0026] In some embodiments, in step S4.1, when there is no need for deep learning framework adaptation, the operator code is compiled into a run package containing executable files and dependency library files. The run package has a built-in environment detection script to detect the operating system version, hardware driver version, and necessary dependent components to ensure installation and operation on the target device. When there is a need for deep learning framework adaptation, the operator code is compiled into a whl package containing Python interfaces and dependency library files. The whl package is compatible with mainstream stable Python versions and automatically configures the framework call path and environment variables after installation, so that the framework can directly recognize and call the operator.

[0027] In some embodiments, an automated operator development system based on artificial intelligence is provided, which includes an information collection module, a data analysis module, a code generation module, a compilation module, and a precision verification module. The information collection module collects, parses, and stores operator-related information. It also features information format verification, error alerts, information export, and backup functions. When uploaded information is incomplete or formatted incorrectly, it provides real-time feedback to the user and guides them to correct it. It supports exporting information in a specified format. The data analysis module parses and verifies operator-related information. It performs multi-round parameter optimization and block strategy design using artificial intelligence algorithms. It adjusts the direction of parameter optimization and block strategy adjustment based on the hardware characteristics of the target chip and the operator calculation type, and stores optimization process logs for traceability. The code generation module generates algorithm demos, operator code, test code, documentation, and framework adaptation-related code. It automatically adapts to the framework version requirements during framework adaptation and supports code format standardization to ensure compatibility and readability. The compilation module compiles the operator code into corresponding executable files or library files according to adaptation requirements. It supports custom compilation options and outputs compilation process logs for easy troubleshooting of compilation anomalies. The accuracy verification module receives data and benchmarks, calculates absolute and relative errors, and outputs accuracy comparison results and verification conclusions. It can store historical accuracy comparison data and error trend analysis reports to provide a reference for subsequent operator optimization.

[0028] Example 2 This embodiment provides an automated operator development method based on artificial intelligence. Through standardized and intelligent end-to-end design, it achieves closed-loop automation of operator development from information collection to accuracy verification, reducing the cost of manual intervention and improving operator adaptability and execution performance. Figure 2 As shown, the specific implementation of this method is as follows: S1. Collect all the information required by the operators and complete the classification, organization, parsing, and storage: The core of this step is to comprehensively collect, standardize, and securely store the basic information required for operator development, providing accurate and reusable data support for subsequent intelligent analysis and code generation. The collection scope covers all dimensions of information, including operator functionality, environment adaptation, and scenario constraints. This includes operator name, input / output and attribute definitions, core mathematical formulas, compatible deep learning frameworks, compatible chip models, scenario usage restrictions, and binary compatibility settings. It also supports multiple upload channels, balancing ease of use and standardization. After collection, the information preprocessing loop is completed through four main operations: classification, parsing, index optimization, and secure storage.

[0029] S1.1. Receive uploaded operator-related information: The system receives all operator information uploaded by users through designated channels. Uploaded content must strictly cover all necessary elements required for the entire operator development process, and must not contain missing key information, ambiguous statements, or inconsistent formatting. Specifically, operator names must conform to a unified naming convention and clearly define the operator's function; input / output and attribute definitions must clearly specify parameter names, data types, dimension ranges, value constraints, and default value settings; mathematical formulas must be presented in a standard format, clearly expressing the core operational logic; compatible frameworks and chips must specify the specific model and version; scenario limitations must specify the applicable data scale, accuracy requirements, and operating environment constraints; binary compatibility settings must specify the compatible operating system bitness, compilation environment, and dependent library versions. During the upload process, the system verifies the completeness of the information in real time. If any missing key information is detected, the system immediately prompts the user to supplement it, ensuring that subsequent data analysis and code generation stages obtain complete and accurate basic data, avoiding process delays or invalid results due to information issues.

[0030] S1.2. Information parsing and storage: The uploaded operator information is analyzed item by item and in depth to ensure that the system accurately understands the core meaning and logical relationships of each information element. Specific analysis operations are as follows: For input / output and attribute definitions, syntax standardization checks, dimensional matching analysis, and definition uniqueness verification are conducted to clarify the functional positioning, data type compatibility range, dimensional upper and lower limits, and relationships with other parameters for each parameter; for core mathematical formulas, the operational logic is broken down using syntax parsing tools to clarify the priority of each operation, association rules, and parameter mapping relationships, transforming complex formulas into logical expressions recognizable by the system, while verifying the compatibility of the formulas with input / output parameters; for constraints such as adaptation frameworks and compatible chips, core constraints are extracted and a standardized constraint list is formed through keyword extraction and semantic analysis techniques.

[0031] After parsing, the information is stored according to a pre-defined hierarchical data structure, employing a three-tiered storage architecture of "core data - auxiliary data - constraint data." Core data is stored in a high-performance database, while auxiliary and constraint data utilize distributed storage to enhance scalability. Simultaneously, an information index table is established, containing fields such as information type, keywords, storage address, and associated information identifiers, enabling rapid information location and retrieval. Storage media are selected with data encryption and fault-tolerant backup capabilities to ensure that data is not lost, damaged, or leaked during storage and subsequent use.

[0032] S1.3. Information Classification and Index Optimization: The parsed operator information is categorized into three types based on functional attributes: core parameters, auxiliary parameters, and constraints, achieving standardized information classification. Core parameters are key information supporting the core computational functions of the operator, including input and output data types, dimensional requirements, key coefficients in mathematical formulas, and computational priority parameters. Auxiliary parameters are supplementary information ensuring the development, deployment, and use of the operator, including the operator version number, developer notes, and update logs. Constraints are the constraints that must be followed during the development and operation of the operator, including limitations on the dimensionality of scenario use, data value range constraints, and chip architecture adaptation requirements.

[0033] After classification, an index is built based on information function associations. The default sorting rule is "usage frequency," which ranks frequently used information at the top of the index by statistically analyzing the call frequency of various types of information in historical operator development data, improving the efficiency of subsequent information retrieval. The indexing rule can also be switched, allowing for "information relevance sorting" based on actual development needs. This will group information closely related in terms of calculation logic and parameter configuration, reducing the frequency of cross-index lookups. During classification and index optimization, it is crucial to ensure accurate information categorization and consistent indexing rules to avoid classification errors and index chaos.

[0034] S1.4. Multiple Upload Methods and Standardized Guidance: The system supports dual upload channels: a graphical user interface (GUI) and an application programming interface (API), both with standardized guidance features. The GUI upload method is designed for manual operation scenarios, providing step-by-step information entry templates. It is structured into sections: "Basic Information - Core Parameters - Constraints," with each field accompanied by formatting instructions, examples, and mandatory field indicators. A built-in real-time format validation function immediately displays an error message when user-entered information does not conform to preset specifications, clearly indicating the error location, cause, and correction criteria, guiding the user to complete the entry correctly.

[0035] The API upload method is designed for batch processing scenarios, supporting batch uploads of multiple sets of operator information and resuming interrupted uploads of large-volume information. During the upload process, it provides real-time feedback on upload progress, the number of successful uploads, the number of failed uploads, and the specific reason for each failure, allowing users to quickly troubleshoot problems based on the feedback. The API also supports custom upload parameters, allowing users to set upload timeout, data encryption methods, and duplicate information processing rules, balancing flexibility and security to ensure efficient and smooth information upload processes in different scenarios.

[0036] S2. Deep analysis and verification of operator information, and intelligent optimization of parameters and block partitioning strategies: This step is the core of operator performance optimization. Based on the information normalized in step S1, it determines the optimal solution to suit the target chip and scenario requirements through deep analysis and verification, AI analysis of computational characteristics, and multi-round parameter and block strategy optimization. This provides precise parameter configuration and logical support for subsequent code generation. This step relies on artificial intelligence algorithms to replace the experience-based operations of traditional manual optimization. Through quantitative analysis and iterative verification, it balances operator computational accuracy, execution efficiency, and resource consumption, ensuring that the operator achieves optimal performance in the target environment.

[0037] S2.1. Parameter parsing verification and anomaly marking: A second in-depth analysis and compliance verification is performed on the operator information stored in S1. Compared to the basic analysis of S1, this step focuses more on a deep check of parameter logic consistency, constraint adaptability, and information integrity. During the analysis, the value range, functional positioning, relationship logic with other parameters, and weight of influence on the calculation results of each parameter are clarified. For example, for coefficient parameters in mathematical formulas, their value range and sensitivity to calculation precision are clarified; for input and output parameters, dimensional compatibility, data type matching, and the rationality of default values ​​are checked.

[0038] Simultaneously, multi-dimensional compliance verification is conducted: verifying the consistency between parameter definitions and mathematical formulas to avoid parameter mapping errors; verifying the compatibility of parameter value ranges with scenario limitations to ensure that parameter settings do not exceed scenario constraint boundaries; and verifying the compatibility between the adaptation framework, compatible chips, and parameter configurations. If issues such as missing information, logical contradictions, or adaptation conflicts are found during the verification process, they are categorized and marked according to the anomaly type, clearly indicating the anomaly category, specific location, and detailed reasons, providing clear guidance for subsequent manual correction or automatic adjustment.

[0039] S2.2. Computational Characteristics AI Analysis: Using the mathematical formulas of operators and scenario constraints as core inputs, the computational characteristics of operators are systematically and quantitatively analyzed through machine learning or deep learning models. First, the input information is preprocessed: the mathematical formulas are transformed into computational logic expressions recognizable by the model, broken down into basic operational units, and the operational priority and relationships of each unit are labeled; the scenario constraints are quantified into numerical constraints to ensure that the model can accurately understand the computational requirements and constraint boundaries of the operators.

[0040] Subsequently, a pre-defined AI model is invoked to perform feature extraction and analysis. The model prioritizes a hybrid model architecture that balances accuracy and efficiency. If the operator's computational logic is simple, machine learning models such as decision trees and random forests can be used; if the operator involves complex numerical operations, a deep learning model is chosen to improve analysis accuracy. The model obtains the core features of the operator through the feature extraction module, including the proportion of operation types, computational complexity level, memory access pattern, data parallel processing capability, computation time distribution, and peak resource consumption. The feature analysis module quantifies the influence weight of each feature, ultimately outputting an operator computational characteristic analysis report, providing accurate data support for subsequent parameter optimization and block-based strategy design.

[0041] In some embodiments, a single machine learning model can be used to complete the computational characteristic analysis. A random forest model suitable for numerical computational characteristic analysis is selected, and the preprocessed mathematical formula features and scene constraint features are used as model inputs. The model parameters are optimized through multiple rounds of iterative training, and the feature weight allocation rules are adjusted. After each iteration, cross-validation is used to verify the accuracy of the analysis results. If the result error is within the preset threshold range, the iteration is stopped, and the final computational characteristic analysis result is output.

[0042] S2.3. Multi-round parameter optimization and determination of the optimal solution: Based on the analysis of operator computational characteristics, a pre-set artificial intelligence optimization algorithm is initiated to conduct multiple rounds of parameter tuning and iterative optimization of the block-based strategy. Parameter optimization focuses on three main categories: core computational parameters, memory allocation parameters, and parallel processing parameters. In each round of optimization, the algorithm makes targeted adjustments to the parameters according to the operator computational characteristics and scenario constraints: core computational parameters adopt a "sensitivity-first adjustment" strategy, prioritizing the adjustment of parameters that have a greater impact on computational accuracy; memory allocation parameters are adjusted based on the target chip's memory architecture, including the memory usage ratio and data caching strategy; and parallel processing parameters are adjusted based on the operator's data parallelism characteristics, including the number of parallel processing units and task allocation rules.

[0043] After each round of parameter adjustments, performance evaluation is conducted by simulating the target operating environment. Evaluation metrics include computation time, memory usage, data processing throughput, and accuracy loss rate, quantifying the potential for improving execution efficiency. The optimization direction and parameter adjustment magnitude are dynamically adjusted based on the evaluation results: if the performance improvement after a round of optimization meets the target, optimization is deepened in that direction; if the performance improvement does not meet expectations, the reasons are analyzed, and the optimization direction is switched.

[0044] While optimizing parameters, iterative optimization of the block partitioning strategy is carried out simultaneously. The core is to optimize the data block size and partitioning rules based on the target chip's cache characteristics. First, the hardware parameters of the target chip are obtained, including cache capacity, cache level, cache access speed, data bus width, etc., and an initial block partitioning scheme is designed based on the operator memory access mode and data volume. Then, the block partitioning parameters are adjusted through multiple rounds of iteration: when the chip cache capacity is small, small-sized blocks are used; when the data parallelism is high, data blocks are divided according to parallel processing units; when the operator has complex nested operations, a hierarchical block partitioning strategy is adopted. After each round of block partitioning scheme adjustment, indicators such as data access latency, cache utilization, and computational parallelism are evaluated, inefficient processing logic is eliminated, and finally, the synergistic optimization of parameter configuration and block partitioning strategy is achieved to form the optimal combination scheme.

[0045] S2.4. Characteristic Quantification and Evaluation Index Setting: Focusing on three core characteristics—computational complexity, memory access patterns, and data parallelism—this study further quantifies their impact on operator execution efficiency using AI models, establishing a mapping relationship between characteristics and performance. Computational complexity is quantified using a weighted summation of operation steps and nesting levels, with weight allocation tilted towards deeper nested operations. Memory access patterns are quantified using metrics such as access frequency, access continuity, and address distribution concentration. Data parallelism is quantified using metrics such as the scale of data that can be processed in parallel and the utilization rate of parallel units. The impact weights of each characteristic are calculated through the model, allowing for targeted adjustments and optimization priorities.

[0046] Simultaneously, multi-dimensional evaluation indicators are set, with core indicators including computational efficiency improvement rate and memory usage reduction rate. Computational efficiency improvement rate = (computation time before optimization - computation time after optimization) / computation time before optimization × 100%; memory usage reduction rate = (memory usage before optimization - memory usage after optimization) / memory usage before optimization × 100%. The analysis and evaluation focus is adjusted based on the operator computation type: for convolutional operators, the focus is on analyzing the space for data parallelism optimization and block access efficiency; for logical judgment operators, the focus is on analyzing the potential for simplifying computation steps and the continuity of memory access; for matrix operation operators, the focus is on analyzing computational complexity and cache adaptability, ensuring the analysis and evaluation are targeted and reasonable.

[0047] In some embodiments, a data processing latency reduction rate metric can be added. By using metrics from three dimensions—computational efficiency, memory usage, and processing latency—the optimization effect can be comprehensively measured, avoiding the one-sidedness of optimization caused by a single metric and ensuring that the operator can achieve improvements in multiple performance dimensions.

[0048] S3. Algorithm Demo Validation and Operator Code and Supporting Documentation Construction: This step, based on the optimized parameter configuration and block-based strategy of S2, completes the entire process of operator deployment, from algorithm verification to code construction and documentation. The core is to verify the logic and accuracy through an algorithm demo, then generate deployable operator code, test code, and accompanying documentation, adapting it to deep learning frameworks as needed to achieve the engineering deployment of the operator. The entire process strictly adheres to the principles of "verification first, code synchronization, and documentation support" to ensure the operator's functionality is reliable, easy to deploy, and easy to maintain.

[0049] S3.1. Algorithm Demo Generation and Full-Scene Validation: Based on the operator's mathematical formula, input / output parameter definitions, and optimized parameter configurations, an algorithm demo based on NumPy is automatically generated. The NumPy library boasts efficient numerical computation capabilities and excellent compatibility, allowing for rapid reproduction of the operator's core operational logic. The demo code strictly adheres to coding standards, with a structure divided into three main modules: parameter definition, core operations, and result output. The parameter definition module precisely maps to the optimized parameter configurations, the core operations module rigorously reproduces the mathematical formula logic and block processing rules, and the result output module outputs the calculation results in a preset format, while also providing a log printing interface for easy debugging and analysis.

[0050] To comprehensively verify the correctness of the algorithm's logic, the reliability of its accuracy, and its adaptability to various scenarios, the demo needs to cover multiple input scenarios for full-dimensional verification. For routine input scenarios, data types, formats, and value ranges commonly used in daily operator operations are selected to verify the accuracy of basic computational functions. For boundary value input scenarios, the maximum, minimum, critical, and dimensional critical values ​​of the parameter range are selected to verify the stability of the computational logic under critical conditions. For abnormal format input scenarios, abnormal data such as dimension mismatches, inconsistent data types, and null values ​​are selected to test the demo's anomaly identification and handling capabilities. For extreme scale input scenarios, inputs far exceeding the normal data volume are selected to test the demo's stress resistance and resource adaptability.

[0051] During the verification process, the demo output results are compared with the theoretical calculation results to calculate the accuracy error. If the error is within the preset threshold range, the verification is considered to have passed; if it fails, the process returns to step S2 to re-optimize the parameters and block strategy until the verification meets the standard.

[0052] S3.2. Code and accompanying documentation generation: After the algorithm demo passes validation, the engineered operator code is automatically generated based on optimal parameter configuration and block-based strategies. Code development strictly adheres to the syntax and coding standards of the target programming language, balancing execution efficiency and readability. During generation, the optimized parameter configuration and block-based processing logic are precisely translated into code statements. Core computation modules employ efficient coding methods, avoiding redundant code and complex nested structures, while incorporating hardware adaptation optimization logic to improve code execution efficiency. The operator code must fully cover all stages, including data reception, parameter parsing, block-based processing, core computation, result output, and exception handling, ensuring it can be executed independently or called by the framework. It also reserves extension interfaces to facilitate subsequent feature iterations and performance optimizations.

[0053] While generating operator code, corresponding test code and accompanying documentation are generated simultaneously. The test code is designed according to the categories of "functional test - performance test - exception test": the functional test module calls the operator code, inputs preset test data, and compares the output results with the expected results; the boundary test module reuses the boundary value input data in the demo verification; the exception test module designs various abnormal inputs and abnormal running scenarios; the performance test module has a built-in timer and resource monitoring interface, which can output performance indicators such as calculation time, CPU utilization, and memory usage.

[0054] The accompanying documentation is compiled in a standardized format, and its core content includes: an operator overview, briefly introducing the operator's functional positioning, design purpose, and application scope; a functional description, detailing the computational functions, core features, and performance advantages that the operator can achieve; input and output parameter descriptions, clarifying the name, data type, dimensional requirements, value range, default value, and function of each parameter; a parameter configuration guide, detailing the configuration methods, adjustment range, and performance impact of each parameter; usage examples, providing sample code for various scenarios such as basic calls, custom parameter configurations, and framework integration calls; and precautions, listing environmental dependencies, compatibility limitations, performance optimization suggestions, and common problem avoidance methods that need to be considered during operator use.

[0055] S3.3. Code Optimization and Documentation Supplement: To further improve the execution performance and adaptability of the operator code, targeted optimizations were performed on the generated operator code. In terms of hardware adaptation optimization, an appropriate instruction set was selected for the target chip architecture, and the execution order was optimized through instruction rearrangement to adapt to the chip pipeline characteristics. Redundant instructions were eliminated by removing invalid assignments, duplicate judgments, and uncalled function definitions, reducing computational overhead and resource consumption.

[0056] For memory optimization, a data block storage strategy is adopted. The block size and storage method are designed in conjunction with the target chip's cache structure to achieve continuous data storage and efficient retrieval, reducing data transmission latency. The memory layout is optimized by centralizing frequently accessed data, improving cache hit rate and reducing memory bandwidth usage. After code optimization, the optimization effect is verified through a performance testing module to ensure that metrics such as computational efficiency and memory usage meet expected requirements.

[0057] Simultaneously, the accompanying documentation will be supplemented and improved, including parameter adjustment case studies, selecting typical application scenarios, and detailing the specific steps for parameter adjustment, performance changes before and after adjustment, and optimization logic; scenario-based parameter configuration examples will be added, providing corresponding parameter configuration schemes for different data scales, computational accuracy requirements, and hardware environments; and code structure explanations will be added, breaking down the core modules, functional divisions, and calling relationships of the operator code to facilitate user understanding of the code logic and enable secondary development or troubleshooting.

[0058] S3.4. Deep Learning Framework Adaptation: If users require deep learning framework compatibility, generate compatible API interfaces and calling code based on the target framework's technical specifications. First, review the target framework's interface design standards, data format requirements, function call rules, and error handling mechanisms to ensure the API interface design strictly complies with the framework specifications; interface names, parameter types, and return value formats all conform to the framework's conventions. The API interface must cover basic calls, custom parameters, batch processing, and other functionalities to meet the needs of different use cases.

[0059] The calling code focuses on implementing the interaction logic between operators and the framework, including core functions such as data format conversion, parameter passing, framework context integration, and return of computation results. The data format conversion module converts the framework's tensor format into a data format that the operators can process, and simultaneously converts the operator output into a tensor format supported by the framework. The parameter passing module achieves precise mapping between framework parameters and operator parameters, supporting dynamic parameter adjustment. The framework context integration module embeds operators into the framework's computation process, ensuring seamless collaboration with other framework components. After generation, multiple rounds of compatibility testing are conducted to verify the usability, stability, and performance of the API interface and calling code within the target framework. If compatibility issues arise, the interface design or calling logic is adjusted accordingly.

[0060] Version 3.5 Adaptation and Documentation Improvement: The system automatically detects the target framework version, obtains the specific version number through the framework version query interface or by parsing the version identifier file in the installation directory, and adapts the corresponding interface standard according to the version differences. Since different framework versions may differ in interface parameters, function names, data formats, etc., the adaptation logic is specifically adjusted when generating API interfaces and calling code to ensure that operators can run normally in different framework versions, achieving cross-version compatibility.

[0061] Simultaneously improve the framework adaptation content of the supporting documentation, supplement version compatibility instructions, clarify the framework version range for operator adaptation, list the tested and unsupported versions, and explain the functional differences and adaptation limitations between different versions; supplement the framework integration guide, detailing the steps for API interface registration, call path configuration, environment variable settings, etc., taking into account both automatic and manual configuration scenarios; supplement the troubleshooting and solution guide for common problems, analyzing possible causes and providing troubleshooting steps and solutions for problems that may occur during framework integration, such as interface call failures, data format conversion errors, abnormal calculation results, and performance failures.

[0062] In some embodiments, offline adaptation can be achieved through a preset framework version adaptation list. This list contains the interface standards, parameter requirements, compatibility differences, and adaptation solutions corresponding to different framework versions. During the generation process, the adaptation requirements of the target version are extracted by querying the list, and the API interface and calling code are generated according to the requirements. There is no need to call the framework interface in real time to detect the version, and adaptation can be completed in an offline environment, improving generation efficiency. The adaptation list is updated regularly to include newly released framework versions and adaptation requirements, ensuring the long-term compatibility of the operators.

[0063] S4. Multi-mode compilation and deployment, operator precision verification and optimization guidelines: This step involves the engineering compilation of operator code, deployment in the target environment, and final accuracy verification. The core is selecting the appropriate compilation mode based on framework adaptation requirements, generating deployable files, verifying operator performance through accuracy benchmark comparison, and providing clear optimization guidance when performance falls short, thus forming a closed-loop verification process for operator development. This step balances flexibility and rigor, supports compilation and deployment in multiple scenarios, ensures stable operation of the operator in the target environment, and guarantees reliable operator calculation results through rigorous accuracy verification.

[0064] S4.1. On-demand compilation and file generation: Depending on whether the operator is compatible with the deep learning framework, the corresponding compilation method is selected, and the compilation process strictly follows the specifications and standards of the target programming language and compilation tools. Preprocessing operations are performed before compilation: syntax checking to identify and correct syntax problems such as misspelled keywords and incomplete statement structures; logic verification using static analysis tools to check for potential logical vulnerabilities such as uninitialized variables, array out-of-bounds errors, and null pointer references; and dependency library association to confirm that all required libraries are present, establish the relationship between the code and the libraries, and clarify the version requirements of the libraries.

[0065] During compilation, compilation parameters can be flexibly set according to the compilation method and target environment: the compilation optimization level can be selected according to needs; O3 level optimization is selected to prioritize execution speed, O2 level optimization is selected to balance speed and memory, and O0 level optimization can be selected and debug information is enabled for debugging scenarios; the output file format is set according to deployment requirements; an executable file can be generated if there is no framework adaptation requirement, and a library file can be generated if there is a framework adaptation requirement or if it needs to be called by other programs; the target platform architecture must be consistent with the compatible chip hardware architecture to avoid the compiled file not running due to architecture incompatibility. After compilation, the corresponding executable file or library file is generated, and a compilation log is output, recording the compilation steps, parameters used, dependent library call status, and exception information to facilitate troubleshooting compilation problems.

[0066] S4.2. Generation of scenario-specific compilation packages: To address different framework adaptation requirements, corresponding integrated compilation packages are generated. When no deep learning framework adaptation is required, a `run` package is generated. This package is an integrated installation and runtime package, containing the operator executable file, all required dependency libraries, environment detection scripts, and installation guidelines. The environment detection script built into the `run` package is automatically executed before installation and runtime, checking the target device's operating system version, hardware driver version, and the existence and version compatibility of necessary dependencies. If the detection results meet the requirements, the installation process is executed automatically; otherwise, clear prompts are output to guide the user in adjusting the environment configuration.

[0067] When deep learning framework adaptation is required, a whl package is generated. This package is a standard Python environment installer, containing operator Python API interfaces, dependency library files, version adaptation scripts, and auto-configuration tools, compatible with mainstream stable Python versions. During installation, the whl package automatically configures the deep learning framework's call path, registers the operator API interfaces to the framework's interface list, and automatically sets relevant environment variables, eliminating the need for manual configuration by the user. In some embodiments, the whl package supports a manual configuration option, providing both automatic and manual configuration modes during installation. The manual configuration mode includes a detailed configuration guide to adapt to complex environments.

[0068] S4.3. Environment Deployment and Data Reception: After the compiled package is generated, it is deployed to the target environment according to the preset deployment process. Before deployment, a comprehensive environment test must be performed. Hardware configuration test covers key parameters such as processor model, number of cores, memory size, storage capacity, and compatible chip models to confirm that the hardware configuration can support the operator's computing requirements. Software environment test covers operating system version, dependent library version, driver version, framework version (adaptive scenario), etc., to confirm that the software environment is compatible with the compiled package.

[0069] After the test is passed, the deployment process begins: First, the compiled package is transferred to the specified directory of the target environment. During the transfer, the file hash value is verified to ensure the integrity of the file transfer. Then, the installation command is executed, which automatically completes operations such as file decompression, environment configuration, dependency library association, and service registration. After installation, a trial run test is conducted. The operator is called to perform a simple calculation task to verify whether the operator can start and run normally without errors or crashes. If the trial run is successful, the deployment is complete.

[0070] After deployment, the operator enters a standby state, receiving user-supplied input data and precision benchmarks. The input data must conform to the operator's input format requirements, supporting various methods such as local file import, network interface transmission, and internal framework data transfer. The precision benchmark serves as reference data for measuring the operator's computational accuracy and can be obtained through mature open-source algorithms, precise manual calculations, or reliable calculation results from other frameworks. The benchmark data format must be consistent with the operator's output format. Upon receiving data and benchmarks, data validation is performed to check data integrity, format correctness, dimension matching, and value rationality. If any issues are found, the user is promptly prompted to correct them.

[0071] S4.4. Accuracy Calculation and Result Judgment: After receiving the input data, the operator starts the calculation process according to the optimized parameter configuration and block strategy, and outputs the actual result after the calculation is completed. The precision calculation module is then invoked to perform error calculation and result determination. Error calculation uses a two-dimensional index, including absolute error and relative error: Absolute error is calculated point-by-point along each dimension, with the formula |actual result - precision benchmark|, and the average, maximum, and minimum values ​​of the overall absolute error are also calculated; relative error is calculated based on the absolute error, with the formula |actual result - precision benchmark| / |precision benchmark| (the benchmark value is not 0), and the overall average, maximum, and minimum values ​​are also calculated.

[0072] Based on the preset accuracy error standard, the operator is judged to pass the verification. The error standard needs to be formulated in combination with the operator's application scenario and calculation accuracy requirements. Different types of operators can be set with different standards. If the absolute and relative errors of all dimensions are within the preset range, the verification is judged to pass, and complete accuracy comparison data and a verification conclusion report are output. If the error of any dimension exceeds the preset range, the verification is judged to fail, and accuracy comparison data, error exceeding the standard location, degree of exceeding the standard and distribution characteristics are output, providing a clear basis for subsequent debugging and optimization.

[0073] S4.5. Optimization Guidelines for Non-Compliance: For scenarios where accuracy verification fails, conduct systematic error analysis to clarify debugging priorities and parameter adjustment paths. First, analyze the error type and characteristics: distinguish between absolute error exceeding the standard, relative error exceeding the standard, or both exceeding the standard; determine whether the error exceeds the standard in a single dimension or across all dimensions; and identify whether the error is systematic or random. At the same time, analyze the error magnitude and distribution to clarify the degree to which the error exceeds the threshold, and whether the error is concentrated in a specific dimension, a specific computational step, or a specific input range.

[0074] Based on the error analysis results and the operator development process, the core debugging links are located: if the error is concentrated in the edge computing part after data block division, the debugging focus is on the block division strategy rules and edge data processing logic; if the error fluctuates significantly with parameter values, the debugging focus is on the precision setting and value range of the core operation parameters; if the error originates from framework integration, the debugging focus is on the data format conversion logic and API interface parameter mapping; if the error is a systematic deviation, the debugging focus is on the logical reproduction of mathematical formulas and the setting of operation priorities.

[0075] The parameter adjustment path was then clearly defined, determining the adjustment order and direction: core parameters affecting computational accuracy were adjusted first, followed by auxiliary parameters; the parameter value range was coarsely adjusted first, followed by fine-tuning of specific values; the block partitioning strategy was optimized simultaneously, adjusting block size, partitioning rules, and edge processing logic. Key optimization points were marked, and specific adjustment suggestions and parameter optimization ranges were provided. Relevant personnel could carry out optimization operations according to the guidelines. After completion, compilation, deployment, and accuracy verification were re-executed until the operator passed verification.

[0076] S4.6. Accessibility Support: The compilation module supports user-defined compilation options, allowing flexible settings such as compilation optimization level, output file path, debug information on / off, and dependency library linking method. Detailed logs are output during compilation, including fields such as timestamp, log level, module name, operation description, and exception information. These logs provide a structured record of the entire compilation process, enabling users to quickly locate the cause of compilation errors and efficiently troubleshoot and resolve problems.

[0077] The accuracy verification module automatically stores historical data for each accuracy verification, including actual output results, accuracy benchmarks, dimensional error values, statistical indicators, verification conclusions, verification time, parameter configurations used, and block partitioning strategies. Simultaneously, it generates an error trend analysis report based on historical data, analyzing the variation patterns of errors under different optimization stages and parameter configurations. Historical data and trend reports provide crucial references for subsequent operator optimization and version iterations, helping users summarize optimization patterns, formulate more reasonable optimization strategies, avoid repetitive and ineffective operations, and provide data support for operator performance upgrades and scenario expansion.

[0078] The AI-based automated operator development method provided in this embodiment constructs a fully automated closed loop for operator development through four core steps, achieving standardized and intelligent implementation from information collection to accuracy verification. In terms of development efficiency, AI-driven information processing, parameter optimization, and code generation replace a large amount of manual coding, debugging, and optimization work, simplifying the development process, reducing the requirements for professional mathematical foundations and programming skills in operator development, enabling non-professional developers to participate in operator development, expanding the scope of development participation, and significantly shortening the development cycle.

[0079] In terms of performance, through multiple rounds of parameter optimization and block strategy iteration, combined with the hardware characteristics of the target chip and the computational characteristics of the operator, the optimal combination scheme is determined, which effectively improves the execution efficiency and computational accuracy of the operator, reduces memory usage and data transmission latency, ensures that the operator achieves optimal performance in the target environment, and has good cross-environment adaptability.

[0080] In terms of practicality, the method supports multiple upload methods, multiple compilation modes, and multiple framework adaptations, meeting the operator development needs of different scenarios and hardware environments. The generated accompanying documentation and auxiliary functions enhance the ease of use and maintainability of the operators. In summary, this method effectively ensures the integrity, reliability, and efficiency of operator development, providing strong support for the efficient deployment and performance optimization of deep learning models, and promoting the large-scale application of deep learning technology in various fields such as industry and scientific research.

[0081] The above description is merely a preferred embodiment of the present invention. It should be understood that the present invention is not limited to the forms disclosed herein and should not be construed as excluding other embodiments. It can be used in various other combinations, modifications, and environments, and can be altered within the scope of the concept described herein through the above teachings or related technologies or knowledge. Modifications and variations made by those skilled in the art that do not depart from the spirit and scope of the present invention should be within the protection scope of the appended claims.

Claims

1. A method for developing automated operators based on artificial intelligence, characterized in that, Includes the following steps: S1. Collect operator-related information, including operator name, input / output and attribute definitions, mathematical formulas, adaptation framework, compatible chips, scene limitations and binary compatibility settings. After classifying, organizing and parsing the collected operator-related information, it provides a foundation for subsequent data analysis and code generation. S2. Analyze and verify the collected operator-related information, combine the mathematical formula of the operator with the scenario constraints, analyze the computational characteristics of the operator through artificial intelligence algorithms, perform multiple rounds of parameter optimization and block strategy iterative adjustment, and determine the optimal parameter configuration and block processing logic; S3. Based on the results of parameter optimization and block processing logic, generate a NumPy-based algorithm demo to verify the algorithm logic and accuracy. After successful verification, generate operator code, test code, and documentation. As needed, match the calling specifications of deep learning frameworks to generate compatible API interfaces and calling code. S4. Compile the generated operator code into an executable file or library file according to the corresponding compilation method based on the adaptation requirements. After deployment to the corresponding environment, receive data and benchmarks and calculate the error between the actual output result and the benchmark. Output the accuracy comparison result and verification conclusion according to the preset accuracy error standard. If it fails, give the debugging focus and parameter adjustment path.

2. The method according to claim 1, characterized in that, Step S1 also includes: S1.

1. Receive the uploaded operator-related information; S1.

2. Parse and store the uploaded operator-related information to provide a foundation for subsequent data analysis and code generation; S1.

3. The parsed operator-related information is classified and organized according to core parameters, auxiliary parameters and constraints. An index is created according to the functional association of information names. The indexing rules follow the order of usage frequency to facilitate retrieval and retrieval during subsequent data analysis and code generation.

3. The method according to claim 1, characterized in that, Step S2 also includes: S2.

1. Parse the parameter information of the operator, verify the accuracy and completeness of the parameter information, and mark any missing or contradictory information as abnormal; S2.

2. Based on the mathematical formulas and scenario constraints of the operators, analyze the computational characteristics of the operators using machine learning models or deep learning models; S2.

3. Based on the computational characteristics obtained from the analysis, multiple rounds of parameter optimization are performed using artificial intelligence algorithms. After each round of optimization, the potential for improving execution efficiency is evaluated. The optimization direction and parameter adjustment items are adjusted according to the evaluation results. At the same time, iterative optimization of the block strategy is carried out. The data block size and partitioning rules are adjusted in combination with the target chip cache structure to eliminate inefficient processing logic and determine the optimal combination of parameters and block strategy.

4. The method according to claim 1, characterized in that, Step S3 also includes: S3.

1. Based on the mathematical formulas, inputs, outputs, and attribute definitions of the operators, generate an algorithm demo based on NumPy to verify the algorithm logic and accuracy, covering both regular and special input scenarios; S3.

2. After the algorithm demo verification is passed, the operator code is generated according to the optimal parameter configuration and block strategy. At the same time, the corresponding test code and documentation are generated. The test code includes functional verification, boundary condition testing and abnormal input testing logic. S3.

3. If it is necessary to adapt to a specific deep learning framework, generate API interfaces and calling code that are compatible with that deep learning framework; S3.

4. When generating framework-compatible API interfaces and calling code, match the calling specifications and data format requirements of the deep learning framework, automatically detect the framework version and adapt to the corresponding interface standard, and ensure that operators can be directly integrated into the framework's computation process. The documentation covers operator usage instructions, parameter configuration guidelines, version compatibility instructions, and troubleshooting steps and solutions for common problems.

5. The method according to claim 1, characterized in that, Step S4 includes: S4.

1. Select the appropriate compilation method based on whether it is compatible with the deep learning framework, and compile the operator code into an executable file or a library file; S4.

2. Deploy the compiled files to the target environment. Before deployment, check the hardware configuration and dependent library versions of the target environment to ensure that the environment meets the running requirements and receive the incoming data and benchmarks. S4.

3. Calculate the absolute and relative errors between the actual output of the operator and the benchmark, and output the accuracy comparison results and the conclusion of whether the verification is passed according to the preset accuracy error standard; S4.

4. If the verification fails, based on the error type and magnitude analysis results, clarify the key points of debugging and the parameter adjustment path, associate the corresponding operator parameter adjustment items or block strategy block rule links, mark the key optimization points, and provide adjustment suggestions and parameter optimization range for subsequent optimization.

6. The method according to claim 1, characterized in that, In step S1, operator-related information is uploaded through a graphical interface or API interface. The graphical interface provides step-by-step information filling templates and real-time format verification prompts to guide users to fill in the information correctly. The API interface supports batch uploading, resuming interrupted uploads, and real-time feedback on upload status, including upload progress percentage, number of successful uploads, number of failed uploads, and the specific reason for each failure.

7. The method according to claim 1, characterized in that, In step S2, the computational characteristics of the analyzed operator include computational complexity, memory access pattern, and data parallelism. The impact weight of these characteristics on the operator execution efficiency is quantified by machine learning or deep learning models. Evaluation indicators such as computational efficiency improvement rate and memory usage reduction rate are set to provide data support for parameter optimization and block strategy design. At the same time, the specific technical aspects of characteristic analysis are adjusted in combination with the operator computation type.

8. The method according to claim 4, characterized in that, In step S3.2, the generated operator code covers all development scenarios, and selects an appropriate instruction set for the hardware architecture of the target chip, performs instruction rearrangement and redundant instruction removal, and adopts a data block storage strategy to optimize memory layout, reduce data transmission latency and memory usage, and ensure execution on the target chip. At the same time, the generated test code includes performance benchmark test logic, which can output operator execution time and resource usage data. The document also includes parameter adjustment examples and parameter configuration examples for different scenarios.

9. The method according to claim 5, characterized in that, In step S4.1, when there is no need for deep learning framework adaptation, the operator code is compiled into a run package containing executable files and dependency library files. The run package has a built-in environment detection script to detect the operating system version, hardware driver version, and necessary dependent components to ensure installation and operation on the target device. When there is a need for deep learning framework adaptation, the operator code is compiled into a whl package containing Python interfaces and dependency library files. The whl package is compatible with mainstream stable Python versions and automatically configures the framework call path and environment variables after installation, so that the framework can directly recognize and call the operator.

10. An automated operator development system based on artificial intelligence, used to execute the method as described in any one of claims 1-9, characterized in that, It includes an information collection module, a data analysis module, a code generation module, a compilation module, and a precision verification module; The information collection module is used to collect and parse information related to the storage operator. It also has information format verification, error prompts, information export and backup functions. When the uploaded information is incomplete or the format is incorrect, it will provide real-time feedback to the user and guide them to make corrections. It also supports exporting information in a specified format. The data analysis module is used to parse information related to the verification operator, perform multi-round parameter optimization and block strategy design through artificial intelligence algorithms, and adjust the direction of parameter optimization and block strategy adjustment based on the hardware characteristics of the target chip and the operator calculation type. It stores optimization process logs for traceability. The code generation module is used to generate algorithm demos, operator code, test code, documentation and framework adaptation-related code. When adapting to the framework, it automatically adapts to the version requirements of the framework and supports code format standardization to ensure compatibility and readability. The compilation module is used to compile operator code into corresponding executable files or library files according to adaptation requirements. It supports custom compilation options and outputs compilation process logs to facilitate troubleshooting compilation exceptions. The accuracy verification module is used to receive data and benchmarks, calculate absolute and relative errors, and output accuracy comparison results and verification conclusions. It can store historical accuracy comparison data and error trend analysis reports to provide a reference for subsequent operator optimization.