Method and system for pruning neural networks using stratified analysis

The pruning engine optimizes neural networks by reducing weights and connections through a formula-based approach, addressing high calculation costs and resource constraints, thereby improving efficiency and reducing training time.

JP7623038B2Active Publication Date: 2025-01-28MOFFETT TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
JP2023532776
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-11-30
Filing Date
2021-10-28
Publication Date
2025-01-28
Estimated Expiration
2041-10-28

AI Technical Summary

Technical Problem

Neural networks, particularly deep neural networks and convolutional neural networks, face high calculation costs due to large memory requirements and processing resources, which are not feasible for edge devices with limited storage and processing capabilities.

Method used

A pruning engine analyzes neural networks to reduce the number of weights and connections by generating a pruned neural network without extensive re-training, using a formula-based approach to determine optimal connection subsets for each layer.

Benefits of technology

This method significantly reduces memory usage and processing resources required for neural networks, minimizing the time and effort needed for training, thus enhancing efficiency and reducing the overall computational burden.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007623038000019
    Figure 0007623038000019
  • Figure 0007623038000020
    Figure 0007623038000020
  • Figure 0007623038000021
    Figure 0007623038000021
Patent Text Reader

Abstract

The embodiments disclosed herein allow neural networks to be pruned. The inputs and outputs generated by a reference neural network are used to prune the reference neural network. The pruned neural network may have a subset of the weights present in the reference neural network.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS This application claims the benefit of U.S. Non-provisional Patent Application No. 17 / 107,046, filed November 30, 2020, the disclosure of which is incorporated by reference herein in its entirety.

[0002] FIELD OF THE DISCLOSURE Embodiments of the present disclosure relate generally to artificial intelligence. More particularly, embodiments of the present disclosure relate to methods and systems for pruning neural networks, such as deep neural networks. [Background technology]

[0003] Neural networks, such as deep neural networks (DNNs) and convolutional neural networks (CNNs), have become widely used techniques in artificial intelligence (AI) to extract high-level information from low-level data such as images, videos, audio, and text. However, the high computational cost of neural networks can prevent their use in applications with low budgets for energy consumption, processing capacity / resources, storage space, and / or latency tolerance. For example, edge devices such as mobile phones and surveillance cameras may not have large storage / processing resources, etc. Summary of the Invention

[0004] The computational cost of neural networks can come from a variety of sources. First, neural network parameters can be on the order of millions or tens of millions resulting in huge storage costs, which can prohibit storage of neural network parameters in memory space. Second, the number of neurons in a neural network can consume large memory space and may require billions of arithmetic operations at run time. Third, search engines based on vector representations generated by neural networks, such as face comparison engines, can be computationally expensive, based in part on high-dimensional dense vector representations (embeddings) of neural networks.

[0005] Embodiments of the present disclosure are illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings in which like reference symbols indicate similar elements and in which: [Brief description of the drawings]

[0006] [Figure 1] FIG. 2 illustrates the operation of a neural network, in accordance with one or more embodiments of the present disclosure. [Diagram 2] FIG. 1 illustrates an example neural network, in accordance with one or more embodiments of the present disclosure. [Diagram 3] FIG. 2 illustrates an example pruning engine in accordance with one or more embodiments of the present disclosure. [Figure 4] FIG. 1 is a flow diagram illustrating an example process for pruning a neural network in accordance with one or more embodiments of the present disclosure. [Diagram 5] FIG. 1 is a block diagram illustrating an exemplary computing device in accordance with one or more embodiments of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0007] Various embodiments and aspects of the present disclosure are described with reference to the details set forth below, and the accompanying drawings illustrate various embodiments. The following description and drawings are illustrative of the present disclosure and should not be construed as limiting the present disclosure. Numerous specific details are described in order to provide a thorough understanding of the various embodiments of the present disclosure. However, in some instances, well-known or conventional details are not described in order to provide a concise description of the various embodiments of the present disclosure.

[0008] References herein to "one embodiment" or "an embodiment" mean that a particular feature, structure, or characteristic described in connection with that embodiment may be included in at least one embodiment of the present disclosure. The appearances of the phrase "in one embodiment" in various places in the specification do not necessarily all refer to the same embodiment.

[0009] A neural network may include thousands or millions of nodes and / or weights. Storing these weights and / or nodes may use a huge amount of storage space. In addition, a huge amount of processing / computational resources may be used to execute the neural network 200 (e.g., to process / analyze input data using the neural network 200). For example, each of the weights may be applied to the input, which increases the number of calculations and / or operations performed by the neural network. Therefore, it may be useful to reduce the number of weights / connections and / or nodes in the neural network. This should reduce the amount of storage space used to store the neural network and reduce the processing / computational resources used.

