This disclosure relates generally to deep learning (DL) model management and, more particularly, to methods and apparatus for dynamic XPU hardware-aware deep learning (DL) model management.
Compute workloads for a computing device may be carried out through use of Deep Learning (DL) models. Deep Learning (DL) models, such as neural networks (NNs), are useful tools that have demonstrated their value solving complex problems regarding pattern recognition, object classification, natural language processing, automatic speech recognition, etc. Identifying an optimal combination of hardware (HW) and/or software (SW) (e.g., a Deep Learning model) to execute a compute workload is complex due to the vast range of available types of hardware and/or Deep Learning (DL) models and customization(s) thereof.
In general, the same reference numbers will be used throughout the drawing(s) and accompanying written description to refer to the same or like parts. The figures are not to scale. Instead, the thickness of the layers or regions may be enlarged in the drawings. Although the figures show layers and regions with clean lines and boundaries, some or all of these lines and/or boundaries may be idealized. In reality, the boundaries and/or lines may be unobservable, blended, and/or irregular.
As used herein, unless otherwise stated, the term “above” describes the relationship of two parts relative to Earth. A first part is above a second part, if the second part has at least one part between Earth and the first part. Likewise, as used herein, a first part is “below” a second part when the first part is closer to the Earth than the second part. As noted above, a first part can be above or below a second part with one or more of: other parts therebetween, without other parts therebetween, with the first and second parts touching, or without the first and second parts being in direct contact with one another.
Notwithstanding the foregoing, in the case of a semiconductor device, “above” is not with reference to Earth, but instead is with reference to a bulk region of a base semiconductor substrate (e.g., a semiconductor wafer) on which components of an integrated circuit are formed. Specifically, as used herein, a first component of an integrated circuit is “above” a second component when the first component is farther away from the bulk region of the semiconductor substrate than the second component.
As used in this patent, stating that any part (e.g., a layer, film, area, region, or plate) is in any way on (e.g., positioned on, located on, disposed on, or formed on, etc.) another part, indicates that the referenced part is either in contact with the other part, or that the referenced part is above the other part with one or more intermediate part(s) located therebetween.
As used herein, connection references (e.g., attached, coupled, connected, and joined) may include intermediate members between the elements referenced by the connection reference and/or relative movement between those elements unless otherwise indicated. As such, connection references do not necessarily infer that two elements are directly connected and/or in fixed relation to each other. As used herein, stating that any part is in “contact” with another part is defined to mean that there is no intermediate part between the two parts.
Unless specifically stated otherwise, descriptors such as “first,” “second,” “third,” etc., are used herein without imputing or otherwise indicating any meaning of priority, physical order, arrangement in a list, and/or ordering in any way, but are merely used as labels and/or arbitrary names to distinguish elements for ease of understanding the disclosed examples. In some examples, the descriptor “first” may be used to refer to an element in the detailed description, while the same element may be referred to in a claim with a different descriptor such as “second” or “third.” In such instances, it should be understood that such descriptors are used merely for identifying those elements distinctly that might, for example, otherwise share a same name.
As used herein, “approximately” and “about” refer to dimensions that may not be exact due to manufacturing tolerances and/or other real world imperfections. As used herein “substantially real time” refers to occurrence in a near instantaneous manner recognizing there may be real world delays for computing time, transmission, etc. Thus, unless otherwise specified, “substantially real time” refers to real time +/−1 second.
As used herein, the phrase “in communication,” including variations thereof, encompasses direct communication and/or indirect communication through one or more intermediary components, and does not require direct physical (e.g., wired) communication and/or constant communication, but rather additionally includes selective communication at periodic intervals, scheduled intervals, aperiodic intervals, and/or one-time events.
As used herein, “processor circuitry” is defined to include (i) one or more special purpose electrical circuits structured to perform specific operation(s) and including one or more semiconductor-based logic devices (e.g., electrical hardware implemented by one or more transistors), and/or (ii) one or more general purpose semiconductor-based electrical circuits programmed with instructions to perform specific operations and including one or more semiconductor-based logic devices (e.g., electrical hardware implemented by one or more transistors). Examples of processor circuitry include programmed microprocessors, Field Programmable Gate Arrays (FPGAs) that may instantiate instructions, Central Processor Units (CPUs), Graphics Processor Units (GPUs), Digital Signal Processors (DSPs), XPUs, or microcontrollers and integrated circuits such as Application Specific Integrated Circuits (ASICs). For example, an XPU may be implemented by a heterogeneous computing system including multiple types of processor circuitry (e.g., one or more FPGAs, one or more CPUs, one or more GPUs, one or more DSPs, etc., and/or a combination thereof) and application programming interface(s) (API(s)) that may assign computing task(s) to whichever one(s) of the multiple types of the processing circuitry is/are best suited to execute the computing task(s).
Artificial intelligence (AI), including machine learning (ML), deep learning (DL), and/or other artificial machine-driven logic, enables machines (e.g., computers, logic circuits, etc.) to use a model to process input data to generate an output based on patterns and/or associations previously learned by the model via a training process. For instance, the model may be trained with data to recognize patterns and/or associations when processing input data such that other input(s) result in output(s) consistent with the recognized patterns and/or associations.
Many different types of machine learning models and/or machine learning architectures exist. In some examples disclosed herein, a decision tree model is used. Using a decision tree model enables the interpretation of data that is simple and explainable. In general, machine learning models/architectures that are suitable to use in the example approaches disclosed herein will be Convolutional Neural Network (CNN) and/or Deep Neural Network (DNN), wherein interconnections are not visible outside of the model. However, other types of machine learning models could additionally or alternatively be used such as Recurrent Neural Network (RNN), Support Vector Machine (SVM), Gated Recurrent Unit (GRU), Long Short Term Memory (LSTM), etc.
In general, implementing a ML/AI system involves two phases, a learning/training phase and an inference phase. In the learning/training phase, a training algorithm is used to train a model to operate in accordance with patterns and/or associations based on, for example, training data. In general, the model includes internal parameters that guide how input data is transformed into output data, such as through a series of nodes and connections within the model to transform input data into output data. Additionally, hyperparameters are used as part of the training process to control how the learning is performed (e.g., a learning rate, a number of layers to be used in the machine learning model, etc.). Hyperparameters are defined to be training parameters that are determined prior to initiating the training process.
Different types of training may be performed based on the type of ML/AI model and/or the expected output. For example, supervised training uses inputs and corresponding expected (e.g., labeled) outputs to select parameters (e.g., by iterating over combinations of select parameters) for the ML/AI model that reduce model error. As used herein, labelling refers to an expected output of the machine learning model (e.g., a classification, an expected output value, etc.) Alternatively, unsupervised training (e.g., used in deep learning, a subset of machine learning, etc.) involves inferring patterns from inputs to select parameters for the ML/AI model (e.g., without the benefit of expected (e.g., labeled) outputs).
In examples disclosed herein, ML/AI models are trained using known software samples (e.g., malicious and/or clean). However, any other training algorithm may additionally or alternatively be used. In examples disclosed herein, training is performed on a set of models optimized for a selected objective (e.g., performance, accuracy, cost, power, energy, efficiency, etc.).
Training is performed using hyperparameters that control how the learning is performed (e.g., a learning rate, a number of layers to be used in the machine learning model, etc.).
Training is performed using training data. In examples disclosed herein, the training data may be any type of dataset of features (e.g., AI features).
Once training is complete, the model is deployed for use as an executable construct that processes an input and provides an output based on the network of nodes and connections defined in the model. The model is stored in a memory. The model may then be executed by the model management circuitry 208 of
Once trained, the deployed model may be operated in an inference phase to process data. In the inference phase, data to be analyzed (e.g., live data) is input to the model, and the model executes to create an output. This inference phase can be thought of as the AI “thinking” to generate the output based on what it learned from the training (e.g., by executing the model to apply the learned patterns and/or associations to the live data). In some examples, input data undergoes pre-processing before being used as an input to the machine learning model. Moreover, in some examples, the output data may undergo post-processing after it is generated by the AI model to transform the output into a useful result (e.g., a display of data, an instruction to be executed by a machine, etc.).
In some examples, output of the deployed model may be captured and provided as feedback. By analyzing the feedback, an accuracy of the deployed model can be determined. If the feedback indicates that the accuracy of the deployed model is less than a threshold or other criterion, training of an updated model can be triggered using the feedback and an updated training data set, hyperparameters, etc., to generate an updated, deployed model.
Exploration and discovery of new Artificial Intelligence (AI) features is a time-consuming problem. The rapid discovery of new hardware features will accelerate the time-to-market for new AI products and/or features.
Currently, training and inference stages in DL model management systems are focused on a single DL model. Some of these single DL models are decomposed into multiple smaller models, however, the focus of these DL model management systems is on single abstract entities. These current DL model management systems do not analyze differences between alternative models to gain insights and to propose new features for AI feature development and/or exploration.
Neural Architecture Search (NAS) refers to approaches for Deep Learning (DL) model management that focus on finding the right network topology for a particular set of requirements. Hardware-aware NAS approaches consider information from the target hardware (HW) when searching for an optimal neural network topology. The primary focus of hardware-aware NAS approaches is to find a single DL model that fits the listed criteria.
Current NAS approaches to DL model management treat each discovered model in isolation. That is, they do not further consider the existence of differences between models (e.g., candidate features optimized for different objectives by the NAS algorithm) to discover new features and/or gain further insights.
Most current NAS solutions fail to consider how, where, and in what conditions the optimized models will be deployed. For instance, the target hardware might have other processes affecting the availability of the device's resources while the model was optimized, creating an assumption that all available resources would be allocated to that model during inference. This proves to be a significant disadvantage during deployment, however, since if the target hardware undergoes a change in resource utilization during runtime, the hardware will most likely require a model replacement to another model that is better suited for the new conditions.
Model duality must be leveraged in order to explore two or more different architectural options optimized for multiple objectives (e.g., accuracy, latency, performance, cost, etc.). A delta between these architectural options is identified and explored to establish new features and/or gaps in the software (SW) or hardware (HW) to aid in model design/management and/or hardware co-optimization.
In some examples, a composable ML compute node can be implemented by a single homogeneous computing or electronic system that may be configured and/or otherwise utilized to execute an AI/ML model. For example, the composable ML compute node can be implemented by a single Central Processor Unit (CPU), Graphics Processor Unit (GPU), Artificial Intelligence Processor (AI Processor), Field Programmable Gate Array (FPGA), Digital Signal Processor (DSP), XPU, etc. In some examples, the composable ML compute node can be implemented by portion(s) of a single homogeneous computing or electronic system, such as portion(s) (e.g., kernel(s)) of a single CPU, GPU, AI Processor, FPGA, DSP, XPU, etc. In some such examples, the portion(s) can include a kernel (e.g., a hardware kernel) and/or corresponding interconnect(s) to which different kernel(s), hardware, etc., can be coupled (e.g., physically coupled, communicatively coupled, coupled via a computing or electrical bus, etc.). In some examples, a composable ML compute node can be implemented by multiple ones of the same type of homogeneous computing or electronic system, or portion(s) thereof. For example, the composable ML compute node can be implemented by two or more CPUs (or portion(s) thereof), two or more GPUs (or portion(s) thereof), two or more AI Processors (or portion(s) thereof), two or more FPGAs (or portion(s) thereof), two or more DSPs (or portion(s) thereof), two or more XPUs (or portion(s) thereof), etc.
In some examples, a composable ML compute node can be implemented by a single heterogeneous computing or electronic system that may be configured and/or otherwise utilized to execute an AI/ML model. For example, the composable ML compute node can be implemented by a CPU, a GPU, an AI Processor, an FPGA, a DSP, XPU, etc., and/or any combination(s) thereof. In some such examples, the composable ML compute node can be implemented by one or more CPUs, one or more GPUs, one or more AI Processors, one or more FPGAs, one or more DSPs, one or more XPUs, etc., and/or any combination(s) thereof. In some examples, the composable ML compute node can be implemented by portion(s) of a single heterogeneous computing or electronic system, such as portion(s) of a CPU, GPU, AI Processor, FPGA, DSP, XPU, etc., and/or any combination(s) thereof. In some examples, a composable ML compute node can be implemented by multiple ones of the same heterogeneous computing or electronic system, or portion(s) thereof. For example, the composable ML compute node can be implemented by two or more instances of a heterogeneous computing system, which includes one or more CPUs (or portion(s) thereof), one or more GPUs (or portion(s) thereof), one or more AI Processors (or portion(s) thereof), one or more FPGAs (or portion(s) thereof), one or more DSPs (or portion(s) thereof), one or more XPUs (or portion(s) thereof), etc., and/or combination(s) thereof. In some examples, the composable ML compute node can be implemented by two or more different heterogeneous computing or electronic systems. For example, the composable ML compute node can be implemented by a first heterogeneous computing system and a second heterogeneous computing system. In some such examples, portion(s) of the first heterogeneous computing system and the second heterogeneous computing system can be different.
In some examples, the composable ML compute node can include, store, and/or otherwise access an executable construct to execute an AI/ML model to complete a workload, or portion(s) thereof. For example, the executable construct can be implemented by a configuration image, an executable binary, executable code (e.g., executable machine-readable code), an executable file (e.g., an executable binary file), an executable program, executable instructions (e.g., executable machine-readable instructions), etc., that, when executed, can implement an AI/ML model to effectuate completion of AI/ML workloads.
The AutoML architecture 100 of the illustrated example includes example optimized applications 104, example optimized middleware and frameworks 106, and example application programming interfaces (APIs) 108. In some examples, the optimized applications 104 can be implemented by applications (e.g., software applications, web- or browser-based applications, etc.) that are customized, tailored, and/or otherwise optimized to effectuate the identification and/or generation of a composable ML compute node. For example, the optimized applications 104 can be accessed, utilized, etc., by a developer (e.g., a software developer, a researcher, etc.), Information Technology (IT) personnel, etc. In some such examples, the optimized applications 104 can be accessed, utilized, etc., to co-design a hardware/software (HW/SW) solution for a technical problem that can benefit from AI/ML techniques. In some examples, the optimized middleware and frameworks 106 can be implemented by middleware and frameworks that are customized, tailored, and/or otherwise optimized to effectuate the identification and/or generation of a composable ML compute node. For example, the optimized middleware and frameworks 106 can implement an interface (e.g., communication, connectivity, etc.) between the optimized applications 104 and the APIs 108.
The APIs 108 of the illustrated example can be invoked to program, develop, and/or otherwise generate an AI/ML application by at least one of direct programming or API-based programming. The APIs 108 of the illustrated example include example porting tools 110, example direct programming APIs 112, example API-based programming APIs 114, and example analysis tools 116.
In some examples, the porting tools 110 can be implemented by software (e.g., a software application) that can adapt a program for the purpose of achieving some form of execution in a first computing or electronic environment that is different from a second computing or electronic environment for which the program was originally designed. For example, the porting tools 110 can convert and/or otherwise adapt a first program developed for a first type of hardware, operating system (OS), library, etc., into a second program for a second type of hardware, OS, library, etc.
In some examples, the direct programming APIs 112 can be invoked to effectuate direct programming tasks, which may include developing and/or compiling data parallel C++ applications. In some examples, the API-based programming APIs 114 can be invoked to effectuate API-based programming, which may include developing and/or compiling applications that call (or invoke, instantiate, etc.) a Math Kernel Library (MKL), an MKL Deep Neural Network (DNN) library, a data analytics acceleration library, a thread building block library, a parallel standard template library, a media software development kit (SDK), a deep learning deployment toolkit, a machine learning scaling library, etc., and/or any combination(s) thereof.
In some examples, the analysis tools 116 can be called, instantiated, and/or otherwise invoked to analyze hardware, software, and/or configuration(s) thereof of a composable ML compute node. For example, the analysis tools 116 can instantiate emulator(s) to emulate all of the hardware and/or software features of the composable ML compute node to generate and/or otherwise output one or more evaluation parameters. In some such examples, the evaluation parameters can include parameters representative and/or otherwise indicative of accuracy, latency, a number of cycles to complete a workload, or throughput of the composable ML compute node. In some examples, the evaluation parameters can include parameters representative and/or otherwise indicative of a processor or clock frequency, a fabric frequency, a read memory bandwidth, a write memory bandwidth, hardware de-rate factors, a number of memory ports, a number of data processing units (DPUs), a number of model layers (e.g., neural network layers, convolution layers, etc.) an activation precision (e.g., a precision of activation values to be processed), a weight precision (e.g., a precision of weight values to be processed), etc., and/or any combination(s) thereof. For example, the analysis tools 116 can execute an emulator based on the composable ML compute node. In some such examples, the analysis tools 116 can execute the emulator to determine a throughput of the composable ML compute node when the composable ML compute node executes a particular AI/ML model having a particular configuration.
In some examples, the analysis tools 116 can instantiate simulator(s) to simulate the behavior, the configuration, etc., of a composable ML compute node to generate and/or otherwise output one or more evaluation parameters. For example, the analysis tools 116 can execute a model (e.g., a simulation model, an AI/ML model, etc.) based on the composable ML compute node. In some such examples, the analysis tools 116 can execute the model to estimate, predict, and/or otherwise determine a throughput of the composable ML compute node when the composable ML compute node executes a particular AI/ML model having a particular configuration.
The AutoML architecture 100 of the illustrated example includes different types of hardware and/or software from which a composable ML compute node can be generated. In the illustrated example, the AutoML architecture 100 includes interfaces and target system software for scalar, vector, matrix, and spatial hardware. Additionally and/or alternatively, any other type of hardware may be used. In this example, the scalar hardware is implemented by an example CPU 118 and example CPU system software 120. For example, the CPU system software 120 can include instructions corresponding to a CPU Instruction Set Architecture (ISA). In this example, the vector hardware is implemented by an example GPU 122 and example GPU system software 124. For example, the GPU system software 124 can include kernels, portion(s) of code, etc., such as kernels, compute kernels, and/or shaders. In some examples, the kernels, the portion(s) of code), etc., can be represented in a high-level programming language such as, for example, a High-Level Shader Language (HLSL), OpenCL, etc.
In this example, the matrix hardware is implemented by an example AI processor 126 and example AI system software 128. For example, the AI system software 128 can include one or more AI/ML algorithms, models, etc., such as neural networks (e.g., convolution neural networks (CNNs), deep neural networks (DNNs), recurrent neural networks (RNNs), etc.), Linear Regression models, Logistic Regression Models, Decision Tree Models, Learning Vector Quantization Models, etc., and/or combination(s) thereof. In this example, the spatial hardware is implemented by an example FPGA 130 and example FPGA system software 132. For example, the FPGA system software 132 can include kernels, portion(s) of code, etc., based on a hardware description language (HDL) such as Verilog.
The ML system configurator 102 of the illustrated example can interface with the CPU 118 and/or the CPU system software 120 via an example host interface 134. The ML system configurator 102 of the illustrated example can interface with the GPU 122, the GPU system software 124, the AI processor 126, the AI system software 128, the FPGA 130, and/or the FPGA system software 132 via an example level-zero interface 136.
In the illustrated example, the CPU system software 120, the GPU system software 124, the AI system software 128, the FPGA system software 132, the host interface 134, and/or the level-zero interface 136 can correspond to and/or otherwise implement example system software below level zero 138. For example, system software below level zero 138 can correspond to and/or otherwise implement low-level direct-to-metal interfaces that are tailored to hardware, such as the CPU 118, the GPU 122, etc.
In the illustrated example, the APIs 108 can implement example system software above level zero 140 and an example developer interface 142. For example, a developer, a user, etc., can access and/or otherwise utilize the AutoML architecture 100 by way of the APIs 108. In some examples, a developer, a user, etc., can access and/or otherwise utilize system software at a higher level than low-level direct-to-metal interfaces by way of the APIs 108. In some examples, a developer, a user, etc., can access and/or otherwise utilize the system software below level zero 138 via the host interface 134 and/or the level-zero interface 136.
In examples disclosed herein, the example input dataset 202 may contain candidate features, objectives with which models are to be optimized, etc. The example input dataset 202 is transmit to the model training circuitry 204 for use in the training and/or optimization of models by the DL model management system 200.
The example model training circuitry 204, including the example difference determiner circuitry 206, the example similarity determiner circuitry 208, and the example feature collector circuitry 210, receives the example input dataset 202 and generates a set of models (e.g., first model 212A, second model 212B, and third model 212C) based on a chosen objective. For example, in the DL model management system 200 disclosed herein, the first model, 212A, is trained to optimize accuracy as the key objective, the second model, 212B, is trained to optimize performance as the key objective, and the third model, 212C, is trained to optimize cost as the key objective.
The example difference determiner circuitry 206 analyzes the feature lists of models optimized for different selected objectives (e.g., accuracy, performance, cost, etc.) to identify feature differences between the various models. In examples disclosed herein, the difference determiner circuitry 206 identifies these differences by associating features that are present when a first objective was selected for a first model (e.g., features from the first model 212A with a selected objective of accuracy) but are not present when a second objective was selected for a second model (e.g., features from the second model 212B with a selected objective of performance). In determining these differences, further insight is gained into why a model might have improved its overall performance at the cost of another objective (e.g., cost).
In some examples, the model training circuitry 204 includes means for identifying candidate differences between models optimized for different selected objectives (e.g., accuracy, performance, cost, etc.). For example, the means for identifying differences may be implemented by the example difference determiner circuitry 206. In some examples, the example difference determiner circuitry 206 may be instantiated by processor circuitry such as the example processor circuitry 512 of
The example similarity determiner circuitry 208 analyzes the feature lists of models optimized for different selected objectives (e.g., accuracy, performance, cost, etc.) to identify feature similarities between the various models. In examples disclosed herein, the similarity determiner circuitry 208 identifies these similarities by associating features that are present when a first objective was selected for a first model (e.g., features from the first model 212A with a selected objective of accuracy) and are still present when a second objective was selected for a second model (e.g., features from the second model 212B with a selected objective of performance). In determining these similarities, further insight is gained into which features are important for overall model performance (e.g., it can be concluded that some layers are very important when performing object detection).
In some examples, the model training circuitry 204 includes means for identifying similarities between models optimized for different selected objectives (e.g., accuracy, performance, cost, etc.). For example, the means for identifying similarities may be implemented by the example similarity determiner circuitry 208. In some examples, the example similarity determiner circuitry 208 may be instantiated by processor circuitry such as the example processor circuitry 512 of
The example feature collector circuitry 210 collects the list of features identified by both the difference determiner circuitry 206 and the similarity determiner circuitry 120. In some examples, the feature collector circuitry 210 may then perform further analysis on the list of collected features, however in examples disclosed herein, the list may be retained for output.
In some examples, the model training circuitry 204 includes means for collecting features identified by the example difference determiner circuitry 206 and the example similarity determiner circuitry 208. For example, the means for collecting features may be implemented by the example feature collector circuitry 210. In some examples, the example feature collector circuitry 210 may be instantiated by processor circuitry such as the example processor circuitry 512 of
The first, second, and third models (212A, 212B, and 212C) obtained from the input dataset 202 are input into the example model management circuitry 214 for further processing after use by the model training circuitry 204. In examples disclosed herein, the first model 212A is optimized to maximize the selected objective of accuracy, the second model 212B is optimized to maximize the selected objective of performance, and the third model 212C is optimized to maximize the selected objective of cost.
In examples disclosed herein, the example model management circuitry 214 includes example Quality of Service (QoS) sampling circuitry 216, example QoS selector circuitry 218, and example model scheduler circuitry 220.
The example Quality of Service (QoS) sampler circuitry 216 samples a current state of the target hardware platform. For example, the Quality of Service (QoS) sampler circuitry 216 may determine that the target hardware platform is currently responding to a high priority request from an application.
In some examples, the model management circuitry 214 includes means for determining a current state of a target hardware platform. For example, the means for determining may be implemented by the example QoS sampler circuitry 216. In some examples, the example QoS sampler circuitry 216 may be instantiated by processor circuitry such as the example processor circuitry 512 of
The example QoS selector circuitry 218 selects a quality of service (QoS) to be prioritized based on the current state of the target hardware platform, as determined by the QoS sampler circuitry 216. For example, the QoS selector circuitry 218 may choose accuracy as the QoS objective of top priority if the QoS sampler circuitry 216 establishes prior that the target hardware platform is currently responding to a high priority request from an application.
In some examples, the model management circuitry 214 includes means for selecting a quality of service (QoS) objective. For example, the means for selecting a QoS objective may be implemented by the example QoS selector circuitry 218. In some examples, the example QoS selector circuitry 218 may be instantiated by processor circuitry such as the example processor circuitry 512 of
The example model scheduler circuitry 220 selects the model that will best satisfy the requirements of the selected quality of service (QoS) objective for prioritization, for use by the target hardware platform. Additionally, the model scheduler circuitry 220 also monitors utilization metrics of the target hardware platform. If any of the utilization metrics is established to be lower than a pre-determined threshold value, the model scheduler circuitry 220 then adjusts the model selection to produce another model for use by the target hardware platform. For example, if the first model 212A begins to produce low utilization metrics on the hardware platform, the model scheduler circuitry 220 selects the second model 212B as the new model for use. If the second model 212B begins to yield low utilization metrics after some time, the model scheduler circuitry 220 may determine that the first model 212A is better for use by the hardware platform. In examples disclosed herein, the model scheduler circuitry 220 includes a feedback loop wherein the progression of selected models is used as input to the example model training circuitry 204.
In some examples, the model management circuitry 214 includes means for selecting a model. For example, the means for selecting may be implemented by the example model scheduler circuitry 220. In some examples, the example model scheduler circuitry 220 may be instantiated by processor circuitry such as the example processor circuitry 512 of
While an example manner of implementing the model training circuitry 204 of
While an example manner of implementing the model management circuitry 214 of
A flowchart representative of example hardware logic circuitry, machine readable instructions, hardware implemented state machines, and/or any combination thereof for implementing the model training circuitry 204 of
The machine readable instructions described herein may be stored in one or more of a compressed format, an encrypted format, a fragmented format, a compiled format, an executable format, a packaged format, etc. Machine readable instructions as described herein may be stored as data or a data structure (e.g., as portions of instructions, code, representations of code, etc.) that may be utilized to create, manufacture, and/or produce machine executable instructions. For example, the machine readable instructions may be fragmented and stored on one or more storage devices and/or computing devices (e.g., servers) located at the same or different locations of a network or collection of networks (e.g., in the cloud, in edge devices, etc.). The machine readable instructions may require one or more of installation, modification, adaptation, updating, combining, supplementing, configuring, decryption, decompression, unpacking, distribution, reassignment, compilation, etc., in order to make them directly readable, interpretable, and/or executable by a computing device and/or other machine. For example, the machine readable instructions may be stored in multiple parts, which are individually compressed, encrypted, and/or stored on separate computing devices, wherein the parts when decrypted, decompressed, and/or combined form a set of machine executable instructions that implement one or more operations that may together form a program such as that described herein.
In another example, the machine readable instructions may be stored in a state in which they may be read by processor circuitry, but require addition of a library (e.g., a dynamic link library (DLL)), a software development kit (SDK), an application programming interface (API), etc., in order to execute the machine readable instructions on a particular computing device or other device. In another example, the machine readable instructions may need to be configured (e.g., settings stored, data input, network addresses recorded, etc.) before the machine readable instructions and/or the corresponding program(s) can be executed in whole or in part. Thus, machine readable media, as used herein, may include machine readable instructions and/or program(s) regardless of the particular format or state of the machine readable instructions and/or program(s) when stored or otherwise at rest or in transit.
The machine readable instructions described herein can be represented by any past, present, or future instruction language, scripting language, programming language, etc. For example, the machine readable instructions may be represented using any of the following languages: C, C++, Java, C#, Perl, Python, JavaScript, HyperText Markup Language (HTML), Structured Query Language (SQL), Swift, etc.
As mentioned above, the example operations of
“Including” and “comprising” (and all forms and tenses thereof) are used herein to be open ended terms. Thus, whenever a claim employs any form of “include” or “comprise” (e.g., comprises, includes, comprising, including, having, etc.) as a preamble or within a claim recitation of any kind, it is to be understood that additional elements, terms, etc., may be present without falling outside the scope of the corresponding claim or recitation. As used herein, when the phrase “at least” is used as the transition term in, for example, a preamble of a claim, it is open-ended in the same manner as the term “comprising” and “including” are open ended. The term “and/or” when used, for example, in a form such as A, B, and/or C refers to any combination or subset of A, B, C such as (1) A alone, (2) B alone, (3) C alone, (4) A with B, (5) A with C, (6) B with C, or (7) A with B and with C. As used herein in the context of describing structures, components, items, objects and/or things, the phrase “at least one of A and B” is intended to refer to implementations including any of (1) at least one A, (2) at least one B, or (3) at least one A and at least one B. Similarly, as used herein in the context of describing structures, components, items, objects and/or things, the phrase “at least one of A or B” is intended to refer to implementations including any of (1) at least one A, (2) at least one B, or (3) at least one A and at least one B. As used herein in the context of describing the performance or execution of processes, instructions, actions, activities and/or steps, the phrase “at least one of A and B” is intended to refer to implementations including any of (1) at least one A, (2) at least one B, or (3) at least one A and at least one B. Similarly, as used herein in the context of describing the performance or execution of processes, instructions, actions, activities and/or steps, the phrase “at least one of A or B” is intended to refer to implementations including any of (1) at least one A, (2) at least one B, or (3) at least one A and at least one B.
As used herein, singular references (e.g., “a”, “an”, “first”, “second”, etc.) do not exclude a plurality. The term “a” or “an” object, as used herein, refers to one or more of that object. The terms “a” (or “an”), “one or more”, and “at least one” are used interchangeably herein. Furthermore, although individually listed, a plurality of means, elements or method actions may be implemented by, e.g., the same entity or object. Additionally, although individual features may be included in different examples or claims, these may possibly be combined, and the inclusion in different examples or claims does not imply that a combination of features is not feasible and/or advantageous.
As illustrated in
At block 310, the difference determiner circuitry 206 checks whether the models contained within the example dataset received in block 305 (e.g., input dataset 202 from
At block 315, the difference determiner circuitry 206 identifies feature differences between each of the models received for processing in block 305. In examples disclosed herein, the example dataset received for processing in block 305 includes a variety of models, each model optimized for a different objective on the same target hardware platform. Accordingly, the difference determining circuity 206 identifies feature differences between each of the models by comparing lists of features present in each of the models and selecting those which are not present in all models. For example, certain features that are present for a model with a selected objective of accuracy but are not present for a model with a selected objective of performance are identified by the difference determiner circuitry 206.
At block 320, the example similarity determiner circuitry 208 performs a similar process as the example difference determiner circuitry 206, however, feature similarities between each of the models are identified. For example, certain features that are present for a model with a selected objective of accuracy and are also present for a model with a selected objective of performance are identified by the similarity determiner circuitry 208.
At block 325, the example feature collector circuitry 210 aggregates the features identified by the example difference determiner circuitry 206 and the example similarity determiner circuitry 208 into a single set. In example disclosed herein, the feature collector circuitry 210 may output the aggregated feature set.
As illustrated in
At block 410, the QoS selector circuitry 218 chooses a quality of service (QoS) objective (e.g., cost, accuracy, performance, etc.) to prioritize based on the current state of the hardware platform determined in block 405 (e.g., currently responding to a high priority request from an application) by the QoS sampler circuitry 216. For example, the QoS selector circuitry 218 may choose accuracy as the QoS objective of top priority if the QoS sampler circuitry 216 establishes that the hardware platform is currently responding to a high priority request from an application.
At block 415, the QoS selector circuitry 218 sorts the collection of models, each optimized for a different QoS objective, based on the selected QoS priority objective in block 410. In examples disclosed herein, the QoS selector circuitry 218 may sort the collection of models in descending order, based on ability to maximize the selected QoS objective for prioritization.
At block 420, the QoS selector circuitry 218 checks to see if the list of sorted models (e.g., sorted based on ability to maximize the selected QoS objective for prioritization) is empty. If the QoS selector circuitry 218 determines that the list is empty, the process moves back to block 405. However, if the QoS selector circuitry 218 determines that the list is not empty, the process moves forward to block 425.
At block 425, the model scheduler circuitry 220 selects the model that will satisfy the requirements of the selected QoS objective for prioritization, for use by the target hardware platform. In examples disclosed herein, since the list of optimized models is sorted in descending order based on ability to satisfy the selected QoS priority objective, the first model in the list is selected for use.
At block 430, the model scheduler circuitry 220 determines whether the selected model is yielding low utilization metrics on the target hardware platform. If the model scheduler circuitry 220 determines that the model does indeed have low utilization metrics, the process moves to block 435. However, if the model scheduler circuitry 220 determines that the selected model is not yielding low utilization metrics on the target platform, the process is ended.
At block 435, the model scheduler circuitry 220, after determining that the selected model is yielding low utilization metrics on the target hardware platform, removes the model in current use from the list of sorted models. Then, the process moves back to block 420 where the QoS selector circuitry 218 checks to see if the list of sorted models is empty.
The processor platform 600 of the illustrated example includes processor circuitry 612. The processor circuitry 512 of the illustrated example is hardware. For example, the processor circuitry 512 can be implemented by one or more integrated circuits, logic circuits, FPGAs, microprocessors, CPUs, GPUs, DSPs, and/or microcontrollers from any desired family or manufacturer. The processor circuitry 512 may be implemented by one or more semiconductor based (e.g., silicon based) devices. In this example, the processor circuitry 512 implements the example model training circuitry 204, including the example difference determiner circuitry 206, the example similarity determiner circuitry 208, and the example feature collector circuitry 210 and the example model management circuitry 214, including the example quality of service (QoS) sampler circuitry 216, the example QoS selector circuitry 218, and the example model scheduler circuitry.
The processor circuitry 512 of the illustrated example includes a local memory 513 (e.g., a cache, registers, etc.). The processor circuitry 512 of the illustrated example is in communication with a main memory including a volatile memory 514 and a non-volatile memory 516 by a bus 518. The volatile memory 514 may be implemented by Synchronous Dynamic Random Access Memory (SDRAM), Dynamic Random Access Memory (DRAM), RAMBUS® Dynamic Random Access Memory (RDRAM®), and/or any other type of RAM device. The non-volatile memory 516 may be implemented by flash memory and/or any other desired type of memory device. Access to the main memory 514, 516 of the illustrated example is controlled by a memory controller 517.
The processor platform 500 of the illustrated example also includes interface circuitry 520. The interface circuitry 520 may be implemented by hardware in accordance with any type of interface standard, such as an Ethernet interface, a universal serial bus (USB) interface, a Bluetooth® interface, a near field communication (NFC) interface, a Peripheral Component Interconnect (PCI) interface, and/or a Peripheral Component Interconnect Express (PCIe) interface.
In the illustrated example, one or more input devices 522 are connected to the interface circuitry 520. The input device(s) 522 permit(s) a user to enter data and/or commands into the processor circuitry 512. The input device(s) 522 can be implemented by, for example, an audio sensor, a microphone, a camera (still or video), a keyboard, a button, a mouse, a touchscreen, a track-pad, a trackball, an isopoint device, and/or a voice recognition system.
One or more output devices 524 are also connected to the interface circuitry 520 of the illustrated example. The output device(s) 524 can be implemented, for example, by display devices (e.g., a light emitting diode (LED), an organic light emitting diode (OLED), a liquid crystal display (LCD), a cathode ray tube (CRT) display, an in-place switching (IPS) display, a touchscreen, etc.), a tactile output device, a printer, and/or speaker. The interface circuitry 520 of the illustrated example, thus, typically includes a graphics driver card, a graphics driver chip, and/or graphics processor circuitry such as a GPU.
The interface circuitry 520 of the illustrated example also includes a communication device such as a transmitter, a receiver, a transceiver, a modem, a residential gateway, a wireless access point, and/or a network interface to facilitate exchange of data with external machines (e.g., computing devices of any kind) by a network 526. The communication can be by, for example, an Ethernet connection, a digital subscriber line (DSL) connection, a telephone line connection, a coaxial cable system, a satellite system, a line-of-site wireless system, a cellular telephone system, an optical connection, etc.
The processor platform 500 of the illustrated example also includes one or more mass storage devices 528 to store software and/or data. Examples of such mass storage devices 528 include magnetic storage devices, optical storage devices, floppy disk drives, HDDs, CDs, Blu-ray disk drives, redundant array of independent disks (RAID) systems, solid state storage devices such as flash memory devices and/or SSDs, and DVD drives.
The machine executable instructions 532, which may be implemented by the machine readable instructions of
The cores 602 may communicate by a first example bus 604. In some examples, the first bus 604 may implement a communication bus to effectuate communication associated with one(s) of the cores 602. For example, the first bus 604 may implement at least one of an Inter-Integrated Circuit (I2C) bus, a Serial Peripheral Interface (SPI) bus, a PCI bus, or a PCIe bus. Additionally or alternatively, the first bus 604 may implement any other type of computing or electrical bus. The cores 602 may obtain data, instructions, and/or signals from one or more external devices by example interface circuitry 606. The cores 602 may output data, instructions, and/or signals to the one or more external devices by the interface circuitry 606. Although the cores 602 of this example include example local memory 620 (e.g., Level 1 (L1) cache that may be split into an L1 data cache and an L1 instruction cache), the microprocessor 600 also includes example shared memory 610 that may be shared by the cores (e.g., Level 2 (L2_cache)) for high-speed access to data and/or instructions. Data and/or instructions may be transferred (e.g., shared) by writing to and/or reading from the shared memory 610. The local memory 620 of each of the cores 602 and the shared memory 610 may be part of a hierarchy of storage devices including multiple levels of cache memory and the main memory (e.g., the main memory 514, 516 of
Each core 602 may be referred to as a CPU, DSP, GPU, etc., or any other type of hardware circuitry. Each core 602 includes control unit circuitry 614, arithmetic and logic (AL) circuitry (sometimes referred to as an ALU) 616, a plurality of registers 618, the L1 cache 620, and a second example bus 622. Other structures may be present. For example, each core 602 may include vector unit circuitry, single instruction multiple data (SIMD) unit circuitry, load/store unit (LSU) circuitry, branch/jump unit circuitry, floating-point unit (FPU) circuitry, etc. The control unit circuitry 614 includes semiconductor-based circuits structured to control (e.g., coordinate) data movement within the corresponding core 602. The AL circuitry 616 includes semiconductor-based circuits structured to perform one or more mathematic and/or logic operations on the data within the corresponding core 602. The AL circuitry 616 of some examples performs integer based operations. In other examples, the AL circuitry 616 also performs floating point operations. In yet other examples, the AL circuitry 616 may include first AL circuitry that performs integer based operations and second AL circuitry that performs floating point operations. In some examples, the AL circuitry 616 may be referred to as an Arithmetic Logic Unit (ALU). The registers 618 are semiconductor-based structures to store data and/or instructions such as results of one or more of the operations performed by the AL circuitry 616 of the corresponding core 602. For example, the registers 618 may include vector register(s), SIMD register(s), general purpose register(s), flag register(s), segment register(s), machine specific register(s), instruction pointer register(s), control register(s), debug register(s), memory management register(s), machine check register(s), etc. The registers 618 may be arranged in a bank as shown in
Each core 602 and/or, more generally, the microprocessor 600 may include additional and/or alternate structures to those shown and described above. For example, one or more clock circuits, one or more power supplies, one or more power gates, one or more cache home agents (CHAs), one or more converged/common mesh stops (CMSs), one or more shifters (e.g., barrel shifter(s)) and/or other circuitry may be present. The microprocessor 600 is a semiconductor device fabricated to include many transistors interconnected to implement the structures described above in one or more integrated circuits (ICs) contained in one or more packages. The processor circuitry may include and/or cooperate with one or more accelerators. In some examples, accelerators are implemented by logic circuitry to perform certain tasks more quickly and/or efficiently than can be done by a general purpose processor. Examples of accelerators include ASICs and FPGAs such as those discussed herein. A GPU or other programmable device can also be an accelerator. Accelerators may be on-board the processor circuitry, in the same chip package as the processor circuitry and/or in one or more separate packages from the processor circuitry.
More specifically, in contrast to the microprocessor 600 of
In the example of
The interconnections 710 of the illustrated example are conductive pathways, traces, vias, or the like that may include electrically controllable switches (e.g., transistors) whose state can be changed by programming (e.g., using an HDL instruction language) to activate or deactivate one or more connections between one or more of the logic gate circuitry 708 to program desired logic circuits.
The storage circuitry 712 of the illustrated example is structured to store result(s) of the one or more of the operations performed by corresponding logic gates. The storage circuitry 712 may be implemented by registers or the like. In the illustrated example, the storage circuitry 712 is distributed amongst the logic gate circuitry 708 to facilitate access and increase execution speed.
The example FPGA circuitry 700 of
Although
In some examples, the processor circuitry 512 of
A block diagram illustrating an example software distribution platform 805 to distribute software such as the example machine readable instructions 532 of
From the foregoing, it will be appreciated that example systems, methods, apparatus, and articles of manufacture have been disclosed for dynamic XPU hardware-aware deep learning (DL) model management. Disclosed systems, methods, apparatus, and articles of manufacture improve the efficiency of using a computing device by allowing for the rapid discovery of new hardware features, which accelerates the time-to-market for new Artificial Intelligence (AI) products and/or features and enhances performance improvement measures for computing devices through application of the newly-discovered features. Disclosed systems, methods, apparatus, and articles of manufacture are accordingly directed to one or more improvement(s) in the operation of a machine such as a computer or other electronic and/or mechanical device.
Example methods, apparatus, systems, and articles of manufacture to for dynamic XPU hardware-aware deep learning (DL) model management are disclosed herein. Further examples and combinations thereof include the following:
Example 1 includes an apparatus for a deep learning (DL) model management system comprising interface circuitry, processor circuitry including one or more of at least one of a central processing unit, a graphic processing unit or a digital signal processor, the at least one of the central processing unit, the graphic processing unit or the digital signal processor having control circuitry to control data movement within the processor circuitry, arithmetic and logic circuitry to perform one or more first operations according to instructions, and one or more registers to store a result of the one or more first operations, the instructions in the apparatus, a Field Programmable Gate Array (FPGA), the FPGA including logic gate circuitry, a plurality of configurable interconnections, and storage circuitry, the logic gate circuitry and interconnections to perform one or more second operations, the storage circuitry to store a result of the one or more second operations, or Application Specific Integrated Circuitry (ASIC) including logic gate circuitry to perform one or more third operations, the processor circuitry to perform at least one of the first operations, the second operations, or the third operations to instantiate difference determiner circuitry to analyze feature lists of models optimized for selected objectives to identify feature differences between a plurality of models, similarity determiner circuitry to analyze the plurality of feature lists of the plurality of models optimized for the plurality of selected objectives to identify feature similarities between the plurality of models, QoS selector circuitry to establish a QoS objective for prioritization of the plurality of selected objectives, and model scheduler circuitry to choose a model from the plurality of models for use on a target hardware platform.
Example 2 includes the apparatus of example 1, wherein the processor circuitry is to instantiate QoS sampler circuitry to sample a current state of the target hardware platform.
Example 3 includes the apparatus of example 1, wherein the QoS selector circuitry is to further sort the plurality of models based on an ability to maximize the QoS objective for prioritization.
Example 4 includes the apparatus of example 1, wherein the model scheduler circuitry is to further calculate model utilization metrics for the chosen model on the target hardware platform, and in response to determining that the model utilization metrics are below a threshold value, select another model of the plurality of models for use on the target hardware platform.
Example 5 includes the apparatus of example 1, wherein feature collector circuitry is to retain the plurality of features identified by the difference determiner circuitry and the similarity determiner circuitry.
Example 6 includes a method for deep learning (DL) model training, the method comprising extracting a plurality of models from a dataset, respective ones of the plurality of models optimized for a selected quality of service (QoS) objective of a plurality of QoS objectives, identifying a plurality of feature differences between respective ones of the plurality of models, and identifying a plurality of feature similarities between respective ones of the plurality of models.
Example 7 includes the method of example 6, wherein the plurality of feature differences and the plurality of feature similarities are aggregated for retention.
Example 8 includes a method for deep learning (DL) model management, the method comprising sampling a current state of a target hardware platform, selecting a quality of service (QoS) objective of a plurality of QoS objectives for prioritization based on the current state of the target hardware platform, sorting a plurality of models, respective ones of the plurality of models optimized for respective ones of the plurality of QoS objectives, selecting a model of the sorted plurality of models for use by the target hardware platform, calculating utilization metrics for the model on the target hardware platform, and in response to determining that the utilization metrics do not satisfy a threshold, selecting another model of the plurality of models for use by the target hardware platform.
Example 9 includes the method of example 8, wherein the sorting of the models is based on the selected QoS objective.
Example 10 includes a non-transitory computer readable medium comprising instructions that, when executed, cause a machine to at least analyze feature lists of models optimized for selected objectives to identify feature differences between a plurality of models, analyze the plurality of feature lists of the plurality of models optimized for the plurality of selected objectives to identify feature similarities between the plurality of models, establish a QoS objective for prioritization of the plurality of selected objectives, and choose a model from the plurality of models for use on a target hardware platform.
Example 11 includes the non-transitory computer readable medium of example 11, wherein a current state of the target hardware platform is sampled.
Example 12 includes the non-transitory computer readable medium of example 11, wherein the plurality of models are sorted based on an ability to maximize the QoS objective for prioritization.
Example 13 includes the non-transitory computer readable medium of example 11, wherein the instructions, when executed, further cause the machine to calculate model utilization metrics for the chosen model on the target hardware platform, and in response to determining that the model utilization metrics are below a threshold value, select another model of the plurality of models for use on the target hardware platform.
Example 14 includes the non-transitory computer readable medium of example 11, wherein the plurality of features identified by the difference determiner circuitry and the similarity determiner circuitry are retained.
Example 15 includes an apparatus comprising at least one interface circuit, instructions in the apparatus, and processor circuitry to execute the instructions to analyze feature lists of models optimized for selected objectives to identify feature differences between a plurality of models, analyze the plurality of feature lists of the plurality of models optimized for the plurality of selected objectives to identify feature similarities between the plurality of models, establish a QoS objective for prioritization of the plurality of selected objectives, and choose a model from the plurality of models for use on a target hardware platform.
Example 16 includes the apparatus of example 15, wherein the processor circuitry is to sample a current state of the target hardware platform.
Example 17 includes the apparatus of example 15, wherein the processor circuitry is to further sort the plurality of models based on an ability to maximize the QoS objective for prioritization.
Example 18 includes the apparatus of example 15, wherein the processor circuitry is to further calculate model utilization metrics for the chosen model on the target hardware platform, and in response to determining that the model utilization metrics are below a threshold value, select another model of the plurality of models for use on the target hardware platform.
Example 19 includes the apparatus of example 15, wherein processor circuitry is to retain the plurality of features identified by the difference determiner circuitry and the similarity determiner circuitry.
Example 20 includes the apparatus of example 18, wherein the threshold for model utilization metrics is a predetermined threshold.
The following claims are hereby incorporated into this Detailed Description by this reference. Although certain example systems, methods, apparatus, and articles of manufacture have been disclosed herein, the scope of coverage of this patent is not limited thereto. On the contrary, this patent covers all systems, methods, apparatus, and articles of manufacture fairly falling within the scope of the claims of this patent.
This application claims priority to U.S. Provisional Patent Application No. 63/222,938, which was filed on Jul. 16, 2021. U.S. Provisional Patent Application No. 63/222,938 is hereby incorporated by reference in its entirety.