WO2021135467A1 - Automated machine learning-based ethereum fuel restriction prediction method, apparatus, computer device, and storage medium - Google Patents

Automated machine learning-based ethereum fuel restriction prediction method, apparatus, computer device, and storage medium Download PDF

Info

Publication number
WO2021135467A1
WO2021135467A1 PCT/CN2020/118901 CN2020118901W WO2021135467A1 WO 2021135467 A1 WO2021135467 A1 WO 2021135467A1 CN 2020118901 W CN2020118901 W CN 2020118901W WO 2021135467 A1 WO2021135467 A1 WO 2021135467A1
Authority
WO
WIPO (PCT)
Prior art keywords
smart contract
contract code
target
ethereum
machine learning
Prior art date
Application number
PCT/CN2020/118901
Other languages
French (fr)
Chinese (zh)
Inventor
张楠
王健宗
瞿晓阳
Original Assignee
平安科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2021135467A1 publication Critical patent/WO2021135467A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/213Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
    • G06F18/2135Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods based on approximation criteria, e.g. principal component analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/23Clustering techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Software Systems (AREA)
  • Computing Systems (AREA)
  • Business, Economics & Management (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Mathematical Physics (AREA)
  • Databases & Information Systems (AREA)
  • Finance (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Biophysics (AREA)
  • Molecular Biology (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Accounting & Taxation (AREA)
  • Medical Informatics (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

An Ethereum fuel restriction prediction method based on automated machine learning, an apparatus, a computer device, and a storage medium, relating to blockchain smart contract technology, and comprising: obtaining from among target network addresses the network addresses of all published Ethereum smart contracts so as to acquire a set of target smart contract codes having completed verification, and transaction information corresponding to each target smart contract code; after screening all transaction information, inputting corresponding feature set to an automated machine learning model for training of an automated machine learning model; if a current smart contract code is detected, obtaining the current feature set corresponding to the current smart contract code and inputting same to the automated machine learning model for calculation, and obtaining a corresponding Ethernet fuel restriction. The method realizes automatic dimensionality reduction of automatically-screened features on the basis of smart contract codes, so as to predict Ethereum fuel restrictions. Manual intervention is avoided, reducing labor costs, and prediction accuracy is improved.

Description

基于自动机器学习的以太坊燃料限制预测方法、装置、计算机设备及存储介质Ethereum fuel limit prediction method, device, computer equipment and storage medium based on automatic machine learning
本申请要求于2020年7月31日提交中国专利局、申请号为202010761121.3,发明名称为“基于自动机器学习的以太坊燃料限制预测方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on July 31, 2020, the application number is 202010761121.3, and the invention title is "Ethereum Fuel Restriction Prediction Method and Device Based on Automatic Machine Learning". The entire content of the application is approved The reference is incorporated in this application.
技术领域Technical field
本申请涉及区块链技术领域,尤其涉及一种基于自动机器学习的以太坊燃料限制预测方法、装置、计算机设备及存储介质。This application relates to the field of blockchain technology, and in particular to an Ethereum fuel limit prediction method, device, computer equipment, and storage medium based on automatic machine learning.
背景技术Background technique
作为区块链比较成功的项目-比特币,其最为核心的创新就是在不需要信任第三方的情况下可以远距离进行转移价值。但是比特币的缺点在于并没有支持图灵完备的脚本语言。也即比特币只做到在分布式环境的条件下存储,但是并没有做到在分布式条件下既能存储也能计算。针对这个问题,Vitalik等人推出以太坊。与比特币相比,以太坊最大的不同点在于以太坊是可以支持图灵完备的脚本语言,允许开发者在上面开发任意应用,实现智能合约。As a relatively successful blockchain project-Bitcoin, its core innovation is to transfer value from a long distance without trusting a third party. But the disadvantage of Bitcoin is that it does not support Turing's complete scripting language. That is to say, Bitcoin can only be stored in a distributed environment, but it has not been able to store and calculate in a distributed environment. In response to this problem, Vitalik and others launched Ethereum. Compared with Bitcoin, the biggest difference between Ethereum is that Ethereum is a Turing-complete scripting language that allows developers to develop any application on it and implement smart contracts.
以太坊在区块链上实现一个运行环境,被称为以太坊虚拟机。每个参与到以太坊网络的节点都会运行以太坊虚拟机作为区块验证协议的一部分。这些节点会验证区块中覆盖的每个交易并在以太坊虚拟机中运行交易所触发的代码(智能合约里面的代码)。每个网络上的全节点都会进行相同的计算并存储相同的值。而在执行这些代码和计算的过程中,每一个命令比如加法、hash等等都会有一个特定的消耗,在以太坊上用燃料来进行计数,例如在以太坊上进行加法的操作就需要消耗3个燃料。Ethereum implements an operating environment on the blockchain, which is called the Ethereum Virtual Machine. Every node participating in the Ethereum network will run the Ethereum virtual machine as part of the block verification protocol. These nodes will verify each transaction covered in the block and run the code triggered by the transaction (code in the smart contract) in the Ethereum virtual machine. All nodes on each network will perform the same calculations and store the same values. In the process of executing these codes and calculations, each command such as addition, hash, etc. will have a specific consumption. On Ethereum, fuel is used for counting. For example, the operation of adding on Ethereum needs to consume 3 Fuel.
由于在代码执行过程需要消耗一定的燃料,而且燃料的消耗还跟智能合约所在的状态有关系。因此在进行每一笔交易之前都用户预先支付一定数量的燃料。简单来说这个预先支付的金额在以太坊里被称为燃料限制。在网络上的节点进行认证和计算过程中,如果用户的交易用于计算需要使用的燃料数量小于或等于所设置的燃料限制,那么这个交易就会被处理。相反,如果燃料的总消耗超过燃料限制,用户所提供的燃料都会被使用完,甚至在这过程中所有的操作都会被复原。因此,保证燃料限制的精确就显得非常重要。Because a certain amount of fuel needs to be consumed in the code execution process, and the fuel consumption is also related to the state of the smart contract. Therefore, the user pays a certain amount of fuel in advance before each transaction. Simply put, this prepaid amount is called a fuel limit in Ethereum. In the process of authentication and calculation of nodes on the network, if the amount of fuel used for the calculation of the user's transaction is less than or equal to the set fuel limit, then the transaction will be processed. On the contrary, if the total fuel consumption exceeds the fuel limit, the fuel provided by the user will be used up, and even all operations in the process will be restored. Therefore, it is very important to ensure the accuracy of the fuel limit.
机器学习作为人工智能的一个分支,也是比较热门的研究话题。机器学习算法是一类从数据中自动分析获得规律,并利用规律对未知数据进行预测的算法。机器学习的最大优势是工作效率有大幅度的提高。机器学习无法解决人类解决不了的问题,但是它可以接受大量的数据,基于数据迅速建立连接,做出预测。因此在收集到大量数据的情况下,用机器学习来做预测是效率比较高而且是比较准确的。而当前以太坊就已经有数千万个交易了。用机器学习来发现这些数据中的规律无疑是一种比较好的办法。因此,用机器学习来预测以太坊上交易的燃料限制是可行的。但是对于以太坊交易程序数据来说包含智能合约URL,发明人意识到特征不明显,手动特征工程和手动选择机器学习模型工作量较大且难以保证通用性和准确率。As a branch of artificial intelligence, machine learning is also a hot research topic. Machine learning algorithm is a kind of algorithm that automatically analyzes and obtains rules from data, and uses the rules to predict unknown data. The biggest advantage of machine learning is that work efficiency is greatly improved. Machine learning cannot solve problems that humans cannot solve, but it can accept a large amount of data, quickly establish connections based on the data, and make predictions. Therefore, when a large amount of data is collected, using machine learning to make predictions is more efficient and more accurate. There are already tens of millions of transactions in Ethereum today. It is undoubtedly a better way to use machine learning to discover the laws in these data. Therefore, it is feasible to use machine learning to predict the fuel limit of transactions on Ethereum. But for the Ethereum transaction program data including the smart contract URL, the inventor realized that the features are not obvious. Manual feature engineering and manual selection of machine learning models require a lot of work and it is difficult to ensure versatility and accuracy.
发明内容Summary of the invention
本申请实施例提供了一种基于自动机器学习的以太坊燃料限制预测方法、装置、计算机设备及存储介质,旨在解决现有技术中以太坊交易程序数据包含智能合约的网络地址,数据特征不明显,手动特征工程和手动选择机器学习模型工作量较大,且难以保证通用性和准确率的问题。The embodiments of the application provide an Ethereum fuel limit prediction method, device, computer equipment, and storage medium based on automatic machine learning, aiming to solve the problem that the Ethereum transaction program data in the prior art includes the network address of the smart contract, and the data characteristics are not Obviously, manual feature engineering and manual selection of machine learning models require a lot of work, and it is difficult to ensure versatility and accuracy.
第一方面,本申请实施例提供了一种基于自动机器学习的以太坊燃料限制预测方法,其包括:In the first aspect, an embodiment of the present application provides an Ethereum fuel limit prediction method based on automatic machine learning, which includes:
调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
第二方面,本申请实施例提供了一种基于自动机器学习的以太坊燃料限制预测装置,其包括:In the second aspect, an embodiment of the present application provides an Ethereum fuel limit prediction device based on automatic machine learning, which includes:
目标网络地址获取单元,用于调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;The target network address acquisition unit is used to call the preset stored breadth-first algorithm and the preset target URL, and obtain the network of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm address;
目标代码集合获取单元,用于根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;The target code collection obtaining unit is configured to obtain the verified target smart contract code collection and transaction information corresponding to each target smart contract code in the target smart contract code collection according to the network address;
特征集获取单元,用于调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;The feature set acquisition unit is used to call a pre-stored information field screening strategy, and after information screening is performed on the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening The strategy is used to filter the core features of the transaction information corresponding to the smart contract code to form a feature set;
自动机器学习模型训练单元,用于获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;The automatic machine learning model training unit is used to obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein, the automatic machine learning model is used to predict the smart contract The fuel limit for calling functions;
当前特征集获取单元,用于若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及The current feature set obtaining unit is configured to, if the current smart contract code uploaded by the user terminal is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
燃料限制预测单元,用于将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。The fuel limit prediction unit is used to input the current feature set into the automatic machine learning model to perform calculations to obtain the Ethereum fuel limit corresponding to the current smart contract code, and calculate the Ethereum fuel limit corresponding to the current smart contract code. The fuel limit is sent to the corresponding target receiver.
第三方面,本申请实施例又提供了一种计算机设备,其包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现以下步骤:In a third aspect, an embodiment of the present application provides a computer device, which includes a memory, a processor, and a computer program stored on the memory and running on the processor, and the processor executes the computer The following steps are implemented during the program:
调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein, the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目 标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
第四方面,本申请实施例还提供了一种计算机可读存储介质,其中所述计算机可读存储介质存储有计算机程序,所述计算机程序当被处理器执行时使所述处理器执行以下操作:In a fourth aspect, the embodiments of the present application also provide a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, which when executed by a processor causes the processor to perform the following operations :
调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
本申请实施例提供了一种基于自动机器学习的以太坊燃料限制预测方法、装置、计算机设备及存储介质,包括通过广度优先算法对应的广度优先搜索从目标网址中获取在以太坊上已发布所有智能合约的网络地址;根据网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;调用信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;若检测到用户端上传的当前智能合约代码,根据信息字段筛选策略获取当前智能合约代码对应的当前特征集;将当前特征集输入至自动机器学习模型中进行运算,得到当前智能合约代码对应的以太坊燃料限制,将当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。实现了基于智能合约代码自动筛选特征自动降维后,以对以太坊燃料限制进行预测,不仅避免了人工干预从而降低人工成本,而且提高了预测的准确率。The embodiment of the application provides an Ethereum fuel limit prediction method, device, computer equipment and storage medium based on automatic machine learning, including the breadth-first search corresponding to the breadth-first algorithm to obtain from the target URL all published on Ethereum The network address of the smart contract; according to the network address, obtain the target smart contract code set that has been verified, and the transaction information corresponding to each target smart contract code in the target smart contract code set; call the information field screening strategy, and the target smart contract code After the corresponding transaction information is filtered, the feature set corresponding to each target smart contract code is obtained; the feature set corresponding to each target smart contract code is obtained and input to the automatic machine learning model to be trained for training, and the automatic machine learning model is obtained; Upload the current smart contract code to the client, and obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; input the current feature set into the automatic machine learning model for calculation, and obtain the Ethereum fuel corresponding to the current smart contract code Limit, send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target receiver. After realizing the automatic dimensionality reduction based on the automatic screening of the smart contract code, the Ethereum fuel limit is predicted, which not only avoids manual intervention and reduces labor costs, but also improves the accuracy of prediction.
附图说明Description of the drawings
为了更清楚地说明本申请实施例技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to explain the technical solutions of the embodiments of the present application more clearly, the following will briefly introduce the drawings used in the description of the embodiments. Obviously, the drawings in the following description are some embodiments of the present application. Ordinary technicians can obtain other drawings based on these drawings without creative work.
图1为本申请实施例提供的基于自动机器学习的以太坊燃料限制预测方法的应用场景示意图;FIG. 1 is a schematic diagram of an application scenario of an Ethereum fuel limit prediction method based on automatic machine learning provided by an embodiment of the application;
图2为本申请实施例提供的基于自动机器学习的以太坊燃料限制预测方法的流程示意图;FIG. 2 is a schematic flowchart of an Ethereum fuel limit prediction method based on automatic machine learning provided by an embodiment of the application;
图3为本申请实施例提供的基于自动机器学习的以太坊燃料限制预测装置的示意性框图;3 is a schematic block diagram of an Ethereum fuel limit prediction device based on automatic machine learning provided by an embodiment of the application;
图4为本申请实施例提供的计算机设备的示意性框图。Fig. 4 is a schematic block diagram of a computer device provided by an embodiment of the application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be described clearly and completely in conjunction with the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of them. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative work shall fall within the protection scope of this application.
应当理解,当在本说明书和所附权利要求书中使用时,术语“包括”和“包含”指示所描述 特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。It should be understood that when used in this specification and appended claims, the terms "including" and "including" indicate the existence of the described features, wholes, steps, operations, elements and/or components, but do not exclude one or The existence or addition of multiple other features, wholes, steps, operations, elements, components, and/or collections thereof.
还应当理解,在此本申请说明书中所使用的术语仅仅是出于描述特定实施例的目的而并不意在限制本申请。如在本申请说明书和所附权利要求书中所使用的那样,除非上下文清楚地指明其它情况,否则单数形式的“一”、“一个”及“该”意在包括复数形式。It should also be understood that the terms used in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit the application. As used in the specification of this application and the appended claims, unless the context clearly indicates other circumstances, the singular forms "a", "an" and "the" are intended to include plural forms.
还应当进一步理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。It should be further understood that the term "and/or" used in the specification and appended claims of this application refers to any combination and all possible combinations of one or more of the associated listed items, and includes these combinations .
请参阅图1和图2,图1为本申请实施例提供的基于自动机器学习的以太坊燃料限制预测方法的应用场景示意图;图2为本申请实施例提供的基于自动机器学习的以太坊燃料限制预测方法的流程示意图,该基于自动机器学习的以太坊燃料限制预测方法应用于服务器中,该方法通过安装于服务器中的应用软件进行执行。Please refer to Figures 1 and 2. Figure 1 is a schematic diagram of an application scenario of an Ethereum fuel limit prediction method based on automatic machine learning provided by an embodiment of this application; Figure 2 is an Ethereum fuel based on automatic machine learning provided by an embodiment of this application Schematic diagram of the flow of the restriction prediction method. The Ethereum fuel restriction prediction method based on automatic machine learning is applied to the server, and the method is executed by the application software installed in the server.
如图2所示,该方法包括步骤S110~S160。As shown in Figure 2, the method includes steps S110 to S160.
S110、调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址。S110: Call a preset stored breadth-first algorithm and a preset target URL, and obtain network addresses of all smart contracts that have been published on Ethereum from the target URL through a breadth-first search corresponding to the breadth-first algorithm.
在本实施例中,在目标网址(目标网址具体实施为http://etherscan.io/)上存储有以太坊上已验证过的智能合约和与这些智能合约相关的交易信息,通过广度优先算法对应的广度优先搜索可以从目标网址的各级网页内容中采集到在以太坊上已发布所有智能合约的网络地址。通过广度优先搜索方式,实现了对在以太坊上已发布所有智能合约的网络地址的遍历式获取,获取的网络地址集合数据量也更丰富。In this embodiment, the target URL (the target URL is specifically implemented as http://etherscan.io/) stores the verified smart contracts on Ethereum and the transaction information related to these smart contracts, and the breadth-first algorithm The corresponding breadth-first search can collect the network addresses of all smart contracts that have been published on Ethereum from the content of the web pages at all levels of the target URL. Through the breadth-first search method, the traversal acquisition of the network addresses of all smart contracts that have been published on Ethereum is realized, and the amount of collected network address collection data is also richer.
在一实施例中,步骤S110包括:In an embodiment, step S110 includes:
获取所述目标网址的第一级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第一级网络地址集;Obtain all the network addresses of all smart contracts that have been published on Ethereum in the first-level webpage of the target URL to form a first-level network address set;
访问所有与第一级网页相邻接的第二级网页,并获取第二级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第二级网络地址集;依序访问所有与第二级网页相邻接的第三级网页直至访问至访问所有与第n-1级网页相邻接的第n级网页,以分别获取第三级网络地址集至第n级网络地址集;其中,n的取值与所述目标网址的总网页级数相等;Visit all the second-level webpages adjacent to the first-level webpage, and obtain all the network addresses of all smart contracts that have been published on Ethereum in the second-level webpage to form a second-level network address set; visit all in order The third-level webpage adjacent to the second-level webpage until the access to all the nth-level webpages adjacent to the n-1th-level webpage to obtain the third-level network address set to the nth-level network address set respectively ; Wherein, the value of n is equal to the total page level of the target URL;
由所述第一级网络地址集至第n级网络地址集组成所述目标网址中在以太坊上已发布所有智能合约的网络地址。The first-level network address set to the nth-level network address set form the network addresses of all smart contracts that have been published on Ethereum in the target URL.
在本实施例中,广度优先搜索算法(又称宽度优先搜索)是最简便的图的搜索算法之一,这一算法也是很多重要的图的算法的原型。广度优先算法的核心思想是:从初始节点开始,应用算符生成第一层节点,检查目标节点是否在这些后继节点中,若没有,再用产生式规则将所有第一层的节点逐一扩展,得到第二层节点,并逐一检查第二层节点中是否包含目标节点。若没有,再用算符逐一扩展第二层的所有节点……,如此依次扩展,检查下去,直到发现目标节点为止。使用广度优先算法,寻找深度小,而且每个结点只访问一遍,结点总是以最短路径被访问,这样提高了获取在以太坊上已发布所有智能合约的网络地址的效率。In this embodiment, the breadth-first search algorithm (also called breadth-first search) is one of the simplest graph search algorithms, and this algorithm is also the prototype of many important graph algorithms. The core idea of the breadth-first algorithm is: starting from the initial node, apply operators to generate the first-level nodes, check whether the target node is among these subsequent nodes, and if not, use production rules to expand all the first-level nodes one by one. Get the second-level nodes, and check whether the second-level nodes contain the target node one by one. If not, use the operator to expand all the nodes of the second layer one by one..., expand in this way, and check until the target node is found. Using the breadth-first algorithm, the search depth is small, and each node is only visited once, and the node is always accessed by the shortest path, which improves the efficiency of obtaining the network addresses of all smart contracts that have been published on Ethereum.
S120、根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息。S120: Obtain, according to the network address, a target smart contract code set that has been verified, and transaction information corresponding to each target smart contract code in the target smart contract code set.
在本实施例中,目标网址上已完成验证的智能合约是被打上了已验证的标签的,此时可以快速筛选出具有已验证标签的智能合约代码,以组成目标智能合约代码集合。每一智能合约对应的交易信息有多个字段取值,这些字段取值中可能全部对燃料限制预测相关,也有可能是部分对燃料限制预测相关,后续步骤中需对智能合约对应的交易信息中核心字段进行筛选。In this embodiment, the smart contract that has been verified on the target website is tagged with a verified tag. At this time, smart contract codes with verified tags can be quickly screened out to form a target smart contract code set. The transaction information corresponding to each smart contract has multiple field values. The values of these fields may all be related to fuel limit prediction, or some of them may be related to fuel limit prediction. In the subsequent steps, the transaction information corresponding to the smart contract needs to be included. Core fields are filtered.
在一实施例中,步骤S120包括:In an embodiment, step S120 includes:
将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储;Name and store each target smart contract code in the target smart contract code set for which the network address has been obtained and verified;
获取各目标智能合约代码的交易信息中所包括的交易所在区块高度、交易的hash值、燃 料限制、单独执行本交易实际所用到的燃料、交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。Obtain the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the input data of the exchange function used in the transaction information of each target smart contract code; among them, the exchange The input data using the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction.
在本实施例中,由于部分智能合约在区块链上存在着几个版本,版本名称都是相同的但每个版本的代码可能不相同。此时采用的是以智能合约名称+智能合约版本号+智能合约上传时间的方式命名,这样对由相同版本名称但代码不同的智能合约通过命名不同以区分。In this embodiment, since there are several versions of some smart contracts on the blockchain, the version names are the same, but the code of each version may be different. At this time, the name is based on the smart contract name + smart contract version number + smart contract upload time, so that smart contracts with the same version name but different codes can be distinguished by different names.
获取智能合约的交易信息主要包括:交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。根据对数据重要性分析可知,一般交易所使用函数的输入数据对燃料限制预测相关性最大,故可以设置用于筛选出目标智能合约代码中核心字段取值的信息字段筛选策略便于后续实用。Obtaining the transaction information of the smart contract mainly includes: the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the input data of the exchange to use the function of the exchange; among them, the exchange uses The input data of the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction. According to the analysis of the importance of data, the input data of the general exchange use function has the most relevance to the fuel limit prediction, so you can set the information field filtering strategy for filtering out the value of the core field in the target smart contract code for subsequent practical use.
S130、调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集。S130. Invoke a pre-stored information field screening strategy, and after information screening is performed on the transaction information corresponding to each target smart contract code, a feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen intelligence The core features in the transaction information corresponding to the contract code constitute a feature set.
在本实施例中,由于各目标智能合约代码对应的交易信息包括的字段较多,为了降低数据维度,可以将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集。In this embodiment, since the transaction information corresponding to each target smart contract code includes many fields, in order to reduce the data dimension, the transaction information corresponding to each target smart contract code can be filtered to obtain the corresponding target smart contract code. The corresponding feature set.
在一实施例中,步骤S130包括:In an embodiment, step S130 includes:
获取所述信息字段筛选策略中包括的核心特征字段集;其中,所述核心特征字段集包括交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段;Obtain the core feature field set included in the information field screening strategy; wherein, the core feature field set includes the block height field of the exchange, the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function field, and the exchange execution The FOR loop count field in the function and the number field of the variable in the transaction;
将每一目标智能合约代码对应的交易信息根据所述核心特征字段集进行信息筛选,得到各目标智能合约代码对应的特征集。The transaction information corresponding to each target smart contract code is filtered according to the core feature field set, and the feature set corresponding to each target smart contract code is obtained.
在本实施例中,在以太坊虚拟机环境下,每进行一个操作都要消耗部分的燃料,例如以太坊上进行加法的操作就需要消耗3个燃料等。上述举例的是单个操作所消耗的燃料,智能合约代码中所涉及函数所消耗的燃料并不是上述数据操作对应消耗燃料相加求和。但已知的是,通过所述信息字段筛选策略中包括的核心特征字段对应取值,是与燃料消耗呈正相关的关系。In this embodiment, in the Ethereum virtual machine environment, each operation needs to consume part of the fuel. For example, an addition operation on the Ethereum needs to consume 3 fuels and so on. The above example is the fuel consumed by a single operation. The fuel consumed by the functions involved in the smart contract code is not the sum of the fuel consumed by the above data operations. However, it is known that the corresponding values of the core feature fields included in the information field screening strategy are positively correlated with fuel consumption.
具体实施时,与燃料消耗呈正相关的关系的核心特征字段有交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段,将所述信息字段筛选策略中设置为用于从特征集中筛选包括的核心特征字段的对应取值。将每一目标智能合约代码对应的交易信息相应进行字段筛选后,所得到的筛选结果即是各目标智能合约代码对应的特征集。通过这一筛选过程,有效对数据特征进行了降维。In specific implementation, the core feature fields that are positively related to fuel consumption include the exchange block height field, the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR cycles in the exchange execution function, and the transaction. The number field of the middle variable is set in the information field screening strategy to be used to screen the corresponding values of the core feature fields included in the feature set. After the transaction information corresponding to each target smart contract code is screened accordingly, the result of the screening is the feature set corresponding to each target smart contract code. Through this screening process, the data features are effectively reduced in dimensionality.
S140、获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制。S140. Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract.
在本实施例中,机器学习是让算法自动的从数据中找出一组规则,从而提取数据中对分类/聚类/决策有帮助的特征,随着机器学习的发展,其中人工需要干预的部分越来越多,而AutoML(即自动机器学习)则是对机器学习模型从构建到应用的全过程自动化,最终得出端对端的模型(end to end)。In this embodiment, machine learning allows the algorithm to automatically find a set of rules from the data, so as to extract the features of the data that are helpful for classification/clustering/decision-making. With the development of machine learning, manual intervention is required. There are more and more parts, and AutoML (that is, automatic machine learning) automates the entire process of machine learning models from construction to application, and finally an end-to-end model (end to end) is obtained.
机器学习的应用需要大量的人工干预,这些人工干预表现在:特征提取、模型选择、参数调节等机器学习的各个方面。自动机器学习(AutoML)试图将这些与特征、模型、优化、评价有关的重要步骤进行自动化地学习,使得机器学习模型无需人工干预即可被应用。The application of machine learning requires a lot of manual intervention, which is manifested in various aspects of machine learning such as feature extraction, model selection, and parameter adjustment. Automatic machine learning (AutoML) attempts to learn these important steps related to features, models, optimization, and evaluation automatically, so that machine learning models can be applied without manual intervention.
对于交易燃料预测任务而言,输入数据结构较复杂,还包含代码文本等难以量化的特征, 使用传统的机器学习回归方法无法直接接受文本作为特征,在进行特征工程和模型选择时难度也较大,若使用自动化机器学习方法问题难度可大大减小。For transaction fuel prediction tasks, the input data structure is complex, and it also contains features that are difficult to quantify such as code text. Traditional machine learning regression methods cannot directly accept text as features, and it is difficult to perform feature engineering and model selection. , If you use automated machine learning methods, the difficulty of the problem can be greatly reduced.
在一实施例中,步骤S140包括:In an embodiment, step S140 includes:
调用预先存储的主分量分析算法,以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集;Call the pre-stored principal component analysis algorithm to select the main feature of the feature set corresponding to each target smart contract code, and obtain the dimensionality reduction feature set corresponding to each feature set;
将待训练自动机器学习模型根据所述降维特征集依次进行模型训练、模型选择/组合及超参数调优,得到自动机器学习模型。The automatic machine learning model to be trained is sequentially subjected to model training, model selection/combination, and hyperparameter tuning according to the dimensionality reduction feature set to obtain an automatic machine learning model.
在本实施例中,主分量分析算法即PCA,主要用于数据降维。在训练自动机器学习模型的过程中,训练集的数据维度可以不用太多,此时可以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集,从而实现数据降维。In this embodiment, the principal component analysis algorithm, PCA, is mainly used for data dimensionality reduction. In the process of training the automatic machine learning model, the data dimension of the training set can not be too much. At this time, the main feature selection can be performed on the feature set corresponding to each target smart contract code, and the dimensionality reduction feature set corresponding to each feature set can be obtained. Realize data dimensionality reduction.
之后根据降维特征集对待训练自动机器学习模型依次进行模型训练、模型选择/组合及超参数调优,即可得到自动机器学习模型。Then, according to the dimensionality reduction feature set, the automatic machine learning model to be trained is sequentially performed model training, model selection/combination, and hyperparameter tuning to obtain the automatic machine learning model.
从自动机器学习的流程先后顺序来分,最初是数据准备,包括数据收集和清洗,之后是特征工程,其中包括特征选择,特征提取(对特征进行降维,常用的方法例如PCA),特征组合(将多个特征合并/构建为一个新的特征);在之后的模型构建中,最关键的是模型选择,之后超参数优化,可以采取很多方式,最简单的做法是网格搜索,常用的方法包括用强化学习,进化算法,贝叶斯优化,以及梯度下降,来缩小搜索空间;最后,AutoML通过引入提前停止,降低模型的精度,参数共享来自动化模型评价的过程。From the sequence of the automatic machine learning process, it is initially data preparation, including data collection and cleaning, and then feature engineering, which includes feature selection, feature extraction (reducing features, commonly used methods such as PCA), and feature combination (Combine/construct multiple features into a new feature); In the subsequent model construction, the most critical is model selection. After hyperparameter optimization, many methods can be adopted. The simplest method is grid search, which is commonly used. Methods include reinforcement learning, evolutionary algorithms, Bayesian optimization, and gradient descent to narrow the search space; finally, AutoML automates the process of model evaluation by introducing early stopping, reducing the accuracy of the model, and sharing parameters.
数据收集这项任务,不在是搜索与收集真实数据,还包括产生模拟数据,用来扩展训练数据集,可以使用的新技术包括对抗神经网络,还可以使用强化学习的框架,来优化用于控制生成数据的参数,从而使得生成的数据能更有效的助力模型的训练。而数据清洗则是自动完成包括缺失值补全,离群点处理,特征归一化,类别型特征的不同编码等之前手动完成的工作。The task of data collection is not to search and collect real data, but also to generate simulation data to expand the training data set. New technologies that can be used include countering neural networks, and reinforcement learning frameworks can also be used to optimize control. The parameters of the generated data, so that the generated data can more effectively assist the training of the model. The data cleaning is to automatically complete the work that was manually completed before including missing value completion, outlier processing, feature normalization, and different coding of categorical features.
模型的自动化选择,传统的方法是从传统的模型,例如KNN,SVM,决策树中选出一个,或多个组合起来效果最好的模型,而当前AutoML的研究热点是神经架构搜索(英文全称是Neural Architecture Search),也就是不经过人工干预,模型自动生成一个对当前任务最有效的网络结构。For automatic model selection, the traditional method is to select one or more models from traditional models, such as KNN, SVM, and decision trees, or combine them with the best model. The current research hotspot of AutoML is neural architecture search. It is Neural Architecture Search), that is, without manual intervention, the model automatically generates a network structure that is most effective for the current task.
模型选定后的调参过程,最常用的是网格搜索,也就是按照固定的间距,在搜索空间上打点,AutoML会使用随机抽样,首先评价各个超参数的重要性,之后再对重要的参数进行微调。After the model is selected, the most commonly used is the grid search, that is, according to a fixed interval, in the search space, AutoML will use random sampling, first evaluate the importance of each hyperparameter, and then focus on the important The parameters are fine-tuned.
通过降维特征集对待训练自动机器学习模型进行训练后,即可得到用于预测智能合约所调用函数的燃料限制的自动机器学习模型。After the automatic machine learning model to be trained is trained through the dimensionality reduction feature set, an automatic machine learning model for predicting the fuel limit of the function called by the smart contract can be obtained.
S150、若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集。S150: If the current smart contract code uploaded by the user terminal is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy.
在本实施例中,为了预测其他智能合约代码对应的以太坊燃料限制,此时可以直接由用户在用户端上操作录入当前智能合约代码,之后由用户端将当前智能合约代码发送至服务器中,以由服务器中进行燃料限制预测的数据预处理。此时,也可参考步骤S130中,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集。通过这一精简后的当前特征集进行预测,有效降低数据维度,使得后续预测的效率得到提高。In this embodiment, in order to predict the Ethereum fuel limit corresponding to other smart contract codes, the user can directly input the current smart contract code on the user side at this time, and then the user side sends the current smart contract code to the server. Pre-processing the fuel limit prediction data by the server. At this time, reference may also be made to step S130 to obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy. Prediction through this streamlined current feature set effectively reduces the data dimension and improves the efficiency of subsequent predictions.
S160、将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。S160. Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding The target receiver.
在本实施例中,将所述当前特征集输入至所述自动机器学习模型中进行运算,通过自动机器学习模型即可提取当前特征集中各函数或是数据操作对应消耗的燃料限制,从而精准预测出所述当前智能合约代码对应的以太坊燃料限制。此时为了及时的通知用户端预测结果,可将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。In this embodiment, the current feature set is input to the automatic machine learning model for calculation, and the automatic machine learning model can extract the fuel consumption limit corresponding to each function or data operation in the current feature set, thereby accurately predicting Get the Ethereum fuel limit corresponding to the current smart contract code. At this time, in order to timely notify the user of the prediction result, the Ethereum fuel limit corresponding to the current smart contract code can be sent to the corresponding target receiving end.
在一实施例中,步骤S160包括:In an embodiment, step S160 includes:
将所述当前特征集根据所述主分量分析算法进行主特征选择,获取与所述当前特征集对应的当前降维特征集;Performing main feature selection on the current feature set according to the principal component analysis algorithm, and obtaining a current dimensionality reduction feature set corresponding to the current feature set;
将所述当前降维特征集输入至所述自动机器学习模型中的模型选择模型进行运算,得到目标模型;Inputting the current dimensionality reduction feature set to the model selection model in the automatic machine learning model for calculation to obtain a target model;
将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制。The current feature set is input to the target model for calculation, and the Ethereum fuel limit corresponding to the current smart contract code is obtained.
在本实施例中,在通过自动机器学习进行燃料限制预测,其主要是实现了模型的自动化选择,传统的方法是从传统的模型中选出一个或多个组合起来效果最好的模型,而当前AutoML可通过神经架构搜索,也就是不经过人工干预,模型自动生成一个对当前任务最有效的网络结构,这就极大的提高了预测结果的准确度。In this embodiment, when the fuel limit prediction is performed through automatic machine learning, it mainly realizes the automatic selection of models. The traditional method is to select one or more models with the best combination effect from the traditional models, and Currently, AutoML can search through neural architecture, that is, without manual intervention, the model automatically generates a network structure that is most effective for the current task, which greatly improves the accuracy of the prediction results.
该方法实现了基于智能合约代码自动筛选特征自动降维后,以对以太坊燃料限制进行预测,不仅避免了人工干预从而降低人工成本,而且提高了预测的准确率。This method realizes the automatic dimensionality reduction based on the automatic screening of the smart contract code to predict the Ethereum fuel limit, which not only avoids manual intervention and reduces labor costs, but also improves the accuracy of the prediction.
本申请实施例还提供一种基于自动机器学习的以太坊燃料限制预测装置,该基于自动机器学习的以太坊燃料限制预测装置用于执行前述基于自动机器学习的以太坊燃料限制预测方法的任一实施例。具体地,请参阅图3,图3是本申请实施例提供的基于自动机器学习的以太坊燃料限制预测装置的示意性框图。该基于自动机器学习的以太坊燃料限制预测装置100可以配置于服务器中。The embodiment of the present application also provides an Ethereum fuel limit prediction device based on automatic machine learning. The Ethereum fuel limit prediction device based on automatic machine learning is used to execute any of the aforementioned methods for predicting Ethereum fuel limit based on automatic machine learning. Examples. Specifically, please refer to FIG. 3, which is a schematic block diagram of an Ethereum fuel limit prediction device based on automatic machine learning provided by an embodiment of the present application. The Ethereum fuel limit prediction device 100 based on automatic machine learning can be configured in a server.
如图3所示,基于自动机器学习的以太坊燃料限制预测装置100包括:目标网络地址获取单元110、目标代码集合获取单元120、特征集获取单元130、自动机器学习模型训练单元140、当前特征集获取单元150、燃料限制预测单元160。As shown in FIG. 3, the Ethereum fuel limit prediction device 100 based on automatic machine learning includes: a target network address acquisition unit 110, a target code set acquisition unit 120, a feature set acquisition unit 130, an automatic machine learning model training unit 140, and current features The set acquisition unit 150 and the fuel limit prediction unit 160.
目标网络地址获取单元110,用于调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址。The target network address obtaining unit 110 is used to call a preset stored breadth-first algorithm and a preset target URL, and obtain the information of all smart contracts that have been published on Ethereum from the target URL through a breadth-first search corresponding to the breadth-first algorithm website address.
在本实施例中,在目标网址(目标网址具体实施为http://etherscan.io/)上存储有以太坊上已验证过的智能合约和与这些智能合约相关的交易信息,通过广度优先算法对应的广度优先搜索可以从目标网址的各级网页内容中采集到在以太坊上已发布所有智能合约的网络地址。通过广度优先搜索方式,实现了对在以太坊上已发布所有智能合约的网络地址的遍历式获取,获取的网络地址集合数据量也更丰富。In this embodiment, the target URL (the target URL is specifically implemented as http://etherscan.io/) stores the verified smart contracts on Ethereum and the transaction information related to these smart contracts, and the breadth-first algorithm The corresponding breadth-first search can collect the network addresses of all smart contracts that have been published on Ethereum from the content of the web pages at all levels of the target URL. Through the breadth-first search method, the traversal acquisition of the network addresses of all smart contracts that have been published on Ethereum is realized, and the amount of collected network address collection data is also richer.
在一实施例中,目标网络地址获取单元110包括:In an embodiment, the target network address obtaining unit 110 includes:
第一级获取单元,用于获取所述目标网址的第一级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第一级网络地址集;The first-level obtaining unit is used to obtain all the network addresses of all smart contracts that have been published on Ethereum in the first-level webpage of the target URL to form a first-level network address set;
遍历下一级获取单元,用于访问所有与第一级网页相邻接的第二级网页,并获取第二级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第二级网络地址集;依序访问所有与第二级网页相邻接的第三级网页直至访问至访问所有与第n-1级网页相邻接的第n级网页,以分别获取第三级网络地址集至第n级网络地址集;其中,n的取值与所述目标网址的总网页级数相等;Traverse the next-level acquisition unit to access all second-level webpages adjacent to the first-level webpage, and obtain all the network addresses of all smart contracts that have been published on Ethereum in the second-level webpage to form a second-level webpage. Level network address set; sequentially visit all third-level webpages adjacent to the second-level webpage until accessing all nth-level webpages adjacent to the n-1th-level webpage to obtain the third-level network respectively The address set to the nth-level network address set; wherein the value of n is equal to the total number of page levels of the target URL;
网络地址组合单元,用于由所述第一级网络地址集至第n级网络地址集组成所述目标网址中在以太坊上已发布所有智能合约的网络地址。The network address combination unit is configured to form the network addresses of all smart contracts that have been published on Ethereum in the target URL from the first-level network address set to the nth-level network address set.
在本实施例中,广度优先搜索算法(又称宽度优先搜索)是最简便的图的搜索算法之一,这一算法也是很多重要的图的算法的原型。广度优先算法的核心思想是:从初始节点开始,应用算符生成第一层节点,检查目标节点是否在这些后继节点中,若没有,再用产生式规则将所有第一层的节点逐一扩展,得到第二层节点,并逐一检查第二层节点中是否包含目标节点。若没有,再用算符逐一扩展第二层的所有节点……,如此依次扩展,检查下去,直到发现目标节点为止。使用广度优先算法,寻找深度小,而且每个结点只访问一遍,结点总是以最短路径被访问,这样提高了获取在以太坊上已发布所有智能合约的网络地址的效率。In this embodiment, the breadth-first search algorithm (also called breadth-first search) is one of the simplest graph search algorithms, and this algorithm is also the prototype of many important graph algorithms. The core idea of the breadth-first algorithm is: starting from the initial node, apply operators to generate the first-level nodes, check whether the target node is among these subsequent nodes, and if not, use production rules to expand all the first-level nodes one by one. Get the second-level nodes, and check whether the second-level nodes contain the target node one by one. If not, use the operator to expand all the nodes of the second layer one by one..., expand in this way, and check until the target node is found. Using the breadth-first algorithm, the search depth is small, and each node is only visited once, and the node is always accessed by the shortest path, which improves the efficiency of obtaining the network addresses of all smart contracts that have been published on Ethereum.
目标代码集合获取单元120,用于根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息。The target code set obtaining unit 120 is configured to obtain a verified target smart contract code set and transaction information corresponding to each target smart contract code in the target smart contract code set according to the network address.
在本实施例中,目标网址上已完成验证的智能合约是被打上了已验证的标签的,此时可以快速筛选出具有已验证标签的智能合约代码,以组成目标智能合约代码集合。每一智能合约对应的交易信息有多个字段取值,这些字段取值中可能全部对燃料限制预测相关,也有可能是部分对燃料限制预测相关,后续步骤中需对智能合约对应的交易信息中核心字段进行筛选。In this embodiment, the smart contract that has been verified on the target website is tagged with a verified tag. At this time, smart contract codes with verified tags can be quickly screened out to form a target smart contract code set. The transaction information corresponding to each smart contract has multiple field values. The values of these fields may all be related to fuel limit prediction, or some of them may be related to fuel limit prediction. In the subsequent steps, the transaction information corresponding to the smart contract needs to be included. Core fields are filtered.
在一实施例中,目标代码集合获取单元120包括:In an embodiment, the target code set obtaining unit 120 includes:
命名存储单元,用于将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储;The naming storage unit is used to respectively name and store each target smart contract code in the target smart contract code set for which the network address has been verified;
交易信息解析获取单元,用于获取各目标智能合约代码的交易信息中所包括的交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。The transaction information analysis and acquisition unit is used to acquire the block height of the exchange included in the transaction information of each target smart contract code, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the function used by the exchange The input data of the function used by the exchange includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction.
在本实施例中,由于部分智能合约在区块链上存在着几个版本,版本名称都是相同的但每个版本的代码可能不相同。此时采用的是以智能合约名称+智能合约版本号+智能合约上传时间的方式命名,这样对由相同版本名称但代码不同的智能合约通过命名不同以区分。In this embodiment, since there are several versions of some smart contracts on the blockchain, the version names are the same, but the code of each version may be different. At this time, the name is based on the smart contract name + smart contract version number + smart contract upload time, so that smart contracts with the same version name but different codes can be distinguished by different names.
获取智能合约的交易信息主要包括:交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。根据对数据重要性分析可知,一般交易所使用函数的输入数据对燃料限制预测相关性最大,故可以设置用于筛选出目标智能合约代码中核心字段取值的信息字段筛选策略便于后续实用。Obtaining the transaction information of the smart contract mainly includes: the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the input data of the exchange to use the function of the exchange; among them, the exchange uses The input data of the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction. According to the analysis of the importance of data, the input data of the general exchange use function has the most relevance to the fuel limit prediction, so you can set the information field filtering strategy for filtering out the value of the core field in the target smart contract code for subsequent practical use.
特征集获取单元130,用于调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集。The feature set acquisition unit 130 is configured to call a pre-stored information field screening strategy, and after information screening is performed on the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field The screening strategy is used to screen the core features of the transaction information corresponding to the smart contract code to form a feature set.
在本实施例中,由于各目标智能合约代码对应的交易信息包括的字段较多,为了降低数据维度,可以将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集。In this embodiment, since the transaction information corresponding to each target smart contract code includes many fields, in order to reduce the data dimension, the transaction information corresponding to each target smart contract code can be filtered to obtain the corresponding target smart contract code. The corresponding feature set.
在一实施例中,特征集获取单元130包括:In an embodiment, the feature set obtaining unit 130 includes:
信息字段筛选策略获取单元,用于获取所述信息字段筛选策略中包括的核心特征字段集;其中,所述核心特征字段集包括交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段;The information field screening strategy obtaining unit is used to obtain the core feature field set included in the information field screening strategy; wherein, the core feature field set includes the field of the block height of the exchange, the field of the number of times the exchange executes the SHA256 function, and the field of transaction The number of times field of SHA3 function execution, the number of FOR loops field in the exchange execution function and the number field of the variables in the transaction;
核心特征字段获取单元,用于将每一目标智能合约代码对应的交易信息根据所述核心特征字段集进行信息筛选,得到各目标智能合约代码对应的特征集。The core feature field acquisition unit is used to screen the transaction information corresponding to each target smart contract code according to the core feature field set to obtain the feature set corresponding to each target smart contract code.
在本实施例中,在以太坊虚拟机环境下,每进行一个操作都要消耗部分的燃料,例如以太坊上进行加法的操作就需要消耗3个燃料等。上述举例的是单个操作所消耗的燃料,智能合约代码中所涉及函数所消耗的燃料并不是上述数据操作对应消耗燃料相加求和。但已知的是,通过所述信息字段筛选策略中包括的核心特征字段对应取值,是与燃料消耗呈正相关的关系。In this embodiment, in the Ethereum virtual machine environment, each operation needs to consume part of the fuel. For example, an addition operation on the Ethereum needs to consume 3 fuels and so on. The above example is the fuel consumed by a single operation. The fuel consumed by the functions involved in the smart contract code is not the sum of the fuel consumed by the above data operations. However, it is known that the corresponding values of the core feature fields included in the information field screening strategy are positively correlated with fuel consumption.
具体实施时,与燃料消耗呈正相关的关系的核心特征字段有交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段,将所述信息字段筛选策略中设置为用于从特征集中筛选包括的核心特征字段的对应取值。将每一目标智能合约代码对应的交易信息相应进行字段筛选后,所得到的筛选结果即是各目标智能合约代码对应的特征集。通过这一筛选过程,有 效对数据特征进行了降维。In specific implementation, the core feature fields that are positively related to fuel consumption include the exchange block height field, the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR cycles in the exchange execution function, and the transaction. The number field of the middle variable is set in the information field screening strategy to be used to screen the corresponding values of the core feature fields included in the feature set. After the transaction information corresponding to each target smart contract code is screened accordingly, the result of the screening is the feature set corresponding to each target smart contract code. Through this screening process, the data features are effectively reduced in dimensionality.
自动机器学习模型训练单元140,用于获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制。The automatic machine learning model training unit 140 is used to obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein, the automatic machine learning model is used to predict the smart contract The fuel limit of the called function.
在本实施例中,机器学习是让算法自动的从数据中找出一组规则,从而提取数据中对分类/聚类/决策有帮助的特征,随着机器学习的发展,其中人工需要干预的部分越来越多,而AutoML(即自动机器学习)则是对机器学习模型从构建到应用的全过程自动化,最终得出端对端的模型(end to end)。In this embodiment, machine learning allows the algorithm to automatically find a set of rules from the data, so as to extract the features of the data that are helpful for classification/clustering/decision-making. With the development of machine learning, manual intervention is required. There are more and more parts, and AutoML (that is, automatic machine learning) automates the entire process of machine learning models from construction to application, and finally an end-to-end model (end to end) is obtained.
机器学习的应用需要大量的人工干预,这些人工干预表现在:特征提取、模型选择、参数调节等机器学习的各个方面。自动机器学习(AutoML)试图将这些与特征、模型、优化、评价有关的重要步骤进行自动化地学习,使得机器学习模型无需人工干预即可被应用。The application of machine learning requires a lot of manual intervention, which is manifested in various aspects of machine learning such as feature extraction, model selection, and parameter adjustment. Automatic machine learning (AutoML) attempts to learn these important steps related to features, models, optimization, and evaluation automatically, so that machine learning models can be applied without manual intervention.
对于交易燃料预测任务而言,输入数据结构较复杂,还包含代码文本等难以量化的特征,使用传统的机器学习回归方法无法直接接受文本作为特征,在进行特征工程和模型选择时难度也较大,若使用自动化机器学习方法问题难度可大大减小。For transaction fuel prediction tasks, the input data structure is complex, and it also contains features that are difficult to quantify, such as code text. Traditional machine learning regression methods cannot directly accept text as features, and it is difficult to perform feature engineering and model selection. , If you use automated machine learning methods, the difficulty of the problem can be greatly reduced.
在一实施例中,自动机器学习模型训练单元140包括:In an embodiment, the automatic machine learning model training unit 140 includes:
数据降维单元,用于调用预先存储的主分量分析算法,以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集;The data dimensionality reduction unit is used to call the pre-stored principal component analysis algorithm to select the main feature of the feature set corresponding to each target smart contract code to obtain the dimensionality reduction feature set corresponding to each feature set;
模型训练单元,用于将待训练自动机器学习模型根据所述降维特征集依次进行模型训练、模型选择/组合及超参数调优,得到自动机器学习模型。The model training unit is used to sequentially perform model training, model selection/combination, and hyperparameter tuning on the automatic machine learning model to be trained according to the dimensionality reduction feature set to obtain the automatic machine learning model.
在本实施例中,主分量分析算法即PCA,主要用于数据降维。在训练自动机器学习模型的过程中,训练集的数据维度可以不用太多,此时可以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集,从而实现数据降维。In this embodiment, the principal component analysis algorithm, PCA, is mainly used for data dimensionality reduction. In the process of training the automatic machine learning model, the data dimension of the training set can not be too much. At this time, the main feature selection can be performed on the feature set corresponding to each target smart contract code, and the dimensionality reduction feature set corresponding to each feature set can be obtained. Realize data dimensionality reduction.
之后根据降维特征集对待训练自动机器学习模型依次进行模型训练、模型选择/组合及超参数调优,即可得到自动机器学习模型。Then, according to the dimensionality reduction feature set, the automatic machine learning model to be trained is sequentially performed model training, model selection/combination, and hyperparameter tuning to obtain the automatic machine learning model.
从自动机器学习的流程先后顺序来分,最初是数据准备,包括数据收集和清洗,之后是特征工程,其中包括特征选择,特征提取(对特征进行降维,常用的方法例如PCA),特征组合(将多个特征合并/构建为一个新的特征);在之后的模型构建中,最关键的是模型选择,之后超参数优化,可以采取很多方式,最简单的做法是网格搜索,常用的方法包括用强化学习,进化算法,贝叶斯优化,以及梯度下降,来缩小搜索空间;最后,AutoML通过引入提前停止,降低模型的精度,参数共享来自动化模型评价的过程。From the sequence of the automatic machine learning process, it is initially data preparation, including data collection and cleaning, and then feature engineering, which includes feature selection, feature extraction (reducing features, commonly used methods such as PCA), and feature combination (Combine/construct multiple features into a new feature); In the subsequent model construction, the most critical is model selection. After hyperparameter optimization, many methods can be adopted. The simplest method is grid search, which is commonly used. Methods include reinforcement learning, evolutionary algorithms, Bayesian optimization, and gradient descent to narrow the search space; finally, AutoML automates the process of model evaluation by introducing early stopping, reducing the accuracy of the model, and sharing parameters.
数据收集这项任务,不在是搜索与收集真实数据,还包括产生模拟数据,用来扩展训练数据集,可以使用的新技术包括对抗神经网络,还可以使用强化学习的框架,来优化用于控制生成数据的参数,从而使得生成的数据能更有效的助力模型的训练。而数据清洗则是自动完成包括缺失值补全,离群点处理,特征归一化,类别型特征的不同编码等之前手动完成的工作。The task of data collection is not to search and collect real data, but also to generate simulation data to expand the training data set. New technologies that can be used include countering neural networks, and reinforcement learning frameworks can also be used to optimize control. The parameters of the generated data, so that the generated data can more effectively assist the training of the model. The data cleaning is to automatically complete the work that was manually completed before including missing value completion, outlier processing, feature normalization, and different coding of categorical features.
模型的自动化选择,传统的方法是从传统的模型,例如KNN,SVM,决策树中选出一个,或多个组合起来效果最好的模型,而当前AutoML的研究热点是神经架构搜索(英文全称是Neural Architecture Search),也就是不经过人工干预,模型自动生成一个对当前任务最有效的网络结构。For automatic model selection, the traditional method is to select one or more models from traditional models, such as KNN, SVM, and decision trees, or combine them with the best model. The current research hotspot of AutoML is neural architecture search. It is Neural Architecture Search), that is, without manual intervention, the model automatically generates a network structure that is most effective for the current task.
模型选定后的调参过程,最常用的是网格搜索,也就是按照固定的间距,在搜索空间上打点,AutoML会使用随机抽样,首先评价各个超参数的重要性,之后再对重要的参数进行微调。After the model is selected, the most commonly used is the grid search, that is, according to a fixed interval, in the search space, AutoML will use random sampling, first evaluate the importance of each hyperparameter, and then focus on the important The parameters are fine-tuned.
通过降维特征集对待训练自动机器学习模型进行训练后,即可得到用于预测智能合约所调用函数的燃料限制的自动机器学习模型。After the automatic machine learning model to be trained is trained through the dimensionality reduction feature set, an automatic machine learning model for predicting the fuel limit of the function called by the smart contract can be obtained.
当前特征集获取单元150,用于若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集。The current feature set obtaining unit 150 is configured to, if the current smart contract code uploaded by the user terminal is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy.
在本实施例中,为了预测其他智能合约代码对应的以太坊燃料限制,此时可以直接由用户在用户端上操作录入当前智能合约代码,之后由用户端将当前智能合约代码发送至服务器中,以由服务器中进行燃料限制预测的数据预处理。此时,也可参考特征集获取单元130中,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集。通过这一精简后的当前特征集进行预测,有效降低数据维度,使得后续预测的效率得到提高。In this embodiment, in order to predict the Ethereum fuel limit corresponding to other smart contract codes, the user can directly input the current smart contract code on the user side at this time, and then the user side sends the current smart contract code to the server. Pre-processing the fuel limit prediction data by the server. At this time, you can also refer to the feature set obtaining unit 130 to obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy. Prediction through this streamlined current feature set effectively reduces the data dimension and improves the efficiency of subsequent predictions.
燃料限制预测单元160,用于将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。The fuel limit prediction unit 160 is configured to input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and calculate the Ethereum fuel limit corresponding to the current smart contract code. The fuel limit is sent to the corresponding target receiver.
在本实施例中,将所述当前特征集输入至所述自动机器学习模型中进行运算,通过自动机器学习模型即可提取当前特征集中各函数或是数据操作对应消耗的燃料限制,从而精准预测出所述当前智能合约代码对应的以太坊燃料限制。此时为了及时的通知用户端预测结果,可将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。In this embodiment, the current feature set is input to the automatic machine learning model for calculation, and the automatic machine learning model can extract the fuel consumption limit corresponding to each function or data operation in the current feature set, thereby accurately predicting Get the Ethereum fuel limit corresponding to the current smart contract code. At this time, in order to timely notify the user of the prediction result, the Ethereum fuel limit corresponding to the current smart contract code can be sent to the corresponding target receiving end.
在一实施例中,燃料限制预测单元160包括:In an embodiment, the fuel limit prediction unit 160 includes:
当前降维单元,用于将所述当前特征集根据所述主分量分析算法进行主特征选择,获取与所述当前特征集对应的当前降维特征集;The current dimensionality reduction unit is configured to perform main feature selection on the current feature set according to the principal component analysis algorithm, and obtain a current dimensionality reduction feature set corresponding to the current feature set;
目标模型选择单元,用于将所述当前降维特征集输入至所述自动机器学习模型中的模型选择模型进行运算,得到目标模型;A target model selection unit, configured to input the current dimensionality reduction feature set into a model selection model in the automatic machine learning model for calculation to obtain a target model;
当前预测单元,用于将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制。The current prediction unit is used to input the current feature set to the target model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code.
在本实施例中,在通过自动机器学习进行燃料限制预测,其主要是实现了模型的自动化选择,传统的方法是从传统的模型中选出一个或多个组合起来效果最好的模型,而当前AutoML可通过神经架构搜索,也就是不经过人工干预,模型自动生成一个对当前任务最有效的网络结构,这就极大的提高了预测结果的准确度。In this embodiment, when the fuel limit prediction is performed through automatic machine learning, it mainly realizes the automatic selection of models. The traditional method is to select one or more models with the best combination effect from the traditional models, and Currently, AutoML can search through neural architecture, that is, without manual intervention, the model automatically generates a network structure that is most effective for the current task, which greatly improves the accuracy of the prediction results.
该装置实现了基于智能合约代码自动筛选特征自动降维后,以对以太坊燃料限制进行预测,不仅避免了人工干预从而降低人工成本,而且提高了预测的准确率。This device realizes automatic dimensionality reduction based on the automatic screening of smart contract codes to predict the Ethereum fuel limit, which not only avoids manual intervention and reduces labor costs, but also improves the accuracy of prediction.
上述基于自动机器学习的以太坊燃料限制预测装置可以实现为计算机程序的形式,该计算机程序可以在如图4所示的计算机设备上运行。The above-mentioned Ethereum fuel limit prediction device based on automatic machine learning can be implemented in the form of a computer program, which can be run on a computer device as shown in FIG. 4.
请参阅图4,图4是本申请实施例提供的计算机设备的示意性框图。该计算机设备500是服务器,服务器可以是独立的服务器,也可以是多个服务器组成的服务器集群。Please refer to FIG. 4, which is a schematic block diagram of a computer device according to an embodiment of the present application. The computer device 500 is a server, and the server may be an independent server or a server cluster composed of multiple servers.
参阅图4,该计算机设备500包括通过系统总线501连接的处理器502、存储器和网络接口505,其中,存储器可以包括非易失性存储介质503和内存储器504。4, the computer device 500 includes a processor 502, a memory, and a network interface 505 connected through a system bus 501, where the memory may include a non-volatile storage medium 503 and an internal memory 504.
该非易失性存储介质503可存储操作系统5031和计算机程序5032。该计算机程序5032被执行时,可使得处理器502执行基于自动机器学习的以太坊燃料限制预测方法。The non-volatile storage medium 503 can store an operating system 5031 and a computer program 5032. When the computer program 5032 is executed, the processor 502 can execute the Ethereum fuel limit prediction method based on automatic machine learning.
该处理器502用于提供计算和控制能力,支撑整个计算机设备500的运行。The processor 502 is used to provide calculation and control capabilities, and support the operation of the entire computer device 500.
该内存储器504为非易失性存储介质503中的计算机程序5032的运行提供环境,该计算机程序5032被处理器502执行时,可使得处理器502执行基于自动机器学习的以太坊燃料限制预测方法。The internal memory 504 provides an environment for the operation of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute the Ethereum fuel limit prediction method based on automatic machine learning. .
该网络接口505用于进行网络通信,如提供数据信息的传输等。本领域技术人员可以理解,图4中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备500的限定,具体的计算机设备500可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。The network interface 505 is used for network communication, such as providing data information transmission. Those skilled in the art can understand that the structure shown in FIG. 4 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device 500 to which the solution of the present application is applied. The specific computer device 500 may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
其中,所述处理器502用于运行存储在存储器中的计算机程序5032,以实现本申请实施例公开的基于自动机器学习的以太坊燃料限制预测方法。Wherein, the processor 502 is configured to run a computer program 5032 stored in a memory to implement the Ethereum fuel limit prediction method based on automatic machine learning disclosed in the embodiment of the present application.
本领域技术人员可以理解,图4中示出的计算机设备的实施例并不构成对计算机设备具体构成的限定,在其他实施例中,计算机设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。例如,在一些实施例中,计算机设备可以仅包括存储器及 处理器,在这样的实施例中,存储器及处理器的结构及功能与图4所示实施例一致,在此不再赘述。Those skilled in the art can understand that the embodiment of the computer device shown in FIG. 4 does not constitute a limitation on the specific configuration of the computer device. In other embodiments, the computer device may include more or less components than those shown in the figure. Or some parts are combined, or different parts are arranged. For example, in some embodiments, the computer device may only include a memory and a processor. In such embodiments, the structures and functions of the memory and the processor are consistent with the embodiment shown in FIG. 4, and will not be repeated here.
应当理解,在本申请实施例中,处理器502可以是中央处理单元(Central Processing Unit,CPU),该处理器502还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。其中,通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。It should be understood that, in this embodiment of the application, the processor 502 may be a central processing unit (Central Processing Unit, CPU), and the processor 502 may also be other general-purpose processors, digital signal processors (Digital Signal Processors, DSPs), Application Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor.
在本申请的另一实施例中提供计算机可读存储介质。该计算机可读存储介质可以是非易失性,也可以是易失性。该计算机可读存储介质存储有计算机程序,其中计算机程序被处理器执行时实现本申请实施例公开的基于自动机器学习的以太坊燃料限制预测方法。In another embodiment of the present application, a computer-readable storage medium is provided. The computer-readable storage medium may be non-volatile or volatile. The computer-readable storage medium stores a computer program, where the computer program is executed by a processor to implement the Ethereum fuel limit prediction method based on automatic machine learning disclosed in the embodiments of the present application.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,上述描述的设备、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、计算机软件或者二者的结合来实现,为了清楚地说明硬件和软件的可互换性,在上述说明中已经按照功能一般性地描述了各示例的组成及步骤。这些功能究竟以硬件还是软件方式来执行取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those skilled in the art can clearly understand that, for the convenience and conciseness of description, the specific working process of the above-described equipment, device, and unit can refer to the corresponding process in the foregoing method embodiment, which will not be repeated here. A person of ordinary skill in the art may be aware that the units and algorithm steps of the examples described in the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of both, in order to clearly illustrate the hardware and software Interchangeability, in the above description, the composition and steps of each example have been generally described in accordance with the function. Whether these functions are executed by hardware or software depends on the specific application and design constraint conditions of the technical solution. Professionals and technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered beyond the scope of this application.
在本申请所提供的几个实施例中,应该理解到,所揭露的设备、装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为逻辑功能划分,实际实现时可以有另外的划分方式,也可以将具有相同功能的单元集合成一个单元,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另外,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口、装置或单元的间接耦合或通信连接,也可以是电的,机械的或其它的形式连接。In the several embodiments provided in this application, it should be understood that the disclosed equipment, device, and method may be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods, or the units with the same function may be combined into one. Units, for example, multiple units or components can be combined or integrated into another system, or some features can be omitted or not implemented. In addition, the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may also be electrical, mechanical or other forms of connection.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本申请实施例方案的目的。The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the objectives of the solutions of the embodiments of the present application.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以是两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, the functional units in the various embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or software functional unit.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分,或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-Only Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of this application is essentially or the part that contributes to the existing technology, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium. It includes several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage media include: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), magnetic disk or optical disk and other media that can store program codes.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到各种等效的修改或替换,这些修改或替换都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以权利要求的保护范围为准。The above are only specific implementations of this application, but the protection scope of this application is not limited to this. Anyone familiar with the technical field can easily think of various equivalents within the technical scope disclosed in this application. Modifications or replacements, these modifications or replacements shall be covered within the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claims.

Claims (20)

  1. 一种基于自动机器学习的以太坊燃料限制预测方法,其中,包括:An Ethereum fuel limit prediction method based on automatic machine learning, which includes:
    调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
    根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
    调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
    获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
    若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
    将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
  2. 根据权利要求1所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址,包括;The Ethereum fuel limit prediction method based on automatic machine learning according to claim 1, wherein the breadth-first search corresponding to the breadth-first algorithm obtains from the target URL the network that has issued all smart contracts on the Ethereum Address, including;
    获取所述目标网址的第一级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第一级网络地址集;Obtain all the network addresses of all smart contracts that have been published on Ethereum in the first-level webpage of the target URL to form a first-level network address set;
    访问所有与第一级网页相邻接的第二级网页,并获取第二级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第二级网络地址集;依序访问所有与第二级网页相邻接的第三级网页直至访问至访问所有与第n-1级网页相邻接的第n级网页,以分别获取第三级网络地址集至第n级网络地址集;其中,n的取值与所述目标网址的总网页级数相等;Visit all the second-level webpages adjacent to the first-level webpage, and obtain all the network addresses of all smart contracts that have been published on Ethereum in the second-level webpage to form a second-level network address set; visit all in order The third-level webpage adjacent to the second-level webpage until the access to all the nth-level webpages adjacent to the n-1th-level webpage to obtain the third-level network address set to the nth-level network address set respectively ; Wherein, the value of n is equal to the total page level of the target URL;
    由所述第一级网络地址集至第n级网络地址集组成所述目标网址中在以太坊上已发布所有智能合约的网络地址。The first-level network address set to the nth-level network address set form the network addresses of all smart contracts that have been published on Ethereum in the target URL.
  3. 根据权利要求1所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息,包括:The method for predicting Ethereum fuel limit based on automatic machine learning according to claim 1, wherein said obtaining the verified target smart contract code set according to the network address, and each target smart contract code set in the target smart contract code set. The transaction information corresponding to the contract code includes:
    将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储;Name and store each target smart contract code in the target smart contract code set for which the network address has been obtained and verified;
    获取各目标智能合约代码的交易信息中所包括的交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。Obtain the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the input data of the exchange function used in the transaction information of each target smart contract code; among them, the exchange The input data using the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction.
  4. 根据权利要求3所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集,包括:The Ethereum fuel limit prediction method based on automatic machine learning according to claim 3, wherein said calling a pre-stored information field screening strategy, after information screening of the transaction information corresponding to each target smart contract code, is The feature set corresponding to the target smart contract code includes:
    获取所述信息字段筛选策略中包括的核心特征字段集;其中,所述核心特征字段集包括交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段;Obtain the core feature field set included in the information field screening strategy; wherein, the core feature field set includes the block height field of the exchange, the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function field, and the exchange execution The FOR loop count field in the function and the number field of the variable in the transaction;
    将每一目标智能合约代码对应的交易信息根据所述核心特征字段集进行信息筛选,得到各目标智能合约代码对应的特征集。The transaction information corresponding to each target smart contract code is filtered according to the core feature field set, and the feature set corresponding to each target smart contract code is obtained.
  5. 根据权利要求4所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述获 取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型,包括:The method for predicting Ethereum fuel limit based on automatic machine learning according to claim 4, wherein said acquiring the feature set corresponding to each target smart contract code is input to the automatic machine learning model to be trained for training to obtain the automatic machine learning model, include:
    调用预先存储的主分量分析算法,以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集;Call the pre-stored principal component analysis algorithm to select the main feature of the feature set corresponding to each target smart contract code, and obtain the dimensionality reduction feature set corresponding to each feature set;
    将待训练自动机器学习模型根据所述降维特征集依次进行模型训练、模型选择/组合及超参数调优,得到自动机器学习模型。The automatic machine learning model to be trained is sequentially subjected to model training, model selection/combination, and hyperparameter tuning according to the dimensionality reduction feature set to obtain an automatic machine learning model.
  6. 根据权利要求5所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,包括:The method for predicting Ethereum fuel limit based on automatic machine learning according to claim 5, wherein said inputting said current feature set into said automatic machine learning model to perform calculations to obtain said current smart contract code Ethereum fuel restrictions include:
    将所述当前特征集根据所述主分量分析算法进行主特征选择,获取与所述当前特征集对应的当前降维特征集;Performing main feature selection on the current feature set according to the principal component analysis algorithm, and obtaining a current dimensionality reduction feature set corresponding to the current feature set;
    将所述当前降维特征集输入至所述自动机器学习模型中的模型选择模型进行运算,得到目标模型;Inputting the current dimensionality reduction feature set to the model selection model in the automatic machine learning model for calculation to obtain a target model;
    将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制。The current feature set is input to the target model for calculation, and the Ethereum fuel limit corresponding to the current smart contract code is obtained.
  7. 根据权利要求1所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储,包括:The Ethereum fuel limit prediction method based on automatic machine learning according to claim 1, wherein the said network address is obtained by naming and storing each target smart contract code in the target smart contract code set that has been verified. include:
    以智能合约名称+智能合约版本号+智能合约上传时间对所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储。Name and store each target smart contract code in the target smart contract code set for which the network address has been verified by the smart contract name + smart contract version number + smart contract upload time.
  8. 根据权利要求6所述的基于自动机器学习的以太坊燃料限制预测方法,其中,所述将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,包括:The method for predicting Ethereum fuel limit based on automatic machine learning according to claim 6, wherein said inputting said current feature set into said target model for calculation to obtain Ethereum fuel corresponding to said current smart contract code Restrictions include:
    通过自动机器学习模型提取当前特征集中各函数或是数据操作对应消耗的燃料限制,以得到所述当前智能合约代码对应的以太坊燃料限制。An automatic machine learning model is used to extract the fuel limit corresponding to each function or data operation in the current feature set to obtain the Ethereum fuel limit corresponding to the current smart contract code.
  9. 一种基于自动机器学习的以太坊燃料限制预测装置,其中,包括:An Ethereum fuel limit prediction device based on automatic machine learning, which includes:
    目标网络地址获取单元,用于调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;The target network address acquisition unit is used to call the preset stored breadth-first algorithm and the preset target URL, and obtain the network of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm address;
    目标代码集合获取单元,用于根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;The target code collection obtaining unit is configured to obtain the verified target smart contract code collection and transaction information corresponding to each target smart contract code in the target smart contract code collection according to the network address;
    特征集获取单元,用于调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;The feature set acquisition unit is used to call a pre-stored information field screening strategy, and after information screening is performed on the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening The strategy is used to filter the core features of the transaction information corresponding to the smart contract code to form a feature set;
    自动机器学习模型训练单元,用于获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;The automatic machine learning model training unit is used to obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein, the automatic machine learning model is used to predict the smart contract The fuel limit for calling functions;
    当前特征集获取单元,用于若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及The current feature set obtaining unit is configured to, if the current smart contract code uploaded by the user terminal is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
    燃料限制预测单元,用于将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。The fuel limit prediction unit is used to input the current feature set into the automatic machine learning model to perform calculations to obtain the Ethereum fuel limit corresponding to the current smart contract code, and calculate the Ethereum fuel limit corresponding to the current smart contract code. The fuel limit is sent to the corresponding target receiver.
  10. 一种计算机设备,包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的计算机程序,其中,所述处理器执行所述计算机程序时实现以下步骤:A computer device includes a memory, a processor, and a computer program stored on the memory and capable of running on the processor, wherein the processor implements the following steps when the processor executes the computer program:
    调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
    根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
    调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
    获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
    若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
    将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
  11. 根据权利要求10所述的计算机设备,其中,所述通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址,包括;The computer device according to claim 10, wherein the breadth-first search corresponding to the breadth-first algorithm obtains the network addresses of all smart contracts that have been published on Ethereum from the target website, comprising;
    获取所述目标网址的第一级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第一级网络地址集;Obtain all the network addresses of all smart contracts that have been published on Ethereum in the first-level webpage of the target URL to form a first-level network address set;
    访问所有与第一级网页相邻接的第二级网页,并获取第二级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第二级网络地址集;依序访问所有与第二级网页相邻接的第三级网页直至访问至访问所有与第n-1级网页相邻接的第n级网页,以分别获取第三级网络地址集至第n级网络地址集;其中,n的取值与所述目标网址的总网页级数相等;Visit all the second-level webpages adjacent to the first-level webpage, and obtain all the network addresses of all smart contracts that have been published on Ethereum in the second-level webpage to form a second-level network address set; visit all in order The third-level webpage adjacent to the second-level webpage until the access to all the nth-level webpages adjacent to the n-1th-level webpage to obtain the third-level network address set to the nth-level network address set respectively ; Wherein, the value of n is equal to the total page level of the target URL;
    由所述第一级网络地址集至第n级网络地址集组成所述目标网址中在以太坊上已发布所有智能合约的网络地址。The first-level network address set to the nth-level network address set form the network addresses of all smart contracts that have been published on Ethereum in the target URL.
  12. 根据权利要求10所述的计算机设备,其中,所述根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息,包括:The computer device according to claim 10, wherein said obtaining the verified target smart contract code set and the transaction information corresponding to each target smart contract code in the target smart contract code set according to the network address comprises:
    将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储;Name and store each target smart contract code in the target smart contract code set for which the network address has been obtained and verified;
    获取各目标智能合约代码的交易信息中所包括的交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。Obtain the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute the transaction separately, and the input data of the exchange function used in the transaction information of each target smart contract code; among them, the exchange The input data using the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction.
  13. 根据权利要求12所述的计算机设备,其中,所述调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集,包括:The computer device according to claim 12, wherein said calling a pre-stored information field screening strategy, after information screening of transaction information corresponding to each target smart contract code, obtains a feature set corresponding to each target smart contract code, include:
    获取所述信息字段筛选策略中包括的核心特征字段集;其中,所述核心特征字段集包括交易所在区块高度字段、交易所执行SHA256函数次数字段、交易执行SHA3函数次数字段、交易所执行函数中FOR循环次数字段和交易中变量的个数字段;Obtain the core feature field set included in the information field screening strategy; wherein, the core feature field set includes the block height field of the exchange, the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function field, and the exchange execution The FOR loop count field in the function and the number field of the variable in the transaction;
    将每一目标智能合约代码对应的交易信息根据所述核心特征字段集进行信息筛选,得到各目标智能合约代码对应的特征集。The transaction information corresponding to each target smart contract code is filtered according to the core feature field set, and the feature set corresponding to each target smart contract code is obtained.
  14. 根据权利要求13所述的计算机设备,其中,所述获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型,包括:The computer device according to claim 13, wherein said obtaining the feature set corresponding to each target smart contract code and inputting it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model comprises:
    调用预先存储的主分量分析算法,以对各目标智能合约代码对应的特征集进行主特征选择,得到与各特征集对应的降维特征集;Call the pre-stored principal component analysis algorithm to select the main feature of the feature set corresponding to each target smart contract code, and obtain the dimensionality reduction feature set corresponding to each feature set;
    将待训练自动机器学习模型根据所述降维特征集依次进行模型训练、模型选择/组合及超参数调优,得到自动机器学习模型。The automatic machine learning model to be trained is sequentially subjected to model training, model selection/combination, and hyperparameter tuning according to the dimensionality reduction feature set to obtain an automatic machine learning model.
  15. 根据权利要求14所述的计算机设备,其中,所述将所述当前特征集输入至所述自动 机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,包括:The computer device according to claim 14, wherein the inputting the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code comprises:
    将所述当前特征集根据所述主分量分析算法进行主特征选择,获取与所述当前特征集对应的当前降维特征集;Performing main feature selection on the current feature set according to the principal component analysis algorithm, and obtaining a current dimensionality reduction feature set corresponding to the current feature set;
    将所述当前降维特征集输入至所述自动机器学习模型中的模型选择模型进行运算,得到目标模型;Inputting the current dimensionality reduction feature set to the model selection model in the automatic machine learning model for calculation to obtain a target model;
    将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制。The current feature set is input to the target model for calculation, and the Ethereum fuel limit corresponding to the current smart contract code is obtained.
  16. 根据权利要求10所述的计算机设备,其中,所述将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储,包括:The computer device according to claim 10, wherein said naming and storing each target smart contract code in the target smart contract code set for which the verification of the network address has been completed comprises:
    以智能合约名称+智能合约版本号+智能合约上传时间对所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储。Each target smart contract code in the target smart contract code collection that has been verified by the network address is respectively named and stored by the smart contract name + smart contract version number + smart contract upload time.
  17. 根据权利要求15所述的计算机设备,其中,所述将所述当前特征集输入至所述目标模型进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,包括:The computer device according to claim 15, wherein said inputting said current feature set into said target model for calculation to obtain the Ethereum fuel limit corresponding to said current smart contract code comprises:
    通过自动机器学习模型提取当前特征集中各函数或是数据操作对应消耗的燃料限制,以得到所述当前智能合约代码对应的以太坊燃料限制。An automatic machine learning model is used to extract the fuel limit corresponding to each function or data operation in the current feature set to obtain the Ethereum fuel limit corresponding to the current smart contract code.
  18. 一种计算机可读存储介质,其中,所述计算机可读存储介质存储有计算机程序,所述计算机程序当被处理器执行时使所述处理器执行以下操作:A computer-readable storage medium, wherein the computer-readable storage medium stores a computer program that, when executed by a processor, causes the processor to perform the following operations:
    调用预设存储的广度优先算法和预先设置的目标网址,通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址;Call the preset stored breadth-first algorithm and the preset target URL, and obtain the network addresses of all smart contracts that have been published on Ethereum from the target URL through the breadth-first search corresponding to the breadth-first algorithm;
    根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息;Acquiring, according to the network address, a set of verified target smart contract codes and transaction information corresponding to each target smart contract code in the target smart contract code set;
    调用预先存储的信息字段筛选策略,将各目标智能合约代码对应的交易信息进行信息筛选后,得到与各目标智能合约代码对应的特征集;其中,所述信息字段筛选策略用于筛选智能合约代码对应的交易信息中核心特征以组成特征集;Call the pre-stored information field screening strategy, and after information screening of the transaction information corresponding to each target smart contract code, the feature set corresponding to each target smart contract code is obtained; wherein, the information field screening strategy is used to screen the smart contract code The core features in the corresponding transaction information form a feature set;
    获取各目标智能合约代码对应的特征集输入至待训练自动机器学习模型进行训练,得到自动机器学习模型;其中,所述自动机器学习模型用于预测智能合约所调用函数的燃料限制;Obtain the feature set corresponding to each target smart contract code and input it to the automatic machine learning model to be trained for training to obtain the automatic machine learning model; wherein the automatic machine learning model is used to predict the fuel limit of the function called by the smart contract;
    若检测到用户端上传的当前智能合约代码,根据所述信息字段筛选策略获取所述当前智能合约代码对应的当前特征集;以及If the current smart contract code uploaded by the client is detected, obtain the current feature set corresponding to the current smart contract code according to the information field screening strategy; and
    将所述当前特征集输入至所述自动机器学习模型中进行运算,得到所述当前智能合约代码对应的以太坊燃料限制,将所述当前智能合约代码对应的以太坊燃料限制发送至对应的目标接收端。Input the current feature set into the automatic machine learning model for calculation to obtain the Ethereum fuel limit corresponding to the current smart contract code, and send the Ethereum fuel limit corresponding to the current smart contract code to the corresponding target Receiving end.
  19. 根据权利要求18所述的计算机可读存储介质,其中,所述通过广度优先算法对应的广度优先搜索从所述目标网址中获取在以太坊上已发布所有智能合约的网络地址,包括;The computer-readable storage medium according to claim 18, wherein the breadth-first search corresponding to the breadth-first algorithm obtains the network addresses of all smart contracts that have been published on Ethereum from the target website, comprising;
    获取所述目标网址的第一级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第一级网络地址集;Obtain all the network addresses of all smart contracts that have been published on Ethereum in the first-level webpage of the target URL to form a first-level network address set;
    访问所有与第一级网页相邻接的第二级网页,并获取第二级网页中所有在以太坊上已发布所有智能合约的网络地址,以组成第二级网络地址集;依序访问所有与第二级网页相邻接的第三级网页直至访问至访问所有与第n-1级网页相邻接的第n级网页,以分别获取第三级网络地址集至第n级网络地址集;其中,n的取值与所述目标网址的总网页级数相等;Visit all the second-level webpages adjacent to the first-level webpage, and obtain all the network addresses of all smart contracts that have been published on Ethereum in the second-level webpage to form a second-level network address set; visit all in order The third-level webpage adjacent to the second-level webpage until the access to all the nth-level webpages adjacent to the n-1th-level webpage to obtain the third-level network address set to the nth-level network address set respectively ; Wherein, the value of n is equal to the total page level of the target URL;
    由所述第一级网络地址集至第n级网络地址集组成所述目标网址中在以太坊上已发布所有智能合约的网络地址。The first-level network address set to the nth-level network address set form the network addresses of all smart contracts that have been published on Ethereum in the target URL.
  20. 根据权利要求18所述的计算机可读存储介质,其中,所述根据所述网络地址获取已完成验证的目标智能合约代码集合,和与目标智能合约代码集合中各目标智能合约代码对应的交易信息,包括:The computer-readable storage medium according to claim 18, wherein said obtaining a verified target smart contract code set according to the network address, and transaction information corresponding to each target smart contract code in the target smart contract code set ,include:
    将所述网络地址获取已完成验证的目标智能合约代码集合中各目标智能合约代码分别进行命名并存储;Name and store each target smart contract code in the target smart contract code set for which the network address has been obtained and verified;
    获取各目标智能合约代码的交易信息中所包括的交易所在区块高度、交易的hash值、燃料限制、单独执行本交易实际所用到的燃料、交易所使用函数的输入数据;其中,交易所使用函数的输入数据中包括交易所执行SHA256函数次数、交易执行SHA3函数次数、交易所执行函数中FOR循环次数和交易中变量的个数。Obtain the block height of the exchange, the hash value of the transaction, the fuel limit, the fuel actually used to execute this transaction separately, and the input data of the exchange function used in the transaction information of each target smart contract code; among them, the exchange The input data using the function includes the number of times the exchange executes the SHA256 function, the number of times the transaction executes the SHA3 function, the number of FOR loops in the exchange execution function, and the number of variables in the transaction.
PCT/CN2020/118901 2020-07-31 2020-09-29 Automated machine learning-based ethereum fuel restriction prediction method, apparatus, computer device, and storage medium WO2021135467A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010761121.3A CN111898766B (en) 2020-07-31 2020-07-31 Ether house fuel limitation prediction method and device based on automatic machine learning
CN202010761121.3 2020-07-31

Publications (1)

Publication Number Publication Date
WO2021135467A1 true WO2021135467A1 (en) 2021-07-08

Family

ID=73183474

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/118901 WO2021135467A1 (en) 2020-07-31 2020-09-29 Automated machine learning-based ethereum fuel restriction prediction method, apparatus, computer device, and storage medium

Country Status (2)

Country Link
CN (1) CN111898766B (en)
WO (1) WO2021135467A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116611351A (en) * 2023-07-19 2023-08-18 东方空间技术(山东)有限公司 Rocket sublevel life assessment method, computer equipment and readable storage medium

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112101553B (en) * 2020-11-10 2021-02-23 鹏城实验室 Network structure searching method and device, equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107967539A (en) * 2017-11-29 2018-04-27 暨南大学 The method for the fuel limitation merchandised on prediction ether mill based on machine learning and block chain technology
CN109064656A (en) * 2018-08-16 2018-12-21 黄竹磬 Business model and its management system based on Hydrogen Fuel-cell Vehicles energy storing and electricity generating income
CN109064325A (en) * 2018-06-25 2018-12-21 浙江超脑时空科技有限公司 A kind of intelligent contract implementation method and device based on block chain

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108256052B (en) * 2018-01-15 2023-07-11 成都达拓智通科技有限公司 Tri-tracking-based potential customer identification method for automobile industry
CN110069690B (en) * 2019-04-24 2021-12-07 成都映潮科技股份有限公司 Method, device and medium for topic web crawler
CN110751562A (en) * 2019-10-29 2020-02-04 山东科技大学 Training optimization method for foreigner time sequence prediction
CN110942086B (en) * 2019-10-30 2024-04-23 平安科技(深圳)有限公司 Data prediction optimization method, device, equipment and readable storage medium
CN111105160A (en) * 2019-12-20 2020-05-05 北京工商大学 Steel quality prediction method based on tendency heterogeneous bagging algorithm

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107967539A (en) * 2017-11-29 2018-04-27 暨南大学 The method for the fuel limitation merchandised on prediction ether mill based on machine learning and block chain technology
CN109064325A (en) * 2018-06-25 2018-12-21 浙江超脑时空科技有限公司 A kind of intelligent contract implementation method and device based on block chain
CN109064656A (en) * 2018-08-16 2018-12-21 黄竹磬 Business model and its management system based on Hydrogen Fuel-cell Vehicles energy storing and electricity generating income

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116611351A (en) * 2023-07-19 2023-08-18 东方空间技术(山东)有限公司 Rocket sublevel life assessment method, computer equipment and readable storage medium
CN116611351B (en) * 2023-07-19 2023-09-22 东方空间技术(山东)有限公司 Rocket sublevel life assessment method, computer equipment and readable storage medium

Also Published As

Publication number Publication date
CN111898766B (en) 2023-02-24
CN111898766A (en) 2020-11-06

Similar Documents

Publication Publication Date Title
RU2405197C2 (en) Web-crawling based on statistical decision theory and predicting web page change
CN107967539B (en) Method for predicting fuel limit of transaction on ether house based on machine learning and block chain technology
US9398081B2 (en) Automating client development for network APIs
WO2021135467A1 (en) Automated machine learning-based ethereum fuel restriction prediction method, apparatus, computer device, and storage medium
CN111629051B (en) Performance optimization method and device for industrial internet identification analysis system
US20210385251A1 (en) System and methods for integrating datasets and automating transformation workflows using a distributed computational graph
WO2017176742A1 (en) Selection of machine learning alogorithms
CN112154420B (en) Automatic intelligent cloud service testing tool
US11362893B2 (en) Method and apparatus for configuring a cloud storage software appliance
CA3137748A1 (en) Method and apparatus for determining configuration knob of database
CN109271359A (en) Log information processing method, device, electronic equipment and readable storage medium storing program for executing
WO2020053792A1 (en) Malchain detection
WO2020057523A1 (en) Method and device for triggering vulnerability detection
US20220201008A1 (en) Multimodal modelling for systems using distance metric learning
Kupoluyi et al. Muzeel: Assessing the impact of javascript dead code elimination on mobile web performance
US20180203907A1 (en) Method and system for querying semantic information stored across several semantically enhanced resources of a resource structure
CN109446441A (en) A kind of credible distributed capture storage system of general Web Community
US20170228680A1 (en) Improvement message based on element score
CN116048817B (en) Data processing control method, device, computer equipment and storage medium
Casimiro et al. A probabilistic model checking approach to self-adapting machine learning systems
CN110555158A (en) mutually exclusive data processing method and system, and computer readable storage medium
Naddaf et al. Performance modeling and analysis of software architectures specified through graph transformations
CN115361231B (en) Host abnormal flow detection method, system and equipment based on access baseline
US9235382B2 (en) Input filters and filter-driven input processing
EP3438866A1 (en) Network device and method for determining security problems in such a network device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20910787

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20910787

Country of ref document: EP

Kind code of ref document: A1