[0010] FIG. 1 illustrates an example neural network 100 in accordance with one or more embodiments of the present disclosure. The neural network may be a deep neural network. The deep neural network may be a neural network that includes multiple intermediate layers (e.g., multiple layers of nodes and / or weights / connections between the nodes). In one embodiment, the neural network may be a convolutional neural network (CNN), which may be a type / class of deep neural network. A neural network (e.g., a CNN) may use convolution and pooling operations to process inputs and generate and output inferences, decisions, and the like. CNNs may often be used to perform image analysis and / or image processing.

[0011] As shown in FIG. 1, an input 110 may be provided (e.g., passed, fed, etc.) to the neural network 100. For example, the input 110 may include one or more images (e.g., digital images, pictures, etc.) to be processed and / or analyzed by the neural network 100. The input 110 may be processed by a first kernel 115. The first kernel 115 may also be referred to as a convolution filter. A convolution filter may include one or more kernels (e.g., convolution kernels). For example, the input (e.g., an image) may have multiple channels (e.g., multiple input channels such as red, blue, green, an input channel for each pixel of the image). The first kernel 115 may include a filter for each channel. The first kernel 115 may be used to perform a convolution operation on the input 110. A convolution operation may be or may refer to an operation that can merge two sets of information into an output. For example, the first kernel 115 may include weights (e.g., values) that can be applied to portions of the input to generate an output. The first kernel 115 may also be referred to as a layer (eg, a hidden layer) of the neural network.

[0012] In one embodiment, the output generated by the first kernel 115 may be a feature map 120. The feature map 120 may be the result of applying the first kernel 115 (e.g., a set of weights) to the values ​​of the input. For example, the feature map 120 may be the result of an element-wise matrix multiplication and a sum of the results.

[0013] In one embodiment, the neural network 100 may also include and / or perform a pooling operation that may be performed on the feature map 120. The pooling operation may refer to a down-dumping of the feature map, reducing the height and weights of the feature map 120 while keeping the same depth. For example, max pooling (e.g., a type of pooling that may use the maximum value within a pooling range) may be applied to the feature map 120. The feature map 120 may be an output of the first kernel 115 (e.g., the output of the first layer) and may also be an input provided to the second kernel 125 (e.g., the input of the second subsequent layer).

[0014] The second kernel 125 may receive the feature map 120 (e.g., an input feature map) and may apply a convolution operation to the feature map 120 to generate the feature map 130. As described above, one or more pooling operations may be performed on the feature map 130. The feature map 130 may be an output of the second kernel 125 (e.g., an output of one layer) or may be an input provided to the third kernel 135 (e.g., an input of another subsequent layer). The third kernel 135 may receive the feature map 130 (e.g., an input feature map) and may apply a convolution operation to the feature map 130 to generate the feature map 140. As described above, one or more pooling operations may be performed on the feature map 140. The feature map 140 may be an output of the third kernel 135 (e.g., an output of one layer) or may be an input provided to the fourth kernel 145 (e.g., an input of another subsequent layer).

[0015] The fourth kernel 145 may receive the feature map 140 (e.g., an input feature map) and may apply a convolution operation to the feature map 140 to generate the feature map 150. As described above, one or more pooling operations may be performed on the feature map 150. The feature map 150 may be an output of the fourth kernel 145 (e.g., the output of one layer) and may also be an input provided to the fully connected layer 160.

[0016] 1, neural network 100 also includes fully connected layers 160 and 170. In one embodiment, fully connected layers 160 and 170 may use the outputs of previous layers (e.g., feature maps 120, 130, 140, and / or 150) and may generate a final output of neural network 100 (e.g., a final inference, decision, etc.).

[0017] 2 illustrates an example neural network 200 in accordance with one or more embodiments of the present disclosure. The neural network 200 may be used to model relationships between (e.g., complex) inputs and outputs or to find patterns in data, where dependencies between inputs and outputs may not be easily ascertained. The neural network 200 may also be a computational model that may be used to determine features in input data through various computations. For example, the neural network 200 may determine features (e.g., numbers, shapes, patterns, etc.) in input data (e.g., audio data, image data, video data, etc.) according to a structure that defines the order in which computations are performed.

[0018] The neural network 200 may be a deep neural network (CNN). The CNN may be a feed-forward neural network. A feed-forward neural network may be a type of neural network in which the connections between nodes do not form cycles. For example, signals, messages, data, information, etc. flow forward from the input layer 210 of the neural network 200 from left to right (e.g., from the input nodes), through the intermediate layers 220, and to the output layer 220 (e.g., to the output nodes). Signals, messages, data, information, etc. do not go backwards through the neural network (e.g., do not go from right to left). CNNs may be used for image analysis. The connections and / or their associated weights may take the form of convolution filters (and / or convolution kernels) that may be applied to an input (e.g., may be applied to different pixels of an image). Although this disclosure may refer to image analysis for CNNs, in other embodiments, CNNs may be used for other types of data and inputs.

