Heterogeneous hardware recommendation method and device, medium and electronic equipment
The heterogeneous hardware is evaluated and recommended through a multi-dimensional scoring system, which solves the shortcomings of hardware capabilities based on a single dimension in the prior art, and achieves more accurate and reliable hardware recommendations.
Patent Information
- Application Number
- CN202411865517.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-17
- Publication Date
- 2025-03-07
AI Technical Summary
When evaluating hardware capabilities, the prior art usually only based on a single dimension, such as nominal performance, and cannot accurately reflect the performance of hardware in actual applications, resulting in the performance of hardware that does not match the expected performance, which can easily lead to problems.
A heterogeneous hardware recommendation method is provided, which scores candidate heterogeneous hardware through multiple preset scoring dimensions (hardware capability dimension, inference performance dimension, training performance dimension and ecological support dimension), and determines the target scoring dimension based on the user's hardware demand information, and recommends better performing heterogeneous hardware.
It realizes multi-dimensional evaluation of heterogeneous hardware, can more accurately reflect the performance of hardware in actual applications, improves the accuracy and reliability of hardware recommendations, and helps users quickly choose hardware that meets their own needs.
Smart Images

Figure CN119577253A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of hardware, and in particular, to a heterogeneous hardware recommendation method, device, medium and electronic device. Background Art
[0002] With the rise of large AI models, the demand for heterogeneous hardware computing resources has increased significantly, and more requirements have been put forward. At present, the evaluation of hardware capabilities is usually based on a single evaluation dimension, for example, the evaluation of hardware capabilities is based only on the nominal performance of the hardware, which often cannot accurately reflect the actual performance of the hardware in actual applications, making the hardware in actual applications inconsistent with the expected performance, which can easily lead to many problems. Summary of the invention
[0003] The purpose of the present disclosure is to provide a heterogeneous hardware recommendation method, device, medium and electronic device.
[0004] In order to achieve the above object, according to a first aspect of the present disclosure, a heterogeneous hardware recommendation method is provided, the method comprising: Receive hardware requirement information; For each candidate heterogeneous hardware, determine the target score corresponding to each of the candidate heterogeneous hardware in multiple preset scoring dimensions, where the preset scoring dimensions include hardware capability dimension, reasoning performance dimension, training performance dimension, and ecological support dimension; Determining a target scoring dimension from among the preset scoring dimensions according to the hardware requirement information; According to the target scores corresponding to the candidate heterogeneous hardware in the target score dimension, at least one first target heterogeneous hardware to be recommended is determined from the multiple candidate heterogeneous hardware, and hardware information of the first target heterogeneous hardware is output.
[0005] Optionally, the hardware capability dimension corresponds to at least one hardware capability indicator; The target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined in the following manner: For each hardware capability indicator, determining a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a test tool corresponding to the hardware capability indicator; Obtaining a reference indicator value corresponding to each of the hardware capability indicators of the reference hardware; For each hardware capability indicator, determining an indicator score of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a difference between a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator and a reference indicator value of the hardware capability indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each hardware capability indicator and the score weight corresponding to each hardware capability indicator, a target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined.
[0006] Optionally, the reasoning performance dimension corresponds to at least one reasoning performance indicator; The target score of the candidate heterogeneous hardware corresponding to the inference performance dimension is determined in the following manner: determining a first test model; By deploying the first test model to the candidate heterogeneous hardware for execution, performing an inference performance test on the candidate heterogeneous hardware using the first test model, and obtaining a second indicator value of the candidate heterogeneous hardware corresponding to the inference performance indicator; Determining an indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator according to a second indicator value of the candidate heterogeneous hardware corresponding to the reasoning performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator and the score weight corresponding to each reasoning performance indicator, a target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension is determined.
[0007] Optionally, the training performance dimension corresponds to at least one training performance indicator; The target score of the candidate heterogeneous hardware corresponding to the training performance dimension is determined in the following manner: determining a second test model; By deploying the second test model to the candidate heterogeneous hardware for execution, a training performance test is performed on the candidate heterogeneous hardware using the second test model to obtain a third indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; In the case where the candidate heterogeneous hardware supports multi-machine expansion, the second test model is deployed to a heterogeneous hardware cluster composed of a plurality of the candidate heterogeneous hardware for execution, and the training performance test of the candidate heterogeneous hardware is performed using the second test model to obtain a fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; Determining an indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator according to the third indicator value and the fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator and the score weight corresponding to each training performance indicator, the target score of the candidate heterogeneous hardware in the training performance dimension is determined.
[0008] Optionally, the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension is determined in the following manner: Acquire ecological support information of the candidate heterogeneous hardware, where the ecological support information includes operators and software stacks supported by the candidate heterogeneous hardware; Determine basic operators, core operators and target software stack information according to the hardware requirement information; Determining a first score corresponding to the candidate heterogeneous hardware according to the overlap between the operator supported by the candidate heterogeneous hardware and the basic operator; Determining a second score corresponding to the candidate heterogeneous hardware according to the overlap between the operators supported by the candidate heterogeneous hardware and the core operators; Determining a third score corresponding to the candidate heterogeneous hardware according to the overlap between the software stack supported by the candidate heterogeneous hardware and the target software stack information; A target score corresponding to the candidate heterogeneous hardware in the ecological support dimension is determined according to the first score, the second score, and the third score.
[0009] Optionally, the hardware information of the first target heterogeneous hardware includes computing resource utilization information and / or cluster expansion performance information of the first target heterogeneous hardware; The computing resource utilization information includes the actual utilization rate of the computing resources and the nominal information of the computing resources; The cluster expansion performance information is used to characterize how the performance of the first target heterogeneous hardware changes with the size of the hardware cluster.
[0010] Optionally, the cluster expansion performance information of the first target heterogeneous hardware is determined in the following manner: Acquire historical performance information of the first target heterogeneous hardware in hardware clusters of different sizes during historical use, wherein the hardware clusters of different sizes contain different quantities of the first target heterogeneous hardware; The machine learning model is trained by taking the number of first target heterogeneous hardware in the hardware cluster as the input of the model and taking the historical performance information as the target output of the model to obtain a trained performance prediction model; Determine multiple target quantities, where the target quantities are the quantities of hardware required by the first target heterogeneous hardware when performing cluster expansion; Inputting each of the target quantities into the performance prediction model respectively to obtain target performance information output by the performance prediction model; The target quantity and the target performance information corresponding to the target quantity are determined as the cluster expansion performance information.
[0011] Optionally, the method further comprises: Determine a multi-dimensional comprehensive score of the candidate heterogeneous hardware according to the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension, the target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension, the target score of the candidate heterogeneous hardware corresponding to the training performance dimension, and the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension; At least one second target heterogeneous hardware to be recommended is determined from a plurality of the candidate heterogeneous hardware according to the multi-dimensional comprehensive scores of the candidate heterogeneous hardware, and hardware information of the second target heterogeneous hardware is output.
[0012] According to a second aspect of the present disclosure, a heterogeneous hardware recommendation device is provided, the device comprising: A receiving module, used for receiving hardware requirement information; A first determination module is used to determine, for each candidate heterogeneous hardware, a target score corresponding to each of the candidate heterogeneous hardware in a plurality of preset scoring dimensions, wherein the preset scoring dimensions include a hardware capability dimension, a reasoning performance dimension, a training performance dimension, and an ecological support dimension; A second determination module, configured to determine a target scoring dimension from among the preset scoring dimensions according to the hardware requirement information; The first recommendation module is used to determine at least one first target heterogeneous hardware to be recommended from a plurality of candidate heterogeneous hardware according to the target score corresponding to the candidate heterogeneous hardware in the target score dimension, and output hardware information of the first target heterogeneous hardware.
[0013] According to a third aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the steps of the method described in the first aspect of the disclosure are implemented.
[0014] According to a fourth aspect of the present disclosure, there is provided an electronic device, including: a memory having a computer program stored thereon; A processor is used to execute the computer program in the memory to implement the steps of the method described in the first aspect.
[0015] Through the above technical solution, a multi-dimensional scoring system for heterogeneous hardware is provided, which scores from the hardware capability dimension, reasoning performance dimension, training performance dimension and ecological support dimension respectively, and can comprehensively and meticulously evaluate the application capability of heterogeneous hardware in the actual ecology. The above multi-dimensional scoring can cover various key links from hardware basic performance to model operation to ecological adaptability, so as to provide accurate and reliable evaluation results about heterogeneous hardware. Based on this, after receiving the user's hardware demand information, for each candidate heterogeneous hardware, the above multi-dimensional scoring system is used to comprehensively score each candidate heterogeneous hardware, and then according to one or more target scoring dimensions that the hardware demand information mainly focuses on in multiple scoring dimensions, at least one heterogeneous hardware with better scoring performance is recommended to the user in the target scoring dimension in a targeted manner. As a result, the recommendation for heterogeneous hardware is no longer limited to a single indicator, but comprehensively considers the performance of heterogeneous hardware in different scoring dimensions and the actual needs of users, which is conducive to realizing personalized recommendations for users, and can greatly improve the accuracy and reliability of hardware recommendations, thereby helping users quickly select heterogeneous hardware that meets their needs.
[0016] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] The accompanying drawings are used to provide a further understanding of the present disclosure and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present disclosure but do not constitute a limitation of the present disclosure. In the accompanying drawings: Figure 1 is a flowchart of a heterogeneous hardware recommendation method provided according to an embodiment of the present disclosure; Figure 2 is a block diagram of a heterogeneous hardware recommendation device provided according to an embodiment of the present disclosure; Figure 3 is a block diagram of an electronic device according to an exemplary embodiment; Figure 4 is a block diagram of an electronic device according to another exemplary embodiment. DETAILED DESCRIPTION
[0018] The specific implementation of the present disclosure is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described herein is only used to illustrate and explain the present disclosure, and is not used to limit the present disclosure.
[0019] Figure 1 1 is a flow chart of a heterogeneous hardware recommendation method provided according to an embodiment of the present disclosure. In the present disclosure, heterogeneous hardware may include but is not limited to chips, servers, etc. Figure 1As shown, the method provided by the present disclosure may include steps 11 to 14.
[0020] In step 11, hardware requirement information is received.
[0021] The hardware requirement information may be input by the user. The user may input his or her own requirements for hardware usage, and the requirements input by the user may be used as the hardware requirement information.
[0022] Optionally, hardware requirement information may include but is not limited to application scenarios, budget ranges, ecological preferences, performance expectations, etc. Application scenarios may be, for example, large model training scenarios, deep learning scenarios, mobile application scenarios, etc., among which, large model training scenarios and deep learning scenarios require hardware with powerful computing power due to the complexity of the training process. Mobile application scenarios require hardware with low power consumption and small size. Ecological preferences may be, for example, preferred operating systems, preferred development frameworks, preferred servers, etc. Performance expectations may be, for example, higher computing power, low power consumption, better graphics processing capabilities, etc.
[0023] In step 12, for each candidate heterogeneous hardware, the target scores corresponding to the candidate heterogeneous hardware in multiple preset scoring dimensions are determined. The preset scoring dimensions include hardware capability dimension, reasoning performance dimension, training performance dimension and ecological support dimension.
[0024] Optionally, a preliminary screening may be performed from a plurality of optional heterogeneous hardware to determine candidate heterogeneous hardware. For example, if a budget range is indicated in the hardware requirement information received in step 11, heterogeneous hardware whose price meets the budget range indicated by the hardware requirement information may be screened from the optional heterogeneous hardware as candidate heterogeneous hardware.
[0025] For scoring candidate heterogeneous hardware in the hardware capability dimension, its hardware capability can be evaluated based on the hardware conditions of the candidate heterogeneous hardware itself. For scoring candidate heterogeneous hardware in the reasoning performance dimension, its reasoning performance can be evaluated based on the performance of the candidate heterogeneous hardware in actual reasoning scenarios. For scoring candidate heterogeneous hardware in the training performance dimension, its training performance can be evaluated based on the performance of the candidate heterogeneous hardware in actual training scenarios. For scoring candidate heterogeneous hardware in the ecosystem support dimension, its support for the ecosystem required by the hardware requirement information can be evaluated based on the support of the candidate heterogeneous hardware itself for different ecosystems.
[0026] The following will respectively combine different embodiments to exemplify the scoring method under each preset scoring dimension in the present disclosure. It should be noted that for the sake of clarity of description, only the scoring method of a single candidate heterogeneous chip is described. For more than one candidate heterogeneous chips, each candidate heterogeneous chip can adopt the same scoring method as described below.
[0027] In a possible implementation, the hardware capability dimension corresponds to at least one hardware capability indicator. Optionally, the hardware capability indicator may include but is not limited to computing power, storage capacity, communication capacity, energy efficiency, etc.
[0028] In this implementation, the target score corresponding to the hardware capability dimension of the candidate heterogeneous hardware may be determined in the following manner: For each hardware capability indicator, determining a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a test tool corresponding to the hardware capability indicator; Obtaining a reference indicator value corresponding to each hardware capability indicator of the reference hardware; For each hardware capability indicator, determining an indicator score of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a difference between a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator and a reference indicator value of the hardware capability indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each hardware capability indicator and the score weight corresponding to each hardware capability indicator, the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined.
[0029] For different hardware capability indicators, there are usually tools that can test candidate heterogeneous hardware corresponding to the hardware capability indicator. For example, for the hardware capability indicator of computing power, it can be determined by tools such as Geekbench and MegPeak. For another example, for the hardware capability indicator of storage capacity, it can be determined by tools such as CrystalDiskMark and AS SSDBenchmark. For another example, for the hardware capability indicator of communication capability, it can be determined by tools such as Netperf and iperf3. For another example, for the hardware capability indicator of energy efficiency, it can be determined by tools such as CPU EnergyMeter and nvidia-smi.
[0030] Optionally, for the hardware capability indicator of computing power, the single-precision computing power and half-precision computing power of the candidate heterogeneous hardware can be determined through a test tool corresponding to computing power to determine the first indicator value of the candidate heterogeneous hardware corresponding to computing power. For the hardware indicator of storage capacity, the video memory bandwidth and video memory size of the candidate heterogeneous hardware can be determined through a test tool corresponding to storage capacity to determine the first indicator value of the candidate heterogeneous hardware corresponding to storage capacity. For the hardware capability indicator of communication capacity, the inter-card bandwidth of the candidate heterogeneous hardware can be determined through a test tool corresponding to communication capacity to determine the first indicator value of the candidate heterogeneous hardware corresponding to communication capacity.
[0031] Scoring of the hardware capability dimension usually requires reference to other hardware. Therefore, a reference hardware (e.g., NVIDIA A100) can be pre-set. According to the reference indicator values corresponding to each hardware capability indicator of the reference hardware, and based on the first indicator values corresponding to different hardware capability indicators of the candidate heterogeneous hardware, the indicator scores of the candidate heterogeneous hardware corresponding to each hardware capability indicator are determined respectively.
[0032] Among them, the determination method of the indicator score can be set according to actual needs. For example, assuming that for the hardware capability indicator of computing power, the first indicator value is set to be greater than or equal to the reference indicator value as full score, and when the first indicator value is set to be less than the reference indicator value, points are deducted according to the difference between the two, such as deducting 1 point when the difference is less than the first value, deducting 2 points when the difference is greater than the first value and less than the second value, and so on.
[0033] In addition, each hardware capability indicator also corresponds to a scoring weight, which is used to comprehensively score the hardware capability dimension. Then, according to the indicator scores of the candidate heterogeneous hardware corresponding to each hardware capability indicator, combined with the scoring weights corresponding to each hardware capability indicator, the value obtained by weighted summation is the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension. For example, the computing power, storage capacity, and communication capacity can be weighted and summed according to the weight ratio of 4:4:2 to obtain a preliminary comprehensive score, and then the preliminary comprehensive score and energy efficiency can be weighted and summed according to the weight ratio of 9:1 to obtain the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension.
[0034] In a possible implementation, the inference performance dimension may correspond to at least one inference performance indicator. Optionally, the inference performance indicator may include but is not limited to throughput (in token / s), power consumption efficiency, and the like.
[0035] In this implementation, the target score corresponding to the candidate heterogeneous hardware in the inference performance dimension may be determined in the following manner: determining a first test model; By deploying the first test model to the candidate heterogeneous hardware for execution, the candidate heterogeneous hardware is subjected to an inference performance test using the first test model to obtain a second indicator value of the candidate heterogeneous hardware corresponding to the inference performance indicator; Determining an indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator according to a second indicator value of the candidate heterogeneous hardware corresponding to the reasoning performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator and the score weight corresponding to each reasoning performance indicator, the target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension is determined.
[0036] Optionally, the first test model can be a mainstream machine learning model, such as CV (Computer Vision Model), NLP (Natural Language Processing Model), etc. Optionally, the first test model can select models of multiple orders of magnitude, for example, a CV model with 7B parameters and an NLP model with 70B parameters. At the same time, other environment configuration parameters of the first test model can also be set, such as the format of input data, runtime library version, etc.
[0037] After determining the first test model, the first test model can be deployed to the candidate heterogeneous hardware for running, so as to determine the second indicator value of each reasoning performance indicator through the data of the actual running of the first test model on the candidate heterogeneous hardware, and then determine the indicator score of each reasoning performance indicator according to the second indicator value.
[0038] Optionally, a reference value of the indicator can be set for each inference performance indicator, and the corresponding indicator score can be determined according to the comparison between the second indicator value and the reference value. For example, when the second indicator value is equal to the reference value of the indicator, the indicator score is determined to be full score, and when the second indicator value is not equal to the reference value of the indicator, the score is reduced according to the set rules. In this way, the indicator score of the candidate heterogeneous hardware corresponding to each inference performance indicator can be obtained.
[0039] For each inference performance indicator, its respective scoring weight can be preset. For example, the weight ratio of throughput and power efficiency can be set to 9:1. In this way, according to the indicator score of the candidate heterogeneous hardware corresponding to each inference performance indicator, based on the scoring weight corresponding to each inference performance indicator, the value obtained by weighted summation can be used as the target score of the candidate heterogeneous hardware corresponding to the inference performance dimension.
[0040] In a possible implementation, the training performance dimension may correspond to at least one training performance indicator. Optionally, the training performance indicator may include but is not limited to throughput (in token / s), scalability (ScalingAbility), mfu (Machine FLOPS Utilization, machine floating point operation utilization per second), etc.
[0041] In this implementation, the target score corresponding to the candidate heterogeneous hardware in the training performance dimension may be determined in the following manner: determining a second test model; By deploying the second test model to the candidate heterogeneous hardware for running, the candidate heterogeneous hardware is subjected to a training performance test using the second test model to obtain a third indicator value corresponding to the training performance indicator of the candidate heterogeneous hardware; In the case where the candidate heterogeneous hardware supports multi-machine expansion, the second test model is deployed to a heterogeneous hardware cluster composed of multiple candidate heterogeneous hardware for operation, and the second test model is used to perform a training performance test on the candidate heterogeneous hardware to obtain a fourth indicator value corresponding to the training performance indicator of the candidate heterogeneous hardware; Determine an indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator according to the third indicator value and the fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator and the score weight corresponding to each training performance indicator, the target score corresponding to the candidate heterogeneous hardware in the training performance dimension is determined.
[0042] Optionally, the second test model can be a mainstream machine learning model, such as CV (Computer Vision Model), NLP (Natural Language Processing Model), etc. At the same time, other environment configuration parameters of the second test model, such as the format of input data, runtime library version, etc., can also be set.
[0043] After determining the second test model, the second test model can be deployed to the candidate heterogeneous hardware for operation, so as to determine the third indicator value of each training performance indicator through the relevant data of the second test model in the actual training process on the candidate heterogeneous hardware. This is equivalent to performing a single-machine performance test on the candidate heterogeneous hardware. Optionally, when deploying a single-machine test, the second test model can use a model with 7B parameters.
[0044] Moreover, when the candidate heterogeneous hardware supports multi-machine expansion, the second test model can also be deployed to run on a heterogeneous hardware cluster consisting of the multiple candidate heterogeneous hardware, so as to determine the fourth indicator value of each training performance indicator through the relevant data of the second test model in the actual training process on the heterogeneous hardware cluster. This is equivalent to performing a multi-machine performance test on the candidate heterogeneous hardware, that is, testing the training performance of multiple candidate heterogeneous hardware when forming a cluster, which can be used as a reference information for cluster expansion. Optionally, when deploying multi-machine testing, the second test model can use a model with 70B parameters. By way of example, at least 16 candidate heterogeneous hardware can be set in a heterogeneous hardware cluster of multiple candidate heterogeneous hardware.
[0045] Furthermore, based on the third indicator value and the fourth indicator value of the training performance indicator, the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator can be determined. Optionally, a reference value of the indicator can be set for each training performance indicator, and the corresponding indicator score can be determined according to the comparison between the third indicator value and the corresponding reference value and the comparison between the fourth indicator value and the corresponding indicator value. For example, when the third indicator value is equal to the corresponding reference value and the fourth indicator value is equal to the corresponding reference value, the indicator score is determined to be full marks, and when the third indicator value is not equal to the corresponding reference value or the fourth indicator value is not equal to the corresponding reference value, the score is deducted according to the set rules. Thus, the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator can be obtained. In addition, when the candidate heterogeneous hardware does not support multi-machine expansion, the indicator score corresponding to this part of the multi-machine can be directly recorded as 0.
[0046] For each training performance indicator, its respective scoring weight can be preset. In this way, according to the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator, based on the scoring weight corresponding to each training performance indicator, the value obtained by weighted summation can be used as the target score of the candidate heterogeneous hardware corresponding to the training performance dimension.
[0047] In a possible implementation, the target score of the candidate heterogeneous hardware in the ecological support dimension can be determined in the following way: Obtaining ecological support information of candidate heterogeneous hardware, including operators and software stacks supported by the candidate heterogeneous hardware; Determine basic operators and core operators based on hardware requirement information; Determine a first score corresponding to the candidate heterogeneous hardware according to the overlap between the operators supported by the candidate heterogeneous hardware and the basic operators; Determine a second score corresponding to the candidate heterogeneous hardware according to the overlap between the operators supported by the candidate heterogeneous hardware and the core operators; Determine a third score corresponding to the candidate heterogeneous hardware according to the overlap between the software stack supported by the candidate heterogeneous hardware and the target software stack information; Based on the first score, the second score, and the third score, a target score corresponding to the candidate heterogeneous hardware in the ecological support dimension is determined.
[0048] Typically, the manufacturer of the candidate heterogeneous hardware will provide ecological support information for the candidate heterogeneous hardware, for example, providing which operators and software stacks the candidate heterogeneous hardware supports in a table.
[0049] For different hardware requirements, there are usually corresponding basic operators, core operators and software stacks required, and the above information can be stored as the correspondence between hardware requirements and required ecological information. For example, in video surveillance scenarios, image preprocessing, target recognition and tracking are required, involving basic operators such as image filtering and feature extraction, as well as software stacks such as deep learning frameworks. For another example, in scenarios related to large language models, Transformer core operators and deep learning software stacks are usually involved. For another example, in image recognition scenarios that apply convolutional neural networks, basic operators such as convolution and pooling are involved. For another example, in natural language processing scenarios that apply recurrent neural networks, core operators such as recurrent units and attention parameters are usually involved. Based on this, according to the hardware requirement information received in step 11, the basic operators, core operators and software stacks that match the hardware requirements can be determined.
[0050] In this way, the overlap between the operators supported by the candidate heterogeneous software and the basic operators can reflect the coverage of the candidate heterogeneous software on the required basic operators, and thus the first score can be obtained; the overlap between the operators supported by the candidate heterogeneous software and the core operators can reflect the coverage of the candidate heterogeneous software on the required core operators, and thus the second score can be obtained; the overlap between the software stack supported by the candidate heterogeneous software and the target software stack information can reflect the coverage of the candidate heterogeneous software on the required software stack, and thus the third score can be obtained. Optionally, a correspondence between the overlap situation (for example, the proportion of the overlapped operators in all the operators supported by the candidate heterogeneous software, the number of overlapped operators, etc.) and the score can be pre-constructed, and then based on the correspondence, it is easy to obtain the scores corresponding to different overlap situations as the above-mentioned scores.
[0051] In addition, by running a preset test script on the candidate heterogeneous hardware, a compatibility test can be performed on the software stack of the candidate heterogeneous hardware to obtain test data, and the third score corresponding to the candidate heterogeneous hardware can be assisted in determining based on the test data.
[0052] Furthermore, based on the first score, the second score and the third score, and their respective score weights, the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension can be determined by weighted summation.
[0053] In step 13, a target scoring dimension is determined from among the preset scoring dimensions according to the hardware requirement information.
[0054] As mentioned above, hardware requirement information can usually reflect the specific requirements for heterogeneous hardware, which can usually correspond to the capabilities of heterogeneous chips evaluated by preset scoring dimensions. Based on this, the target scoring dimensions that users are more concerned about in the preset scoring dimensions can be determined according to the hardware requirement information.
[0055] Among them, the target scoring dimension can be one or more than one. For example, if the hardware requirement information represents the expectation to use heterogeneous hardware for training large models, then the target score of the training performance dimension is more important to the user than the other scoring dimensions, and the training performance dimension can be used as the target scoring dimension. For another example, if the hardware requirement information represents the expectation to use heterogeneous hardware with higher computing power and lower power consumption for deep learning training, then the hardware capability dimension and the training performance dimension are more important to the user than the other scoring dimensions, and the hardware capability dimension and the training performance dimension can be used as the target scoring dimensions.
[0056] In step 14, at least one first target heterogeneous hardware to be recommended is determined from a plurality of candidate heterogeneous hardware according to the target scores corresponding to the candidate heterogeneous hardware in the target score dimension, and the hardware information of the first target heterogeneous hardware is output.
[0057] For the target scoring dimension, the candidate heterogeneous hardware with the highest scores can be determined according to the target score of each candidate heterogeneous hardware corresponding to the target scoring dimension, and at least one of them can be selected as the first target heterogeneous hardware to be recommended. For example, the top five candidate heterogeneous hardware with the highest scores can be selected as the first target heterogeneous hardware.
[0058] Optionally, in the case where there are more than one target scoring dimensions, multiple first target heterogeneous hardware can be output for each target scoring dimension respectively, and the target scores of these multiple target scoring dimensions can be combined and summed according to preset weights to obtain a comprehensive score, and the first target heterogeneous hardware to be recommended can be selected and output based on the candidate heterogeneous hardware with a higher comprehensive score in the target scoring dimension.
[0059] After determining the first target heterogeneous hardware, the hardware information of the first target heterogeneous hardware may be output, for example, the name, model, technical specifications, target score, etc. of the first target heterogeneous hardware may be outputted in descending order of target scores.
[0060] Optionally, the hardware information of the first target heterogeneous hardware may further include computing resource utilization information and / or cluster expansion performance information of the first target heterogeneous hardware.
[0061] Computing resource utilization information includes the actual utilization rate of computing resources and the nominal information of computing resources. Computing resources may include but are not limited to computing power, bandwidth, etc.
[0062] The computing resources of heterogeneous hardware usually have nominal values, which are marked at the factory. Therefore, the nominal information of the computing resources of the first target heterogeneous hardware can be directly obtained for output. The actual utilization rate of the computing resources can be further determined by collecting historical data of the first target heterogeneous hardware. For example, the average value of multiple historical data of computing power and bandwidth in the process of historical use of the first target heterogeneous hardware is taken and divided by the nominal computing power and bandwidth to obtain the actual utilization rate of computing power and bandwidth.
[0063] In actual applications, heterogeneous chips may not be able to strictly reach the nominal values. Therefore, computing resource utilization information can help users clarify the nominal information of computing resources and the actual utilization rate of computing resources, so that users can more comprehensively determine the actual application of heterogeneous chips based on the comparison of the two, and then determine whether it is necessary to select the corresponding heterogeneous chips.
[0064] The cluster expansion performance information is used to characterize how the performance of the first target heterogeneous hardware changes with the change of the hardware cluster scale.
[0065] For example, the cluster expansion performance information of the first target heterogeneous hardware may be determined in the following manner: Acquire historical performance information of the first target heterogeneous hardware in hardware clusters of different sizes during historical use, wherein the hardware clusters of different sizes contain different quantities of the first target heterogeneous hardware; The number of first target heterogeneous hardware in the hardware cluster is used as the input of the model, and the historical performance information is used as the target output of the model to train the machine learning model to obtain a trained performance prediction model; Determine multiple target quantities, where the target quantity is the quantity of hardware required by the first target heterogeneous hardware when performing cluster expansion; Input each target quantity into the performance prediction model respectively to obtain the target performance information output by the performance prediction model; The target quantity and target performance information corresponding to the target quantity are determined as cluster expansion performance information.
[0066] That is to say, by collecting historical performance information of the first target heterogeneous hardware in hardware clusters of different sizes during historical use, and training the model, the trained performance prediction model has the ability to accurately predict the performance of the specified first target heterogeneous hardware when forming a specified number of hardware clusters. Then, based on the determined multiple target numbers, the performance prediction model is used to determine the target performance information, which is then used as the performance change trend caused by the change in the number of hardware in the cluster when the first target heterogeneous hardware forms a cluster. For example, the target number can be a plurality of randomly determined values, such as 1, 2, 4, 8, 16, etc.
[0067] Optionally, the cluster expansion performance information of the first target heterogeneous hardware may be output and displayed in the form of a line graph with the number of hardware in the cluster as the horizontal axis and the performance as the vertical axis.
[0068] In this way, by recommending the first target heterogeneous hardware to the user and displaying the cluster expansion performance information of the first target heterogeneous hardware, the user can intuitively observe the performance changes of the first target heterogeneous hardware in cluster expansion. For users who have cluster expansion needs, the first target heterogeneous hardware with poor cluster expansion performance can be directly screened out based on the recommended content, thereby improving the efficiency of users in selecting heterogeneous chips.
[0069] Optionally, the method provided by the present disclosure may further include the following steps: Determine the multi-dimensional comprehensive score of the candidate heterogeneous hardware according to the target score corresponding to the hardware capability dimension of the candidate heterogeneous hardware, the target score corresponding to the reasoning performance dimension of the candidate heterogeneous hardware, the target score corresponding to the training performance dimension of the candidate heterogeneous hardware, and the target score corresponding to the ecological support dimension of the candidate heterogeneous hardware; According to the multi-dimensional comprehensive scores of the candidate heterogeneous hardware, at least one second target heterogeneous hardware to be recommended is determined from the plurality of candidate heterogeneous hardware, and the hardware information of the second target heterogeneous hardware is output.
[0070] That is to say, for the target scores of the existing multiple preset scoring dimensions, the weighted sum can be obtained to obtain a multi-dimensional comprehensive score, and then, based on the multi-dimensional comprehensive score, the second target heterogeneous hardware with better comprehensive performance is recommended to the user, providing the user with additional reference. Optionally, the weight corresponding to each preset scoring dimension can be set according to actual needs.
[0071] Among them, the method of determining the second target heterogeneous hardware from multiple candidate heterogeneous hardware is similar in principle to the method of determining the first target heterogeneous hardware from multiple candidate heterogeneous hardware in the previous article. The hardware information of the second target heterogeneous hardware can be the same information as the hardware information of the first target heterogeneous hardware in the previous article, and the determination method is also similar in principle, which will not be repeated here.
[0072] Through the above technical solution, a multi-dimensional scoring system for heterogeneous hardware is provided, which scores from the hardware capability dimension, reasoning performance dimension, training performance dimension and ecological support dimension respectively, and can comprehensively and meticulously evaluate the application capability of heterogeneous hardware in the actual ecology. The above multi-dimensional scoring can cover various key links from hardware basic performance to model operation to ecological adaptability, so as to provide accurate and reliable evaluation results about heterogeneous hardware. Based on this, after receiving the user's hardware demand information, for each candidate heterogeneous hardware, the above multi-dimensional scoring system is used to comprehensively score each candidate heterogeneous hardware, and then according to one or more target scoring dimensions that the hardware demand information mainly focuses on in multiple scoring dimensions, at least one heterogeneous hardware with better scoring performance is recommended to the user in the target scoring dimension in a targeted manner. As a result, the recommendation for heterogeneous hardware is no longer limited to a single indicator, but comprehensively considers the performance of heterogeneous hardware in different scoring dimensions and the actual needs of users, which is conducive to realizing personalized recommendations for users, and can greatly improve the accuracy and reliability of hardware recommendations, thereby helping users quickly select heterogeneous hardware that meets their needs.
[0073] Figure 2 is a block diagram of a heterogeneous hardware recommendation device provided according to an embodiment of the present disclosure. Figure 2 As shown, the device 20 may include: Receiving module 21, used for receiving hardware requirement information; A first determination module 22 is used to determine, for each candidate heterogeneous hardware, a target score corresponding to each of the candidate heterogeneous hardware in a plurality of preset scoring dimensions, wherein the preset scoring dimensions include a hardware capability dimension, a reasoning performance dimension, a training performance dimension, and an ecological support dimension; A second determination module 23, configured to determine a target scoring dimension from among the preset scoring dimensions according to the hardware requirement information; The first recommendation module 24 is used to determine at least one first target heterogeneous hardware to be recommended from a plurality of candidate heterogeneous hardware according to the target score corresponding to the candidate heterogeneous hardware in the target score dimension, and output hardware information of the first target heterogeneous hardware.
[0074] Optionally, the hardware capability dimension corresponds to at least one hardware capability indicator; The target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined by the following modules: A third determination module is used to determine, for each hardware capability indicator, a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a test tool corresponding to the hardware capability indicator; A first acquisition module, used to acquire a reference indicator value corresponding to each of the hardware capability indicators of the reference hardware; a fourth determination module, configured to determine, for each hardware capability indicator, an indicator score of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a difference between the first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator and a reference indicator value of the hardware capability indicator; The fifth determination module is used to determine the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension according to the indicator score of the candidate heterogeneous hardware corresponding to each hardware capability indicator and the score weight corresponding to each hardware capability indicator.
[0075] Optionally, the reasoning performance dimension corresponds to at least one reasoning performance indicator; The target score of the candidate heterogeneous hardware corresponding to the inference performance dimension is determined by the following modules: A sixth determination module, configured to determine a first test model; A first testing module is configured to deploy the first testing model to the candidate heterogeneous hardware for execution, and use the first testing model to perform an inference performance test on the candidate heterogeneous hardware, so as to obtain a second indicator value of the candidate heterogeneous hardware corresponding to the inference performance indicator; a seventh determination module, configured to determine an indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator according to a second indicator value of the candidate heterogeneous hardware corresponding to the reasoning performance indicator; An eighth determination module is used to determine a target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension according to the indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator and the score weight corresponding to each reasoning performance indicator.
[0076] Optionally, the training performance dimension corresponds to at least one training performance indicator; The target score of the candidate heterogeneous hardware corresponding to the training performance dimension is determined by the following modules: A ninth determination module, used to determine a second test model; A second testing module is configured to deploy the second testing model to the candidate heterogeneous hardware for execution, and use the second testing model to perform a training performance test on the candidate heterogeneous hardware, so as to obtain a third indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; A third test module is used for, when the candidate heterogeneous hardware supports multi-machine expansion, deploying the second test model to a heterogeneous hardware cluster composed of a plurality of the candidate heterogeneous hardware to run, using the second test model to perform a training performance test on the candidate heterogeneous hardware, and obtaining a fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; a tenth determination module, configured to determine an indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator according to the third indicator value and the fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; An eleventh determination module is used to determine a target score corresponding to the candidate heterogeneous hardware in the training performance dimension according to the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator and the score weight corresponding to each training performance indicator.
[0077] Optionally, the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension is determined by the following modules: A second acquisition module is used to acquire ecological support information of the candidate heterogeneous hardware, where the ecological support information includes operators and software stacks supported by the candidate heterogeneous hardware; A twelfth determination module, used to determine basic operators, core operators and target software stack information according to the hardware requirement information; a thirteenth determination module, configured to determine a first score corresponding to the candidate heterogeneous hardware according to the overlap between the operator supported by the candidate heterogeneous hardware and the basic operator; A fourteenth determination module, configured to determine a second score corresponding to the candidate heterogeneous hardware according to the overlap between the operator supported by the candidate heterogeneous hardware and the core operator; A fifteenth determination module, configured to determine a third score corresponding to the candidate heterogeneous hardware according to the overlap between the software stack supported by the candidate heterogeneous hardware and the target software stack information; A sixteenth determination module is configured to determine a target score corresponding to the candidate heterogeneous hardware in the ecological support dimension according to the first score, the second score, and the third score.
[0078] Optionally, the hardware information of the first target heterogeneous hardware includes computing resource utilization information and / or cluster expansion performance information of the first target heterogeneous hardware; The computing resource utilization information includes actual utilization of computing resources and nominal information of computing resources; The cluster expansion performance information is used to characterize how the performance of the first target heterogeneous hardware changes with the size of the hardware cluster.
[0079] Optionally, the cluster expansion performance information of the first target heterogeneous hardware is determined by the following modules: A third acquisition module is used to acquire historical performance information of the first target heterogeneous hardware in hardware clusters of different sizes during historical use, wherein the hardware clusters of different sizes contain different quantities of the first target heterogeneous hardware; A training module, used to train the machine learning model by taking the number of first target heterogeneous hardware in the hardware cluster as the input of the model and taking the historical performance information as the target output of the model to obtain a trained performance prediction model; A seventeenth determination module is used to determine multiple target quantities, where the target quantity is the quantity of hardware required by the first target heterogeneous hardware when performing cluster expansion; A processing module, used for inputting each of the target quantities into the performance prediction model to obtain target performance information output by the performance prediction model; An eighteenth determining module is used to determine the target quantity and the target performance information corresponding to the target quantity as the cluster expansion performance information.
[0080] Optionally, the device 20 further includes: A nineteenth determination module is used to determine the multi-dimensional comprehensive score of the candidate heterogeneous hardware according to the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension, the target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension, the target score of the candidate heterogeneous hardware corresponding to the training performance dimension, and the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension; The second recommendation module is used to determine at least one second target heterogeneous hardware to be recommended from a plurality of candidate heterogeneous hardware according to the multi-dimensional comprehensive scores of the candidate heterogeneous hardware, and output the hardware information of the second target heterogeneous hardware.
[0081] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0082] The present disclosure also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the heterogeneous hardware recommendation method provided by any embodiment of the present disclosure.
[0083] The present disclosure also provides an electronic device, comprising: a memory having a computer program stored thereon; A processor is used to execute the computer program in the memory to implement the steps of the heterogeneous hardware recommendation method provided in any embodiment of the present disclosure.
[0084] Figure 3 FIG. 7 is a block diagram of an electronic device 700 according to an exemplary embodiment. Figure 3 As shown, the electronic device 700 may include: a processor 701 , a memory 702 . The electronic device 700 may also include one or more of a multimedia component 703 , an input / output (I / O) interface 704 , and a communication component 705 .
[0085] The processor 701 is used to control the overall operation of the electronic device 700 to complete all or part of the steps in the above-mentioned heterogeneous hardware recommended method. The memory 702 is used to store various types of data to support the operation of the electronic device 700. For example, these data may include instructions for any application or method used to operate on the electronic device 700, and application-related data, such as contact data, sent and received messages, pictures, audio, video, etc. The memory 702 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (Static Random Access Memory, referred to as SRAM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, referred to as EEPROM), erasable programmable read-only memory (Erasable Programmable Read-Only Memory, referred to as EPROM), programmable read-only memory (Programmable Read-Only Memory, referred to as PROM), read-only memory (Read-Only Memory, referred to as ROM), magnetic memory, flash memory, magnetic disk or optical disk. The multimedia component 703 may include a screen and an audio component. The screen may be, for example, a touch screen, and the audio component is used to output and / or input audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may be further stored in the memory 702 or sent through the communication component 705. The audio component also includes at least one speaker for outputting audio signals. The I / O interface 704 provides an interface between the processor 701 and other interface modules, and the above-mentioned other interface modules may be a keyboard, a mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 705 is used for wired or wireless communication between the electronic device 700 and other devices. Wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G or 4G, or a combination of one or more of them, so the corresponding communication component 705 may include: Wi-Fi module, Bluetooth module, NFC module.
[0086] In an exemplary embodiment, the electronic device 700 may be implemented by one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned heterogeneous hardware recommendation method.
[0087] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by a processor, the steps of the heterogeneous hardware recommendation method described above are implemented. For example, the computer-readable storage medium may be the memory 702 including the program instructions, and the program instructions may be executed by the processor 701 of the electronic device 700 to complete the heterogeneous hardware recommendation method described above.
[0088] In another exemplary embodiment, a computer program product is further provided. The computer program product includes a computer program executable by a processor. When the computer program is executed by the processor, the steps of the heterogeneous hardware recommendation method are implemented.
[0089] Figure 4 1 is a block diagram of an electronic device 1900 according to another exemplary embodiment. For example, the electronic device 1900 may be provided as a server. Figure 4 The electronic device 1900 includes a processor 1922, which may be one or more, and a memory 1932 for storing a computer program executable by the processor 1922. The computer program stored in the memory 1932 may include one or more modules each corresponding to a set of instructions. In addition, the processor 1922 may be configured to execute the computer program to perform the above-mentioned heterogeneous hardware recommendation method.
[0090] In addition, the electronic device 1900 may further include a power supply component 1926 and a communication component 1950. The power supply component 1926 may be configured to perform power management of the electronic device 1900, and the communication component 1950 may be configured to implement communication of the electronic device 1900, for example, wired or wireless communication. In addition, the electronic device 1900 may further include an input / output (I / O) interface 1958. The electronic device 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server 2000. TM , Mac OS X TM , Unix TM , Linux TM etc.
[0091] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by a processor, the steps of the heterogeneous hardware recommendation method described above are implemented. For example, the computer-readable storage medium may be the memory 1932 including the program instructions, and the program instructions may be executed by the processor 1922 of the electronic device 1900 to complete the heterogeneous hardware recommendation method described above.
[0092] In another exemplary embodiment, a computer program product is further provided. The computer program product includes a computer program executable by a processor. When the computer program is executed by the processor, the steps of the heterogeneous hardware recommendation method are implemented.
[0093] The preferred embodiments of the present disclosure are described in detail above in conjunction with the accompanying drawings; however, the present disclosure is not limited to the specific details in the above embodiments. Within the technical concept of the present disclosure, a variety of simple modifications can be made to the technical solution of the present disclosure, and these simple modifications all fall within the protection scope of the present disclosure.
[0094] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present disclosure will not further describe various possible combinations.
[0095] In addition, various embodiments of the present disclosure may be arbitrarily combined, and as long as they do not violate the concept of the present disclosure, they should also be regarded as the contents disclosed by the present disclosure.
Claims
1. A heterogeneous hardware recommendation method, characterized in that: The method comprises: Receive hardware requirement information; For each candidate heterogeneous hardware, determine the target score corresponding to each of the candidate heterogeneous hardware in multiple preset scoring dimensions, where the preset scoring dimensions include hardware capability dimension, reasoning performance dimension, training performance dimension, and ecological support dimension; Determining a target scoring dimension from among the preset scoring dimensions according to the hardware requirement information; According to the target scores corresponding to the candidate heterogeneous hardware in the target score dimension, at least one first target heterogeneous hardware to be recommended is determined from the plurality of candidate heterogeneous hardware, and hardware information of the first target heterogeneous hardware is output.
2. The method according to claim 1, characterized in that The hardware capability dimension corresponds to at least one hardware capability indicator; The target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined in the following manner: For each hardware capability indicator, determining a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a test tool corresponding to the hardware capability indicator; Obtaining a reference indicator value corresponding to each of the hardware capability indicators of the reference hardware; For each hardware capability indicator, determining an indicator score of the candidate heterogeneous hardware corresponding to the hardware capability indicator according to a difference between a first indicator value of the candidate heterogeneous hardware corresponding to the hardware capability indicator and a reference indicator value of the hardware capability indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each hardware capability indicator and the score weight corresponding to each hardware capability indicator, a target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension is determined.
3. The method according to claim 1, characterized in that The reasoning performance dimension corresponds to at least one reasoning performance indicator; The target score of the candidate heterogeneous hardware corresponding to the inference performance dimension is determined in the following manner: determining a first test model; By deploying the first test model to the candidate heterogeneous hardware for execution, performing an inference performance test on the candidate heterogeneous hardware using the first test model, and obtaining a second indicator value of the candidate heterogeneous hardware corresponding to the inference performance indicator; Determining an indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator according to a second indicator value of the candidate heterogeneous hardware corresponding to the reasoning performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each reasoning performance indicator and the score weight corresponding to each reasoning performance indicator, a target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension is determined.
4. The method according to claim 1, characterized in that: The training performance dimension corresponds to at least one training performance indicator; The target score of the candidate heterogeneous hardware corresponding to the training performance dimension is determined in the following manner: determining a second test model; By deploying the second test model to the candidate heterogeneous hardware for execution, a training performance test is performed on the candidate heterogeneous hardware using the second test model to obtain a third indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; In the case where the candidate heterogeneous hardware supports multi-machine expansion, the second test model is deployed to a heterogeneous hardware cluster composed of a plurality of the candidate heterogeneous hardware for execution, and the training performance test of the candidate heterogeneous hardware is performed using the second test model to obtain a fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; Determining an indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator according to the third indicator value and the fourth indicator value of the candidate heterogeneous hardware corresponding to the training performance indicator; According to the indicator score of the candidate heterogeneous hardware corresponding to each training performance indicator and the score weight corresponding to each training performance indicator, the target score of the candidate heterogeneous hardware in the training performance dimension is determined.
5. The method according to claim 1, characterized in that The target score of the candidate heterogeneous hardware corresponding to the ecological support dimension is determined in the following way: Acquire ecological support information of the candidate heterogeneous hardware, where the ecological support information includes operators and software stacks supported by the candidate heterogeneous hardware; Determine basic operators, core operators and target software stack information according to the hardware requirement information; Determining a first score corresponding to the candidate heterogeneous hardware according to the overlap between the operator supported by the candidate heterogeneous hardware and the basic operator; Determining a second score corresponding to the candidate heterogeneous hardware according to the overlap between the operators supported by the candidate heterogeneous hardware and the core operators; Determining a third score corresponding to the candidate heterogeneous hardware according to the overlap between the software stack supported by the candidate heterogeneous hardware and the target software stack information; A target score corresponding to the candidate heterogeneous hardware in the ecological support dimension is determined according to the first score, the second score, and the third score.
6. The method according to claim 1, characterized in that The hardware information of the first target heterogeneous hardware includes computing resource utilization information and / or cluster expansion performance information of the first target heterogeneous hardware; The computing resource utilization information includes actual utilization of computing resources and nominal information of computing resources; The cluster expansion performance information is used to characterize how the performance of the first target heterogeneous hardware changes with the size of the hardware cluster.
7. The method according to claim 6, characterized in that The cluster expansion performance information of the first target heterogeneous hardware is determined in the following manner: Acquire historical performance information of the first target heterogeneous hardware in hardware clusters of different sizes during historical use, wherein the hardware clusters of different sizes contain different quantities of the first target heterogeneous hardware; The machine learning model is trained by taking the number of first target heterogeneous hardware in the hardware cluster as the input of the model and taking the historical performance information as the target output of the model to obtain a trained performance prediction model; Determine multiple target quantities, where the target quantities are the quantities of hardware required by the first target heterogeneous hardware when performing cluster expansion; Inputting each of the target quantities into the performance prediction model respectively to obtain target performance information output by the performance prediction model; The target quantity and the target performance information corresponding to the target quantity are determined as the cluster expansion performance information.
8. The method according to claim 1, characterized in that The method further comprises: Determine a multi-dimensional comprehensive score of the candidate heterogeneous hardware according to the target score of the candidate heterogeneous hardware corresponding to the hardware capability dimension, the target score of the candidate heterogeneous hardware corresponding to the reasoning performance dimension, the target score of the candidate heterogeneous hardware corresponding to the training performance dimension, and the target score of the candidate heterogeneous hardware corresponding to the ecological support dimension; At least one second target heterogeneous hardware to be recommended is determined from a plurality of the candidate heterogeneous hardware according to the multi-dimensional comprehensive scores of the candidate heterogeneous hardware, and hardware information of the second target heterogeneous hardware is output.
9. A heterogeneous hardware recommendation device, characterized in that: The device comprises: A receiving module, used for receiving hardware requirement information; A first determination module is used to determine, for each candidate heterogeneous hardware, a target score corresponding to each of the candidate heterogeneous hardware in a plurality of preset scoring dimensions, wherein the preset scoring dimensions include a hardware capability dimension, a reasoning performance dimension, a training performance dimension, and an ecological support dimension; A second determination module, configured to determine a target scoring dimension from among the preset scoring dimensions according to the hardware requirement information; The first recommendation module is used to determine at least one first target heterogeneous hardware to be recommended from a plurality of candidate heterogeneous hardware according to the target score corresponding to the candidate heterogeneous hardware in the target score dimension, and output hardware information of the first target heterogeneous hardware.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method described in any one of claims 1 to 8 are implemented.
11. An electronic device, characterized in that: include: a memory having a computer program stored thereon; A processor, configured to execute the computer program in the memory to implement the steps of the method according to any one of claims 1 to 8.
Citation Information
Cited By
Heterogeneous resource type selection method and device
CN121501857A