[0019] The neural network 200 includes an input layer 210, a hidden layer 220, and an output layer 220. Each of the input layer 210, the hidden layer 220, and the output layer 220 includes one or more nodes 205. Each of the input layer 210, the hidden layer 220, and the output layer 220 may have a different number of nodes 205. The neural network 200 may be a deep neural network (DNN) or a deep CNN. The neural network may be deep (e.g., a deep neural network) if there are two or more hidden layers 220 (e.g., if there are four, ten, or some other suitable number of hidden layers 220). As shown in FIG. 2, the neural network 200 includes two hidden layers 220 (e.g., two columns of nodes 205). In one embodiment, the hidden layers 220 may include the nodes 205 and connections / weights coupled to the nodes 205 in the hidden layers 220. The nodes of the hidden layer may receive inputs (e.g., outputs such as feature maps generated by a previous layer) intended for the hidden layer 220. Weights (e.g., kernels / filters) may be applied to the inputs to generate the outputs (e.g., custom maps) of the current hidden layer.

[0020] Each of the nodes 205 in a layer is connected to either a node 205 in the next level (e.g., the next sublayer) or to a node 205 in another layer, as represented by the arrows / lines between the nodes 205. For example, the nodes 205 in the input layer are each coupled to at least one node 205 in the first hidden layer 220. The neural network 200 may be a fully connected neural network. For example, each node 205 in each layer or level is a connector to each node in the next layer or level, if there is one (nodes 205 in the output layer 220 are not connected to other nodes).

[0021] Each connection may be associated with (e.g., may have) a weight or weight value. The weight or weight value may define a coefficient applied to a calculation. For example, the weight or weight value may be a scaling factor between two or more nodes 205. Each node 205 may represent the sum of its inputs, and the weight or weight value associated with a connection may represent a coefficient or scaling factor by which the output of the node 205 in that connection is multiplied. The weights between the nodes 205 may be determined, calculated, generated, assigned, learned, etc. during a training process for the neural network. For example, backpropagation may be used to set the weights such that the neural network 200 produces an expected output value given the corresponding values ​​in the labeled training data. Thus, the weights of the hidden layer 220 may be viewed as an encoding of meaningful patterns in the data. The weights of the connections between the nodes 205 may be modified by further training.

[0022] Although neural network 200 is depicted with a particular number of nodes 205, layers, and connections, in other embodiments, various neural network architectures / configurations may be used, for example, different fully connected neural networks and partially connected neural networks (where not all nodes in adjacent layers are connected).

[0023] Although this disclosure may refer to convolutional neural networks, other types of neural networks and / or deep neural networks may be used in other embodiments, for example, partially connected deep neural networks, recurrent neural networks, long short-term memory (LSTM) neural networks, etc.

[0024] As described above, neural network 200 may include thousands or millions of nodes and / or weights. Storing neural network 200 may use a huge amount of storage space due to the large number of nodes and / or weights. In addition, a huge amount of processing / computational resources may be used to execute neural network 200 (e.g., to process / analyze input data using neural network 200). Therefore, it may be useful to reduce the number of weights / connections and / or nodes in neural network 200. This should reduce the amount of storage space used to store the neural network and reduce the processing / computational resources used.

[0025] 3 is a diagram illustrating an example pruning engine 300 in accordance with one or more embodiments of the present disclosure. The pruning engine 300 may be located within a computing device 380. The computing device 380 may include hardware such as a processing device (e.g., a processor, a central processing unit (CPU), a programmable logic device (PLD), etc.), memory (e.g., random access memory (e.g., RAM), storage devices (e.g., hard disk drives (HDD), solid state drives (SSD), etc.), and other hardware devices (e.g., sound cards, video cards, etc.). The computing device 380 may be any suitable type of computing device or machine having a programmable processor, including, for example, a server computer, a desktop computer, a laptop computer, a tablet computer, a smartphone, a set-top box, etc. In some examples, the computing device 38 3. Computing device 380 may comprise a single machine or may include multiple interconnected machines (e.g., multiple servers arranged in a cluster). Computing device 380 may run or include an operating system (OS). The OS may manage the execution of other components of computing device 380 (e.g., software, applications, etc.) and / or manage access to hardware (e.g., processor, memory, storage devices, etc.). Although this disclosure may refer to computing device 380, in other embodiments, pruning engine 300 may be located in other types of computing environments, such as a virtual environment. For example, pruning engine 300 may be located in a virtual machine (VM), container, etc. in other embodiments.

[0026] As described above, the neural network 310 may include thousands or millions of nodes and / or weights. Storing the neural network 310 may use a vast amount of storage space due to the large number of nodes and / or weights. In addition, a vast amount of processing / computational resources may be used to execute the neural network 310 (e.g., to process / analyze input data using the neural network 310). Reducing the number of weights / connections and / or nodes in the neural network (e.g., pruning the neural network, sparse the neural network) can alleviate the problems described above.

[0027] However, neural networks are generally retrained after they are pruned. As explained above, training a neural network can be a time-consuming, processing-intensive, and / or costly process. To train a neural network, training data 350 may be passed (e.g., provided) to the neural network hundreds or thousands of times before the weights of the connections between the nodes of the neural network are accurately set. Passing training data 350 through a neural network hundreds / thousands of times (or more) may significantly increase the time (e.g., days, weeks, etc.) required to train the neural network. In addition, passing training data 350 through a neural network hundreds / thousands of times may use a significant amount of processing resources and / or power.

[0028] In one embodiment, the pruning engine 300 may obtain and / or analyze the neural network 310. For example, the pruning engine 300 may retrieve and / or access the neural network 310 from a data store (e.g., memory, disk drive, etc.). As shown in FIG. 3, the neural network 310 includes a set of nodes (shown as circles within the neural network 310) and a set of connections (shown as lines between the nodes / circles) that interconnect the nodes in the set of nodes. The connections between the nodes may also be referred to as weights. The neural network 310 may also be referred to as an original neural network, a reference neural network, a teacher neural network, etc.

[0029] In one embodiment, the pruning engine 300 may generate a neural network 320 (e.g., a second neural network) based on the neural network 310 (e.g., a first neural network). The neural network 320 may include a subset of the connections in the neural network 310. For example, the neural network 320 may be generated by determining, selecting, identifying, etc., a subset of the connections from each layer of the neural network 310. The subset of the connections from each layer of the neural network 310 may be used to generate the neural network 320. The neural network 320 may also include a subset of the nodes in the neural network 310. For example, after selecting the subset of the connections from the neural network 310, some nodes in the neural network 320 may not be connected to any other nodes via connections. These nodes may be removed from the neural network 320. Determining, selecting, identifying, etc., a subset of the connections and / or nodes in the neural network may be referred to as pruning the neural network, scarifying the neural network, etc.

[0030] In one embodiment, pruning engine 300 may generate a second neural network by analyzing the intermediate layers of neural network 310. For each of the intermediate layers of neural network 310, pruning engine 300 may determine (e.g., identify, select, etc.) a subset of weights in each intermediate layer. Pruning engine 300 may generate neural network 320 using a different subset of connections from each intermediate layer. For example, neural network 320 may have the same number of layers as neural network 310. However, neural network 320 may have fewer connections in one or more layers.

[0031] In one embodiment, the pruning engine 300 may generate the neural network 320 without training and / or retraining the neural network 320. For example, the pruning engine 300 may not use any training data to generate the neural network 320. The pruning engine 300 may generate the neural network 320 following inputs provided to different layers of the neural network 310 and based on references generated by the different layers of the neural network 310, as described in more detail below. For example, each layer of the neural network 310 may receive inputs (e.g., input data, feature maps, outputs of previous layers, etc.) and may generate outputs (e.g., feature maps) based on the inputs. The pruning engine may use the inputs and / or outputs of intermediate layers of the neural network 310 to identify a subset of connections (e.g., weights) to be used within the layer of the neural network 320. The inputs provided to the intermediate layers of the neural network 310 may be referred to as reference inputs, and the outputs generated by the intermediate layers of the neural network 310 may be referred to as reference outputs.

[0032] In one embodiment, pruning engine 300 may be able to simultaneously (or substantially simultaneously) determine the subset of connections for each of the layers of neural network 320. As described above, pruning engine 300 may have access to all of the reference inputs and reference outputs of the layers of neural network 310. This may enable pruning engine 300 to parallelize the determination of the subset of connections for each hidden layer of neural network 320.

[0033] In one embodiment, the pruning engine 300 may generate the neural network 320 using the training data 350. However, compared to a standard neural network training process, the pruning engine 300 may not provide the training data 350 to the neural network 320 hundreds or thousands of times. Instead, the number of times that the pruning engine 300 may pass the training data 350 to the neural network 320 may be fewer than the number of times that the training data 350 was provided to the neural network 310 to train the neural network 310. For example, the training data 350 may be passed to the neural network 320 once or twice. The pruning engine may generate the neural network 320 based on reference outputs generated by different layers of the neural network 310, as described in more detail below.

[0034] In one embodiment, the neural network 320 may be generated layer by layer. For example, the pruning engine 300 may generate a kernel / filter for the first layer based on an input provided to the neural network 320. The input may be used to generate a first filter based on a first reference output feature map (e.g., a feature map generated by the neural network 310). The input may be training data 350. The output of the first filter may be used to generate a second filter. For example, the pruning engine 300 may determine the second filter based on the second reference output feature map and the output of the first filter. Thus, the filters of the neural network 320 may be generated sequentially layer by layer.

[0035] As described above, the neural network 320 may be generated based on one or more of the neural network 310, the reference input to the intermediate layer of the neural network 310, and the reference output of the intermediate layer of the neural network 310. In one embodiment, the neural network 320 may be generated based on the following equation (1):

number

[0036] In one embodiment, the term X in Equation (1) may represent one or more feature maps (e.g., one or more reference inputs) provided to an intermediate layer of the neural network 310. As described above, the neural network 320 may have the same number of layers as the neural network 310. Each intermediate layer of the neural network 320 may correspond to and / or be associated with a layer of the neural network 310. The same feature map (e.g., X) provided to a layer of the neural network 310 may be used to determine the connections / weights of the corresponding layer of the neural network 320. The one or more feature maps X may have dimensions (e.g., shape) [N, H, W, C], where H is the height, W is the width, C is the number of input channels, and N is the number of samples (e.g., the number of feature maps). For example, multiple feature maps (e.g., N feature maps) may be included in X. Each of the feature maps may have three channels (e.g., C=3), i.e., a channel for red, a channel for blue, and a channel for blue.

[0037] In one embodiment, Y may be a reference output generated by a corresponding layer of the neural network 310. For example, Y may represent one or more feature maps generated by a corresponding layer of the neural network 310 based on the feature map X provided to the corresponding layer of the neural network 310. The one or more feature maps Y may have dimensions (e.g., shape) [N, H, W, K], where H is the height, W is the width, K is the number of output channels, and N is the number of samples (e.g., the number of feature maps).

[0038] In one embodiment, W is a filter (e.g., one or more kernels including connections / weights) to be determined for a layer of the neural network 320. For example, W may be a filter included in a corresponding layer of the neural network 320. Thus, equation (1) may indicate that the pruning engine 300 obtains (e.g., determines, calculates, etc.) a W (e.g., filter) that minimizes the difference between Y (e.g., a reference output) and the result when the filter W is applied to the input X. W may have dimensions (e.g., shape) [R, S, C, K], where R is the height, S is the width, C is the number of input channels, and K is the number of output channels. The filter W may be applied to the input X in a convolution operation (e.g., the “*” operation in equation (1)).

[0039] Equation (1) can be expressed (e.g., decomposed, unpacked, transformed, simplified, etc.) into K independent problems, one problem for each output channel K. Equation (2) may be used to represent each of the K independent problems.

number

[0040] A convolution operation (eg, "*") may be reduced to an R x S matrix multiplication problem, ie, each of the C variables shown in equation (3) below.

number

[0041] The terms of equation (3) may be modified to produce equation (4) below:

number

number

number

number

number

[0042] Equation (4) can be further modified as shown in equations (5a), (5b), and (5c).

number

number

number

[0043] Referring to equation (5c) above, the term

number

number

number

number

number

[0044] Based on equations (1)-(5c) above, pruning engine 300 may solve for the term w. For example, pruning engine 300 may perform regression analysis, linear regression, and / or other statistical regression to solve for the term w. Solving for the term w results in kernels for the intermediate layers of neural network 320. As described above, pruning engine 300 may determine (e.g., calculate, determine, obtain, etc.) kernels (e.g., one or more filters, convolution filters, etc.) for each intermediate layer simultaneously and / or sequentially (e.g., layer by layer).

[0045] In one embodiment, equations (1)-s may enable pruning engine 300 to determine neural network 320 (e.g., determine weights used in kernels / filters of neural network 320) without using any training data. For example, pruning engine 300 may generate kernels / filters using inputs and / or outputs generated by neural network 310 (e.g., a reference neural network, a teacher neural network, etc.). In another embodiment, pruning engine 350 may generate kernels / filters for intermediate layers of neural network 320 sequentially, layer by layer (e.g., kernels for a first intermediate layer are generated, then kernels for a second intermediate layer are generated, etc.). Generating kernels for each layer may enable pruning engine 300 to pass training data 350 through neural network 320 a smaller number of times (e.g., 1-2 times) compared to a typical training process that may pass training data through a neural network hundreds or thousands of times.

[0046] Pruning engine 300 can reduce the time, effort, computational / processing resources, etc., that may be used to create a pruned (e.g., sparse) neural network (e.g., neural network 320). By refraining from using training data 350 (e.g., not using training data 350 at all) or by using training data 350 a small number of times (e.g., one or two times), pruning engine 300 can save time and / or resources when generating neural network 320. For example, pruning engine 300 may be able to generate neural network 320 without passing training data through the neural network hundreds or thousands of times. This may greatly increase efficiency and / or reduce the time taken to prune a neural network.

[0047] 4 is a flow diagram illustrating an example process 400 for pruning a deep neural network in accordance with one or more embodiments of the present disclosure. Process 400 may be performed by processing logic, which may comprise hardware (e.g., circuitry, dedicated logic, programmable logic, processor, processing device, central processing unit (CPU), system on chip (SoC), etc.), software (e.g., instructions operating / executed on a processing device), firmware (e.g., microcode), or a combination thereof. In some embodiments, process 400 may be performed by one or more of a computing device (e.g., computing device 380 shown in FIG. 3) and a pruning engine (e.g., pruning engine 300 shown in FIG. 3).

[0048] With reference to FIG. 4, process 400 illustrates exemplary functions employed by various embodiments. Although specific functional blocks ("blocks") are disclosed in process 400, such blocks are examples. That is, embodiments are well suited to performing various other blocks or variations of blocks recited in process 400. It should be appreciated that blocks in process 400 may be performed in an order different from that presented, and that not all of the blocks in process 400 may be performed. Additionally, still other blocks (not shown in FIG. 4) may be inserted between the blocks illustrated in FIG. 4.

[0049] Process 400 begins at block 405, where process 400 obtains a first neural network. The first neural network may be a neural network to be pruned (e.g., thinned) to reduce the size of the neural network and / or to reduce the amount of computational / processing resources used. At block 410, process 400 may generate a second neural network based on the first neural network.

[0050] Block 410 includes further blocks 411, 412, and 413. In block 411, process 400 may analyze one or more hidden layers of the first neural network. For example, process 400 may obtain inputs provided to the hidden layers of the first neural network (e.g., reference input feature maps) and / or outputs generated by the hidden layers (e.g., reference output feature maps). In block 412, process 400 may determine (e.g., identify, select, calculate, etc.) a subset of weights for each hidden layer. For example, each layer of the first neural network may include a set of weights. Process 400 may identify a subset of weights in each layer to determine a corresponding layer of the second neural network. Process 400 may stack, flatten, and / or process various matrices as described above to identify a set of weights for each layer. Selecting the subset of weights may be referred to as generating a filter for the layer. In one embodiment, process 400 can identify a subset of weights for each layer simultaneously for all layers. For example, process 400 can access the inputs and / or outputs generated by each layer of the first neural network. This can enable process 400 to simultaneously generate filters for each corresponding layer in the second neural network (solve for w for all layers at the same time). In another embodiment, process 400 can generate each filter for each layer sequentially. For example, process 400 can generate a next filter for a next layer after generating a current filter for a current layer. At block 413, process 400 can generate the second neural network based on the subset of weights identified for each layer.

[0051] FIG. 5 is a block diagram of an exemplary computing device 500, according to some embodiments. The computing device 500 may be connected to other computing devices in a LAN, an intranet, an extranet, and / or the Internet. The computing device may operate in the capacity of a server machine in a client-server network environment, or in the capacity of a client in a peer-to-peer network environment. The computing device may be provided by a personal computer (PC), a set-top box (STB), a server, a network router, switch or bridge, or any machine capable of executing (sequentially or otherwise) a set of instructions that specify actions to be taken by that machine. Additionally, although a single computing device is illustrated, the term "computing device" should also be taken to include any collection of computing devices that, alone or together, execute a set (or sets) of instructions to perform the methods described herein.

[0052] The exemplary computing device 500 may include a processing device (e.g., a general-purpose processor, a programmable logic device (PLD), etc.) 502, a main memory 504 (e.g., synchronous dynamic random access memory (DRAM), read-only memory (ROM)), a static memory 506 (e.g., flash memory), and a data storage device 518, which may communicate with each other via a bus 530.

[0053] The processing device 502 may be provided by one or more general-purpose processing devices, such as a microprocessor, a central processing unit, etc. In an illustrative example, the processing device 502 may comprise a complex instruction set computing (CISC) microprocessor, a reduced instruction set computing (RISC) microprocessor, a very long instruction word (VLIW) microprocessor, or a processor implementing other instruction sets or a processor implementing a combination of instruction sets. The processing device 502 may also comprise an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a digital signal processor (DSP), a network processor, etc. The processing device 502 may be configured to perform the operations described herein in accordance with one or more aspects of the present disclosure to perform the operations and steps described herein.

[0054] The computing device 500 may further include a network interface device 508 capable of communicating with a network 520. The computing device 500 may also include a video display unit 510 (e.g., a liquid crystal display (LCD) or a cathode ray tube (CRT)), an alphanumeric input device 512 (e.g., a keyboard), a cursor control device 514 (e.g., a mouse), and an audio signal generating device 516 (e.g., a speaker). In one embodiment, the video display unit 510, the alphanumeric input device 512, and the cursor control device 514 may be combined into a single component or device (e.g., an LCD touch screen).

[0055] The data storage device 518 may include a computer-readable storage medium 528 on which pruning engine instructions 525, e.g., one or more sets of instructions for performing operations described herein according to one or more aspects of the present disclosure, may be stored. The pruning engine instructions 525 may also reside, completely or at least partially, within the main memory 504 and / or the processing device 502 during their execution by the computing device 500, the main memory 504, and the processing device 502, which also constitute the computer-readable medium. The pruning engine instructions 525 may further be transmitted or received over a network 520 via the network interface device 508.

[0056] Although the computer-readable storage medium 528 is shown in the illustrative example as being a single medium, the term "computer-readable storage medium" should be taken to include a single medium or multiple media (e.g., a centralized or distributed database and / or associated caches and servers) that store one or more sets of instructions. The term "computer-readable storage medium" should also be taken to include any medium that is capable of storing, encoding, or carrying a set of instructions for execution by a machine and that causes a machine to perform the methods described herein. The term "computer-readable storage medium" should therefore be taken to include, but is not limited to, solid-state memory, optical media, and magnetic media.

[0057] Unless specifically stated otherwise, terms such as "obtain," "generate," "analyze," "determine," "stack," "flatten," and the like refer to actions and processes performed or implemented by a computing device that manipulate data represented as physical (electronic) quantities in the registers and memory of the computing device and convert it into other data that is similarly represented as physical quantities in the memory or registers of the computing device, or other devices that store, transmit, or display such information. Also, as used herein, terms such as "first," "second," "third," "fourth," and the like are intended to be labels that distinguish between different elements and may not necessarily have an ordinal meaning according to their numerical designation.

[0058] The examples described herein also relate to an apparatus for performing the operations described herein. This apparatus may be specially constructed for the required purposes, or it may comprise a general-purpose computing device selectively programmed by a computer program stored in the computing device. Such a computer program may be stored in a computer-readable non-transitory storage medium.

[0059] The methods and illustrative examples described herein are not inherently related to any particular computer or other apparatus. Various general-purpose systems may be used in accordance with the teachings described herein, or it may prove convenient to construct more specialized apparatus to perform the required method steps. The required structure for a variety of these systems will appear as described in the above description.

[0060] The above description is illustrative and not restrictive. While the present disclosure has been described with reference to specific, illustrative examples, it will be recognized that the disclosure is not limited to the described examples. The scope of the present disclosure should be determined with reference to the following claims, along with the full scope of equivalents to which such claims are entitled.

[0061] As used herein, the singular forms "a," "an," and "the" are intended to include the plural unless the context clearly indicates otherwise. It will be further understood that the terms "comprises," "comprising," "including," and / or "comprising," as used herein, specify the presence of stated features, integers, steps, operations, components, and / or components, and do not preclude the presence or addition of one or more other features, integers, steps, operations, components, components, and / or combinations thereof. Thus, the terminology used herein is only for the purpose of describing particular embodiments and is not intended to be limiting.

[0062] It should also be noted that in some alternative implementations, the functions / acts shown may occur out of the order shown in the figures. For example, two figures shown in succession may in fact be executed substantially in parallel or may sometimes be executed in the reverse order, depending on the functions / acts involved.

[0063] Although the operations of the methods have been described in a particular order, it should be understood that other operations may be performed between the operations described, the operations described may be coordinated such that they occur at slightly different times, or the operations described may be distributed within a system that enables the occurrence of processing operations at various intervals associated with the processing.

[0064] Various units, circuits, or other components may be described or claimed as being "configured" or "configurable" to perform one or more tasks. In such contexts, the phrase "configured" or "configurable" is used to imply structure by indicating that the unit / circuit / component includes structure (e.g., circuitry) that performs one or more tasks during operation. As such, a unit / circuit / component may be said to be configured to perform or configurable to perform a task even when the specified unit / circuit / component is not currently operational (e.g., not on). A unit / circuit / component used with the words "configured" or "configurable" includes hardware, e.g., circuits, memory that stores program instructions executable to perform an operation, etc. Listing a unit / circuit / component as being "configured" to perform one or more tasks or "configurable" to perform one or more tasks does not invoke 112 U.S.C. 6 para. 102 against that unit / circuit / component. Additionally, "configured" or "configurable" can include a general structure (e.g., a general circuit) that is manipulated by software and / or firmware (e.g., an FPGA or general-purpose processor running software) to operate in a manner capable of performing the tasks in question. "Configured" can also include adapting a manufacturing process (e.g., a semiconductor manufacturing facility) to produce a device (e.g., an integrated circuit) adapted to perform or execute one or more tasks. "Configurable" does not apply to blank media, unprogrammed processors or unprogrammed general computers or unprogrammed programmable logic devices, programmable gate arrays, or other unprogrammed devices unless accompanied by programmed media that confer the capability to the unprogrammed device to be configured to perform the disclosed functions.

[0065] The above description for illustrative purposes has been described with reference to specific embodiments. However, the above exemplary description is not intended to be exhaustive or to limit the invention to the precise form disclosed. Many modifications or variations are possible in light of the above teachings. The embodiments are chosen and described to best explain the principles of the embodiments and their practical application, so as to enable those skilled in the art to best utilize the embodiments and various modifications as may be adapted to the particular use contemplated. Therefore, the present embodiments should be considered as illustrative and not restrictive, and the invention should not be limited to the details given herein, but may be modified within the scope of the appended claims and their equivalents.

Claims

1. Obtaining a first neural network, the first neural network is trained using a first set of training data; the first neural network comprises a first set of nodes; the first neural network comprises a first set of connections interconnecting the first set of nodes; Steps and generating a second neural network based on the first neural network, analyzing a set of hidden layers of the first neural network; determining a subset of weights for each of the hidden layers, the subset of weights comprising generating a respective filter based on inputs and reference outputs provided to the hidden layers, each of the filters comprising a respective one of the subsets of weights; generating the second neural network based on the subset of weights for each hidden layer; Equipped with the second neural network comprises a second set of connections interconnecting a second set of nodes, the second set of connections comprising a subset of the first set of connections; the second neural network is generated without using the first set of training data; Steps and A method comprising:

2. The input is: Stacking the first set of input feature maps to generate a first combined feature map. and the input comprises the first combined feature map. The method of claim 1.

3. The method of claim 2 , wherein the first set of input feature maps is generated by a first filter of the first neural network.

4. The reference output is Flattening the output feature maps to generate vectors and the reference output comprises the vector. The method of claim 1.

5. The method of claim 4 , wherein the output feature map is generated based on a second filter of the first neural network.

6. The method of claim 1 , wherein the subset of weights for each hidden layer is determined simultaneously for each hidden layer.

7. generating the second neural network comprises: Generating the second neural network without training the second neural network. The method of claim 1 , comprising:

8. The method of claim 1 , wherein the second set of nodes comprises a subset of the first set of nodes.

9. A processor; a memory coupled to the processor for storing instructions which, when executed by the processor, cause the processor to perform a method according to any one of claims 1 to 8; An apparatus comprising:

10. Obtaining a first neural network, the first neural network is trained by passing a set of training data through the first neural network a first number of times; the first neural network comprises a first set of nodes; the first neural network comprises a first set of connections interconnecting the first set of nodes; Steps and generating a second neural network based on the first neural network, the second neural network comprises a second set of connections interconnecting a second set of nodes, the second set of connections comprising a subset of the first set of connections; the second neural network is trained by passing the set of training data through the second neural network a second number of times, the second number of times being less than the first number of times; Steps and A method comprising:

11. generating the second neural network based on the first neural network, analyzing a set of hidden layers of the first neural network; determining a subset of weights for each hidden layer; generating the second neural network based on the subset of weights for each hidden layer; The method of claim 10 comprising:

12. determining the subset of weights for each hidden layer, generating, for each hidden layer, a respective filter based on the inputs and reference outputs provided to the hidden layer, each filter comprising a subset of weights; The method of claim 11 , comprising:

13. The input is: Stacking the first set of input feature maps to generate a first combined feature map. and the input comprises the first combined feature map. The method of claim 12.

Citation Information

Patent Citations

  • Artificial neural network class-based pruning

    JP2018129033A

  • Speaker recognition using neural networks

    US20160293167A1

  • Pruning neural networks that include element-wise operations

    US20200160185A1

  • Device and method for compressing machine learning model

    US20200311552A1

  • Computing device for training artificial neural network model, method of training the artificial neural network model, and memory system for storing the same

    US20200356860A1