Pulse sequence processing method, image classification method, device, equipment and medium

By generating and processing image pulse signal sequences, the image classification performance of the asynchronous processor is improved, the problems of slow processing speed and low accuracy are solved, and the reliability and resource utilization efficiency of the image classification model are enhanced.

CN118941878APending Publication Date: 2024-11-12SHANGHAI QI ZHI INSTITUTE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411171787.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-26
Publication Date
2024-11-12

AI Technical Summary

Technical Problem

Asynchronous processors are slow to process in image classification and the generated pulse signals are low, resulting in low reliability of image classification models and waste of computing resources.

Method used

By generating image pulse signal sequences, the time window sequence and weighted pulse signal sequence are determined, input to the initial neuron to generate neuron pulse signals, and update the membrane potential, filter out hidden layers that meet the conditions and store them in the output buffer for image Training of classification models.

Benefits of technology

It improves data processing speed and pulse signal accuracy, enhances the reliability of image classification model, and reduces waste of computing resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118941878A_ABST
    Figure CN118941878A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a pulse sequence processing method and device, an image classification method and device, equipment and a medium. A specific embodiment of the method comprises the following steps: receiving image data; generating an image pulse signal sequence; determining a to-be-input pulse signal sequence; the following steps are executed: determining a time window sequence; the method comprises the following steps: generating a weighted pulse signal sequence; activated neurons are obtained; a neuron pulse signal is generated, and the initial neuron and the initial membrane potential are updated; generating a neuron pulse signal sequence; determining the neuron pulse signal sequence as a to-be-input pulse signal sequence; determining the hidden layer meeting a preset processing condition as a to-be-processed hidden layer; and storing the neuron pulse signal sequence to an output buffer area. According to the embodiment, the processing speed during data processing can be increased, the accuracy of the generated pulse signal is improved, the reliability of the image classification model obtained by training the pulse signal is further improved, and the waste of computing resources is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present disclosure relate to the field of computer technology, and in particular to a pulse sequence processing method, an image classification method, a device, a device, and a medium. Background Art

[0002] Image classification is a method of assigning images to a certain category based on their different features. At present, the common method for classifying images is as follows: first, the pulse sequence corresponding to the image is input into the spiking neural network. Then, an asynchronous processor is used to accelerate the processing of the pulse sequence in the spiking neural network and generate a pulse signal. Finally, the generated pulse signal is used to train the image classification model to complete the image classification.

[0003] However, when using the above method to classify images, the following technical problems often occur:

[0004] First, the asynchronous processor has limited ability to process data in parallel within each processing unit, resulting in a slow data processing speed. In addition, the accuracy of data generated by the asynchronous processor depends on the hardware quality of the asynchronous processor. The data generated by the low-quality asynchronous processor is less accurate, which in turn leads to a lower accuracy of the generated pulse signal, resulting in a lower reliability of the image classification model trained using the pulse signal, resulting in more errors in image classification, and causing a waste of computing resources during image classification.

[0005] Second, the asynchronous processor has a weak ability to identify the generated erroneous data, which easily leads to the continuous accumulation of the generated erroneous data, which in turn leads to slow processing speed and waste of computing resources when reprocessing the data. Summary of the invention

[0006] The content of this disclosure is used to introduce concepts in a brief form, which will be described in detail in the detailed implementation section below. The content of this disclosure is not intended to identify the key features or essential features of the technical solution claimed for protection, nor is it intended to limit the scope of the technical solution claimed for protection.

[0007] Some embodiments of the present disclosure propose a pulse sequence processing method for image classification, an image classification method, a pulse sequence processing device for image classification, an image classification device, an electronic device and a computer-readable medium to solve one or more of the technical problems mentioned in the above background technology section.

[0008] In a first aspect, some embodiments of the present disclosure provide a pulse sequence processing method for image classification, the method comprising: receiving image data, wherein the image data corresponds to image label information; based on the image data, generating an image pulse signal sequence corresponding to the image data, wherein the image pulse signal sequence corresponds to each time step; determining the image pulse signal sequence as a pulse signal sequence to be input; for each hidden layer in a preset number of hidden layers, performing the following steps: based on each time step corresponding to the pulse signal sequence to be input, determining a time window sequence; for each time window in the time window sequence, performing the following steps: based on the time window and the pulse signal sequence to be input, generating a weighted pulse signal sequence corresponding to the time window; for each initial neuron in each initial neuron, the weighted pulse signal sequence is determined as a pulse signal sequence to be input; The sequence is input to the above-mentioned initial neurons to obtain corresponding activated neurons, wherein each of the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neurons correspond to an activated membrane potential; for each of the obtained activated neurons, based on the above-mentioned activated neurons, at least one neuron pulse signal is generated, and the initial neuron and the initial membrane potential corresponding to the above-mentioned activated neurons are updated; based on the generated neuron pulse signals, a neuron pulse signal sequence is generated; the above-mentioned neuron pulse signal sequence is determined as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input; the hidden layer that meets the preset processing conditions among the above-mentioned preset number of hidden layers is determined as a hidden layer to be processed; the neuron pulse signal sequence corresponding to the above-mentioned hidden layer to be processed is stored in the output buffer for training the image classification model.

[0009] In a second aspect, some embodiments of the present disclosure provide an image classification method, the method comprising: acquiring an image data set; for each image data in the above image data set, performing the following steps: performing image segmentation processing on the above image data to obtain a foreground target image; based on the above foreground target image, generating a corresponding neuron pulse signal sequence; inputting the above neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the above neuron pulse signal sequence, wherein the above image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is generated by the method described in any implementation method of the above first aspect; based on the above image label information, determining the category corresponding to the above foreground target image.

[0010] In a third aspect, some embodiments of the present disclosure provide a pulse sequence processing device for image classification, the device comprising: a receiving unit, configured to receive image data, wherein the image data corresponds to image label information; a generating unit, configured to generate an image pulse signal sequence corresponding to the image data based on the image data, wherein the image pulse signal sequence corresponds to each time step; a first determining unit, configured to determine the image pulse signal sequence as a pulse signal sequence to be input; an executing unit, configured to perform the following steps for each hidden layer in a preset number of hidden layers: determine a time window sequence based on each time step corresponding to the pulse signal sequence to be input; for each time window in the time window sequence, perform the following steps: generate a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input; for each initial neuron in each initial neuron, The weighted pulse signal sequence is input into the above-mentioned initial neurons to obtain corresponding activated neurons, wherein each of the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neurons correspond to an activated membrane potential; for each of the obtained activated neurons, based on the above-mentioned activated neurons, at least one neuron pulse signal is generated, and the initial neurons and initial membrane potentials corresponding to the above-mentioned activated neurons are updated; based on the generated neuron pulse signals, a neuron pulse signal sequence is generated; the above-mentioned neuron pulse signal sequence is determined as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input; the second determination unit is configured to determine the hidden layer that meets the preset processing conditions among the above-mentioned preset number of hidden layers as the hidden layer to be processed; the storage unit is configured to store the neuron pulse signal sequence corresponding to the above-mentioned hidden layer to be processed into the output buffer for training the image classification model.

[0011] In a fourth aspect, some embodiments of the present disclosure provide an image classification device, comprising: an acquisition unit, configured to acquire an image data set; an execution unit, configured to execute the following steps for each image data in the above image data set: performing image segmentation processing on the above image data to obtain a foreground target image; generating a corresponding neuron pulse signal sequence based on the above foreground target image; inputting the above neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the above neuron pulse signal sequence, wherein the above image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is generated by the method described in any implementation method of the above first aspect; determining the category corresponding to the above foreground target image based on the above image label information.

[0012] In a fifth aspect, some embodiments of the present disclosure provide an electronic device, comprising: one or more processors; a storage device on which one or more programs are stored, and when the one or more programs are executed by one or more processors, the one or more processors implement the method described in any implementation manner of the above-mentioned first aspect.

[0013] In a sixth aspect, some embodiments of the present disclosure provide a computer-readable medium having a computer program stored thereon, wherein when the program is executed by a processor, the method described in any implementation manner of the first aspect above is implemented.

[0014] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the pulse sequence processing method for image classification of some embodiments of the present disclosure, the processing speed of data processing can be improved, the accuracy of the generated pulse signal can be improved, and the reliability of the image classification model can be improved, and the waste of computing resources during image classification can be reduced. Specifically, the reason for the slow processing speed of data processing, the low accuracy of the generated pulse signal, the low reliability of the image classification model, and the waste of computing resources during image classification is that the asynchronous processor has limited ability to process data in parallel in each processing unit, resulting in a slow processing speed of data processing. And the accuracy of the data generated by the asynchronous processor depends on the hardware quality of the asynchronous processor. The accuracy of the data generated by the low-quality asynchronous processor is low, which in turn leads to the low accuracy of the generated pulse signal, resulting in the low reliability of the image classification model obtained by pulse signal training, resulting in more errors in image classification, resulting in waste of computing resources during image classification. Based on this, the pulse sequence processing method for image classification of some embodiments of the present disclosure, first, receives image data, wherein the above-mentioned image data corresponds to image label information. Thus, the original data to be processed can be obtained. Secondly, based on the above-mentioned image data, an image pulse signal sequence corresponding to the above-mentioned image data is generated, wherein the above-mentioned image pulse signal sequence corresponds to each time step. Thus, the image data can be converted into a corresponding image pulse signal sequence, so that the image data can be processed using a pulse neural network. Then, the above-mentioned image pulse signal sequence is determined as a pulse signal sequence to be input. Then, for each hidden layer in the preset number of hidden layers, the following steps are performed: First, based on each time step corresponding to the pulse signal sequence to be input, a time window sequence is determined. Thus, the data corresponding to each time window can be processed in sequence through the obtained time window sequence. Secondly, for each time window in the above-mentioned time window sequence, the following steps are performed: First, based on the above-mentioned time window and the pulse signal sequence to be input, a weighted pulse signal sequence corresponding to the above-mentioned time window is generated. Thus, by compressing each pulse signal to be input corresponding to the above-mentioned time window, a signal in which a pulse has occurred in each pulse signal to be input is obtained, and a signal in which a pulse has not occurred is discarded, which can speed up the processing speed of subsequent data processing. Secondly, for each initial neuron in each initial neuron, the above-mentioned weighted pulse signal sequence is input into the above-mentioned initial neuron to obtain a corresponding activated neuron, wherein each initial neuron in the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neuron corresponds to an activated membrane potential. Thus, a neuron that has received a pulse signal sequence can be obtained. Then, for each activated neuron among the obtained activated neurons, at least one neuron pulse signal is generated based on the activated neuron, and the initial neuron and the initial membrane potential corresponding to the activated neuron are updated.Thus, it is possible to determine whether a neuron will emit a pulse by the activation membrane potential corresponding to the activated neuron, and process the signal that may emit a pulse, thereby improving the accuracy of data processing. Then, based on the generated individual neuron pulse signals, a neuron pulse signal sequence is generated. Thus, the input data of the next hidden layer can be obtained. Then, the above neuron pulse signal sequence is determined as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input. Thus, the output data of the previous hidden layer can be determined as the input of the next hidden layer. Then, the hidden layer that meets the preset processing conditions in the above preset number of hidden layers is determined as the hidden layer to be processed. Thus, the last processed hidden layer can be screened out. Finally, the neuron pulse signal sequence corresponding to the above hidden layer to be processed is stored in the output buffer for training the image classification model. Thus, the neuron pulse sequence output by the last hidden layer can be used for model training. Also, because each pulse signal to be input corresponding to each time window can be compressed, only the signal with a pulse is processed, and the signal without a pulse is not processed, thus, the processing speed of data processing can be improved. Also, when processing data, it is possible to process the neurons that receive the weighted pulse signals corresponding to each time window to determine whether the neurons have pulsed in the corresponding time window, and then perform different processing on the pulse signal sequences and neurons in different time windows. This can increase the processing speed of data processing, improve the accuracy of the generated pulse signals, and further improve the reliability of the image classification model, reducing the waste of computing resources during image classification. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and that components and elements are not necessarily drawn to scale.

[0016] Figure 1 is a flow chart of some embodiments of a pulse sequence processing method for image classification according to the present disclosure;

[0017] Figure 2 are flowcharts of other embodiments of the image classification method according to the present disclosure;

[0018] Figure 3 is a schematic structural diagram of some embodiments of a pulse sequence processing device for image classification according to the present disclosure;

[0019] Figure 4 is a schematic diagram of the structure of some embodiments of the image classification device according to the present disclosure;

[0020] Figure 5 It is a schematic diagram of the structure of an electronic device suitable for implementing some embodiments of the present disclosure. DETAILED DESCRIPTION

[0021] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein. On the contrary, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.

[0022] It should also be noted that, for ease of description, only the parts related to the invention are shown in the drawings. In the absence of conflict, the embodiments and features in the embodiments of the present disclosure can be combined with each other.

[0023] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.

[0024] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".

[0025] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0026] The present disclosure will be described in detail below with reference to the accompanying drawings and in conjunction with embodiments.

[0027] Figure 1 The flowchart 100 of some embodiments of the pulse sequence processing method for image classification according to the present disclosure is shown. The pulse sequence processing method for image classification comprises the following steps:

[0028] Step 101, receiving image data.

[0029] In some embodiments, the execution subject (e.g., a computing device) of the pulse sequence processing method for image classification may receive image data. The image data may be image data corresponding to an RGB image. The image data may correspond to image label information. The image label information may be a label for characterizing a category corresponding to the image data. The execution subject may be a server for generating and processing an image pulse signal sequence. In practice, the execution subject may receive image data sent by a target server. The target server may be a server for storing and managing image data.

[0030] Step 102: Generate an image pulse signal sequence corresponding to the image data based on the image data.

[0031] In some embodiments, the execution subject may generate an image pulse signal sequence corresponding to the image data based on the image data. The image pulse signal in the image pulse signal sequence may be a pulse signal corresponding to a pixel in the image data. Each image pulse signal in the image pulse signal sequence corresponds to a timestamp. The image pulse signal sequence corresponds to each time step. The time step may be used to characterize the length of time within a unit. In practice, first, the execution subject may randomly set the step length of each time step within a preset step length range. Then, the timestamps may be mapped to each time step. The preset step length range may be the time range that can be set for each time step. For example, the preset step length range may be [3ms, 8ms]. As an example: when the step length of each time step is 4ms, the time step corresponding to the pulse signal with a timestamp of 5ms is the second time step.

[0032] In some optional implementations of some embodiments, the execution subject may generate an image pulse signal sequence corresponding to the image data based on the image data through the following steps:

[0033] In the first step, for each pixel point included in the above image data, the following steps are performed:

[0034] In the first sub-step, the product of the first color channel value corresponding to the above-mentioned pixel point and the first preset weight value is determined as the first color value. The above-mentioned image data includes various pixels, and each of the above-mentioned various pixels corresponds to a first color channel value, a second color channel value and a third color channel value. The above-mentioned first color channel value can be the RGB value of the above-mentioned pixel point under the color channel corresponding to red. The above-mentioned first preset weight value can be a pre-set value. Here, the specific setting of the above-mentioned first preset weight value is not limited. For example, the above-mentioned first preset weight value can be 0.3.

[0035] In the second sub-step, the product of the second color channel value corresponding to the pixel and the second preset weight value is determined as the second color value. The second color channel value may be the RGB value of the pixel under the color channel corresponding to blue. The second preset weight value may be a pre-set value. Here, the specific setting of the second preset weight value is not limited. For example, the second preset weight value may be 0.6.

[0036] In the third sub-step, the product of the third color channel value corresponding to the pixel and the third preset weight value is determined as the third color value. The third color channel value may be the RGB value of the pixel under the color channel corresponding to green. The third preset weight value may be a pre-set value. Here, the specific setting of the third preset weight value is not limited. For example, the third preset weight value may be 0.1.

[0037] The fourth sub-step is to determine the sum of the first color value, the second color value and the third color value as the grayscale value corresponding to the pixel point.

[0038] The fifth sub-step is to generate a normalized value corresponding to the pixel point based on the grayscale value corresponding to the pixel point. The normalized value may be a value obtained by processing the grayscale value. In practice, the execution entity may determine the normalized value as the ratio of the grayscale value to a preset value. The preset value may be 255.

[0039] The sixth sub-step is to generate the pixel pulse probability corresponding to the pixel point based on the normalized value. In practice, the execution subject may determine the normalized value as the pixel pulse probability. The pixel pulse probability may be used to characterize the probability of the pixel point generating a high-level pulse signal.

[0040] The seventh sub-step is to generate each pixel pulse signal corresponding to the above-mentioned pixel point based on the above-mentioned pixel pulse probability and the preset pixel time window. The above-mentioned pixel time window can be a time range for generating pulse signals corresponding to each pixel point included in the above-mentioned image data. The above-mentioned pixel pulse signal can be a pulse signal generated by the above-mentioned pixel point within the above-mentioned time window. Each of the above-mentioned pixel pulse signals corresponds to a timestamp. The above-mentioned timestamp can be the time point when the above-mentioned pixel pulse signal is generated. In practice, the above-mentioned execution subject can generate each pulse signal using a microprocessor within the time range corresponding to the above-mentioned pixel time window. The probability that the generated pulse signal is high level is equal to the above-mentioned pixel pulse probability.

[0041] The second step is to generate an image pulse signal sequence based on the generated pixel pulse signals and the timestamps corresponding to each pixel pulse signal in the pixel pulse signals. In practice, the execution subject can sort the pixel pulse signals in order from early to late by the timestamps to obtain a pixel pulse signal sequence. Then, the pixel pulse signal sequence can be determined as an image pulse signal sequence.

[0042] Step 103: determine the image pulse signal sequence as the pulse signal sequence to be input.

[0043] In some embodiments, the execution entity may determine the image pulse signal sequence as the pulse signal sequence to be input.

[0044] Step 104: for each hidden layer in the preset number of hidden layers, perform the following steps:

[0045] Step 1041, determining a time window sequence based on each time step corresponding to the pulse signal sequence to be input.

[0046] In some embodiments, the execution subject may determine the time window sequence based on each time step corresponding to the pulse signal sequence to be input. The hidden layer may be a hidden layer in a pulse neural network. The time window in the time window sequence may correspond to multiple time steps. The number of time steps corresponding to each time window in the time window sequence is the same. In practice, first, the execution subject may determine a preset number of adjacent time steps as a time window. Then, the time windows may be sorted from early to late by the timestamps included in each time step to obtain a time window sequence. The preset number of time steps may be a preset value. Here, the specific setting of the preset number of time steps is not limited. As an example: when each time window corresponds to two time steps, the step length of each time step is 4ms, and the timestamp corresponding to the pulse signal in the first time step is 3ms, the timestamp corresponding to the pulse signal in the second time step is 5ms, the timestamp corresponding to the pulse signal in the third time step is 9ms, and the timestamp corresponding to the pulse signal in the fourth time step is 13ms, the first time step and the second time step may be determined as the first time window. Then, the third time step and the fourth time step can be determined as the second time window. At this time, the timestamps corresponding to the first time window are 3ms and 5ms, and the timestamps corresponding to the second time window are 9ms and 13ms. When sorting, the first time window is sorted in the order of timestamps from early to late, and the corresponding time window sequence {first time window, second time window} is obtained.

[0047] Step 1042: for each time window in the time window sequence, perform the following steps:

[0048] Step 10421: Based on the time window and the pulse signal sequence to be input, generate a weighted pulse signal sequence corresponding to the time window.

[0049] In some embodiments, the execution subject may generate a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input. The weighted pulse signal sequence may be a bit sequence composed of "0" and "1" obtained by compressing each pulse signal to be input corresponding to the time window in the pulse signal sequence to be input.

[0050] In some optional implementations of some embodiments, the execution subject may generate a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input through the following steps:

[0051] The first step is to determine each of the to-be-input pulse signals corresponding to the time window in the to-be-input pulse signal sequence as each time pulse signal.

[0052] The second step is to generate a corresponding time pulse signal sequence based on the above time pulse signals. In practice, the execution subject can sort the above time pulse signals from early to late according to the timestamps corresponding to the above time pulse signals to obtain the above time pulse signal sequence.

[0053] The third step is to generate the number of time pulses corresponding to the time pulse signal sequence based on the above-mentioned time pulse signals. The above-mentioned number of time pulses can be the number of time pulse signals "1" in the above-mentioned time pulse signal sequence. In practice, the above-mentioned execution subject can obtain the number of time pulses through the POPCNT instruction.

[0054] The fourth step is to generate a weighted pulse signal sequence corresponding to the above-mentioned time pulse signal sequence based on the above-mentioned number of time pulses. In practice, the above-mentioned execution entity can convert the above-mentioned number of time pulses into a corresponding binary number. Then, the above-mentioned binary number can be determined as a weighted pulse sequence. As an example: when the above-mentioned time pulse signal sequence is "1010100", the corresponding number of time pulses is 3. The binary number corresponding to the number of time pulses is "011", and at this time "011" is the corresponding weighted pulse sequence.

[0055] Step 10422: For each initial neuron in each initial neuron, the weighted pulse signal sequence is input into the initial neuron to obtain a corresponding activated neuron.

[0056] In some embodiments, the execution subject may input the weighted pulse signal sequence into each of the initial neurons to obtain a corresponding activated neuron. Each of the initial neurons may have an initial membrane potential. The activated neuron may have an activated membrane potential. The initial neuron may be a pre-set neuron in the pulse neural network. The initial membrane potential may be a membrane potential corresponding to the initial neuron. The activated neuron may be an initial neuron after receiving the weighted pulse signal sequence. The activated membrane potential may be a membrane potential corresponding to the activated neuron.

[0057] Step 10423: for each activated neuron among the obtained activated neurons, at least one neuron pulse signal is generated based on the activated neuron, and the initial neuron and the initial membrane potential corresponding to the activated neuron are updated.

[0058] In some embodiments, the execution subject may generate at least one neuron pulse signal for each of the activated neurons obtained, based on the activated neuron, and update the initial neuron and initial membrane potential corresponding to the activated neuron. The neuron pulse signal may be a pulse signal corresponding to the activated neuron.

[0059] In some optional implementations of some embodiments, the execution subject may generate at least one neuron pulse signal based on the activated neuron, and update the initial neuron and the initial membrane potential corresponding to the activated neuron through the following steps:

[0060] The first step is to generate an activation membrane potential value corresponding to the activated neuron based on the activation membrane potential corresponding to the activated neuron. The activation membrane potential value may be a digital signal corresponding to the activation membrane potential. In practice, the execution subject may convert the activation membrane potential into the corresponding activation membrane potential value through an analog-to-digital converter.

[0061] In the second step, the initial neuron corresponding to the above activated neuron is determined as the target neuron.

[0062] The third step is to determine the initial membrane potential corresponding to the above target neuron as the target membrane potential.

[0063] The fourth step is to generate a target membrane potential value based on the target membrane potential. The target membrane potential value may be a digital signal corresponding to the target membrane potential. In practice, the execution subject may convert the target membrane potential into a corresponding target membrane potential value through an analog-to-digital converter.

[0064] Step 5: The sum of the activation membrane potential value and the target membrane potential value is determined as the cumulative membrane potential value. In practice, first, the execution subject can obtain the sum of the activation membrane potential value and the target membrane potential value by shift addition method. Then, the obtained sum can be determined as the cumulative membrane potential value.

[0065] The sixth step is to generate at least one neuron pulse signal based on the accumulated membrane potential value, and update the initial neuron and the initial membrane potential corresponding to the activated neuron. The neuron pulse signal may be a pulse signal output by the activated neuron.

[0066] In some optional implementations of some embodiments, the execution subject may generate at least one neuron pulse signal based on the accumulated membrane potential value, and update the initial neuron and the initial membrane potential corresponding to the activated neuron through the following steps:

[0067] In the first step, in response to determining that the above-mentioned cumulative membrane potential value meets the preset threshold condition, the following steps are performed:

[0068] The first sub-step is to determine the activated neuron as the corresponding initial neuron to update the initial neuron. The preset threshold condition may be that the cumulative membrane potential value is less than the preset threshold. The preset threshold may be a pre-set value. Here, the specific setting of the preset threshold is not limited.

[0069] The second sub-step is to perform data conversion processing on the accumulated membrane potential value to obtain the accumulated membrane potential. The accumulated membrane potential may be an analog signal corresponding to the accumulated membrane potential value. In practice, the execution subject may convert the accumulated membrane potential value into the corresponding accumulated membrane potential through a digital-to-analog converter.

[0070] The third sub-step is to determine the accumulated membrane potential as the initial membrane potential corresponding to the updated initial neuron, so as to update the initial membrane potential.

[0071] The fourth sub-step is to generate a null value signal as a neuron pulse signal. The neuron pulse signal has a timestamp. The null value signal may be a pulse signal whose corresponding logic number is "0" and whose corresponding level is a low level. In practice, the execution subject may generate a null value signal through a microprocessor. In practice, the execution subject may determine a level that satisfies a preset low level range as a low level. The low level range may be greater than or equal to 0 volts and less than 0.3 volts.

[0072] In some optional implementations of some embodiments, the execution subject may generate at least one neuron pulse signal based on the accumulated membrane potential value, and update the initial neuron and the initial membrane potential corresponding to the activated neuron through the following steps:

[0073] In the first step, in response to determining that the accumulated membrane potential value does not meet the preset threshold condition, the following steps are performed:

[0074] In the first sub-step, the initial neuron corresponding to the activated neuron is determined as the neuron to be input.

[0075] The second sub-step is to determine each image pulse signal in the image pulse signal sequence corresponding to the time window as each pulse signal to be processed.

[0076] The third sub-step is to perform the following steps for each of the above-mentioned pulse signals to be processed:

[0077] Sub-step 1: input the pulse signal to be processed into the neuron to be input, to obtain the neuron to be processed. The neuron to be processed may be a neuron that has received the pulse signal to be processed. The neuron to be processed corresponds to a membrane potential to be processed. The membrane potential to be processed may be the membrane potential corresponding to the neuron to be processed.

[0078] Sub-step 2: Perform data conversion processing on the to-be-processed membrane potential corresponding to the to-be-processed neuron to obtain the to-be-processed membrane potential value. The to-be-processed membrane potential value may be a digital signal corresponding to the to-be-processed membrane potential. In practice, the execution subject may convert the to-be-processed membrane potential into the to-be-processed membrane potential value through an analog-to-digital converter.

[0079] Sub-step three, in response to determining that the membrane potential value to be processed meets the preset threshold condition, executing the following steps:

[0080] First, the neuron to be processed is determined as an activated neuron, so as to update the activated neuron.

[0081] Secondly, the above-mentioned membrane potential to be processed is determined as the activated membrane potential corresponding to the updated activated neuron, so as to update the above-mentioned activated membrane potential.

[0082] Then, a null value signal is generated as a neuron pulse signal. In practice, the above execution subject can generate the null value signal through a microprocessor.

[0083] Sub-step 4: in response to determining that the membrane potential value to be processed does not meet the preset threshold condition, executing the following steps:

[0084] First, a tip signal is generated as a neuron pulse signal. The tip signal may be a pulse signal whose corresponding logic number is "1" and whose corresponding level is a high level. In practice, the execution subject may generate the tip signal through a microprocessor. In practice, the execution subject may determine a level that satisfies a preset high level range as a high level. The preset high level range may be greater than or equal to 1.8 volts and less than 3.3 volts.

[0085] Secondly, the preset resting membrane potential is determined as the membrane potential to be processed, so as to update the membrane potential to be processed to obtain an updated membrane potential to be processed. The resting membrane potential can be a membrane potential whose corresponding digital signal is less than the preset threshold.

[0086] Then, the neuron to be processed is determined as an activated neuron, so as to update the activated neuron.

[0087] Finally, the updated membrane potential to be processed is determined as the activated membrane potential corresponding to the updated activated neuron, so as to update the activated membrane potential.

[0088] The fourth sub-step is to store the generated neuron pulse signals into an output buffer. Each of the neuron pulse signals has a corresponding time stamp. The output buffer can be used to store data to be output.

[0089] The fifth sub-step is to determine the updated activated neuron as the initial neuron corresponding to the activated neuron, so as to update the initial neuron to obtain an updated initial neuron.

[0090] The sixth sub-step is to determine the updated activated membrane potential as the initial membrane potential corresponding to the updated initial neuron, so as to update the above initial membrane potential.

[0091] The above technical solution and its related contents, as an inventive point of an embodiment of the present disclosure, solve the second technical problem mentioned in the background technology: "When the asynchronous processor detects erroneous data, it will roll back to the state before the erroneous data occurs and reprocess the data. When a large amount of data is processed or a large amount of erroneous data is generated, it is easy to cause slow processing speed and waste of computing resources." The factors that lead to slow processing speed and waste of computing resources are often as follows: When the asynchronous processor detects erroneous data, it will roll back to the state before the erroneous data occurs and reprocess the data. When a large amount of data is processed or a large amount of erroneous data is generated, it is easy to cause slow processing speed and waste of computing resources. If the above factors are solved, the data processing speed can be improved and the waste of computing resources can be reduced. In order to achieve this effect, the present disclosure performs the following steps in response to determining that the above cumulative membrane potential value does not meet the preset threshold condition: First, the initial neuron corresponding to the above activated neuron is determined as the neuron to be input. Thus, the initial neuron before receiving the weighted pulse signal sequence can be determined. Then, each image pulse signal corresponding to the above time window in the above image pulse signal sequence is determined as each pulse signal to be processed. Thus, the pulse signal before each weighted processing can be obtained. Then, for each of the above-mentioned pulse signals to be processed, the following steps are performed: first, the pulse signal to be processed is input into the above-mentioned neuron to be input to obtain the neuron to be processed, wherein the neuron to be processed corresponds to a membrane potential to be processed. Thus, each pulse signal before weighted processing can be sequentially input into the above-mentioned neuron to be input. Secondly, the membrane potential to be processed corresponding to the above-mentioned neuron to be processed is subjected to data conversion processing to obtain the membrane potential value to be processed. Thus, the membrane potential value of the corresponding neuron to be processed after inputting a pulse signal to be processed can be obtained. Then, in response to determining that the membrane potential value to be processed meets the preset threshold condition, the following steps are performed: first, the neuron to be processed is determined as an activated neuron to update the activated neuron. Thus, when the membrane potential value to be processed is less than the preset threshold, it can be determined that the neuron to be processed is not activated by the pulse signal to be processed. Secondly, the membrane potential to be processed is determined as the activated membrane potential corresponding to the updated activated neuron to update the activated membrane potential. Thus, the above-mentioned activated membrane potential can be updated, the to-be-processed membrane potential after receiving a to-be-processed pulse signal can be determined as the activated membrane potential, and the second to-be-processed pulse signal can be continued to be received on the basis of receiving the first to-be-processed pulse signal. Then, a null value signal is generated as a neuron pulse signal. Thus, the output of a null value signal can be used to characterize that the above-mentioned to-be-processed neuron has not been activated. Then, in response to determining that the above-mentioned to-be-processed membrane potential value does not meet the above-mentioned preset threshold condition, the following steps are performed: First, a tip signal is generated as a neuron pulse signal.Thus, when the above-mentioned membrane potential value to be processed is greater than the preset threshold value, the above-mentioned neuron to be processed can be indicated by outputting a pulse signal to indicate that the above-mentioned neuron to be processed has been activated. Secondly, the preset resting membrane potential is determined as the membrane potential to be processed, so as to update the above-mentioned membrane potential to be processed and obtain the updated membrane potential to be processed. Thus, the above-mentioned membrane potential to be processed can be reset. Then, the above-mentioned neuron to be processed is determined as the activated neuron to update the above-mentioned activated neuron. Thus, the above-mentioned activated neuron can be updated. Then, the updated membrane potential to be processed is determined as the activated membrane potential corresponding to the updated activated neuron to update the above-mentioned activated membrane potential. Thus, the reset membrane potential to be processed can be determined as the activated membrane potential, and the activated membrane potential can be reset indirectly. Then, the generated neuron pulse signals are stored in the output buffer, wherein each neuron pulse signal in the above-mentioned neuron pulse signals corresponds to a timestamp. Thus, the generated neuron pulse signals can be obtained. Then, the updated activated neuron is determined as the initial neuron corresponding to the above-mentioned activated neuron to update the above-mentioned initial neuron to obtain the updated initial neuron. Thus, the updated initial neuron can be obtained. Finally, the updated activated membrane potential is determined as the initial membrane potential corresponding to the updated initial neuron to update the above initial membrane potential. Thus, the updated initial membrane potential can be obtained. Also, when the cumulative membrane potential value does not meet the preset threshold condition, the pulse signals before weighted processing can be used for reprocessing immediately, thereby improving the ability to identify the generated erroneous data, reducing the continuous accumulation of erroneous data, improving the processing speed during data processing, and reducing the waste of computing resources.

[0092] Step 1043, generating a neuron pulse signal sequence based on each generated neuron pulse signal.

[0093] In some embodiments, the execution subject may generate a neuron pulse signal sequence based on the generated neuron pulse signals. In practice, the execution subject may sort the neuron pulse signals from early to late according to the timestamps corresponding to the neuron pulse signals to obtain the neuron pulse signal sequence.

[0094] Step 1044: determine the neuron pulse signal sequence as the pulse signal sequence to be input, so as to update the pulse signal sequence to be input.

[0095] In some embodiments, the execution entity may determine the neuron pulse signal sequence as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input.

[0096] Step 105: determine the hidden layers that meet the preset processing conditions among the preset number of hidden layers as the hidden layers to be processed.

[0097] In some embodiments, the execution subject may determine a hidden layer that satisfies a preset processing condition among the preset number of hidden layers as a hidden layer to be processed, wherein the preset processing condition may be that the hidden layer is the last hidden layer to be processed among the preset number of hidden layers.

[0098] Step 106, storing the neuron pulse signal sequence corresponding to the hidden layer to be processed into the output buffer for use in training the image classification model.

[0099] In some embodiments, the execution subject may store the neuron pulse signal sequence corresponding to the hidden layer to be processed into an output buffer for training an image classification model. The image classification model may be a neural network model that takes the neuron pulse sequence corresponding to the image data as input and takes the image label information corresponding to the image data as output. For example, the neural network model may be a convolutional neural network.

[0100] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the pulse sequence processing method for image classification of some embodiments of the present disclosure, the processing speed of data processing can be improved, the accuracy of the generated pulse signal can be improved, and the reliability of the image classification model can be improved, and the waste of computing resources during image classification can be reduced. Specifically, the reason for the slow processing speed of data processing, the low accuracy of the generated pulse signal, the low reliability of the image classification model, and the waste of computing resources during image classification is that the asynchronous processor has limited ability to process data in parallel in each processing unit, resulting in a slow processing speed of data processing. And the accuracy of the data generated by the asynchronous processor depends on the hardware quality of the asynchronous processor. The accuracy of the data generated by the low-quality asynchronous processor is low, which in turn leads to the low accuracy of the generated pulse signal, resulting in the low reliability of the image classification model obtained by pulse signal training, resulting in more errors in image classification, resulting in waste of computing resources during image classification. Based on this, the pulse sequence processing method for image classification of some embodiments of the present disclosure, first, receives image data, wherein the above-mentioned image data corresponds to image label information. Thus, the original data to be processed can be obtained. Secondly, based on the above-mentioned image data, an image pulse signal sequence corresponding to the above-mentioned image data is generated, wherein the above-mentioned image pulse signal sequence corresponds to each time step. Thus, the image data can be converted into a corresponding image pulse signal sequence, so that the image data can be processed using a pulse neural network. Then, the above-mentioned image pulse signal sequence is determined as a pulse signal sequence to be input. Then, for each hidden layer in the preset number of hidden layers, the following steps are performed: First, based on each time step corresponding to the pulse signal sequence to be input, a time window sequence is determined. Thus, the data corresponding to each time window can be processed in sequence through the obtained time window sequence. Secondly, for each time window in the above-mentioned time window sequence, the following steps are performed: First, based on the above-mentioned time window and the pulse signal sequence to be input, a weighted pulse signal sequence corresponding to the above-mentioned time window is generated. Thus, by compressing each pulse signal to be input corresponding to the above-mentioned time window, a signal in which a pulse has occurred in each pulse signal to be input is obtained, and a signal in which a pulse has not occurred is discarded, which can speed up the processing speed of subsequent data processing. Secondly, for each initial neuron in each initial neuron, the above-mentioned weighted pulse signal sequence is input into the above-mentioned initial neuron to obtain a corresponding activated neuron, wherein each initial neuron in the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neuron corresponds to an activated membrane potential. Thus, a neuron that has received a pulse signal sequence can be obtained. Then, for each activated neuron among the obtained activated neurons, at least one neuron pulse signal is generated based on the activated neuron, and the initial neuron and the initial membrane potential corresponding to the activated neuron are updated.Thus, it is possible to determine whether a neuron will emit a pulse by the activation membrane potential corresponding to the activated neuron, and process the signal that may emit a pulse, thereby improving the accuracy of data processing. Then, based on the generated individual neuron pulse signals, a neuron pulse signal sequence is generated. Thus, the input data of the next hidden layer can be obtained. Then, the above neuron pulse signal sequence is determined as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input. Thus, the output data of the previous hidden layer can be determined as the input of the next hidden layer. Then, the hidden layer that meets the preset processing conditions in the above preset number of hidden layers is determined as the hidden layer to be processed. Thus, the last processed hidden layer can be screened out. Finally, the neuron pulse signal sequence corresponding to the above hidden layer to be processed is stored in the output buffer for training the image classification model. Thus, the neuron pulse sequence output by the last hidden layer can be used for model training. Also, because each pulse signal to be input corresponding to each time window can be compressed, only the signal with a pulse is processed, and the signal without a pulse is not processed, thus, the processing speed of data processing can be improved. Also, when processing data, it is possible to process the neurons that receive the weighted pulse signals corresponding to each time window to determine whether the neurons have pulsed in the corresponding time window, and then perform different processing on the pulse signal sequences and neurons in different time windows. This can increase the processing speed of data processing, improve the accuracy of the generated pulse signals, and further improve the reliability of the image classification model, reducing the waste of computing resources during image classification.

[0101] Further references Figure 2 , which shows a process 200 of another embodiment of the image classification method. The process 200 of the image classification method includes the following steps:

[0102] Step 201: Acquire an image dataset.

[0103] In some embodiments, the execution subject may obtain the image data set. In practice, the execution subject may obtain the image data set from the target server.

[0104] Step 202: for each image data in the image data set, perform the following steps:

[0105] Step 2021, performing image segmentation processing on the image data to obtain a foreground target image.

[0106] In some embodiments, the execution subject may perform image segmentation processing on the image data to obtain a foreground target image. The foreground target image may be an image different from a background image. In practice, the execution subject may perform image segmentation processing on the image data by segmenting all models to obtain a foreground target image.

[0107] Step 2022: Generate a corresponding neuron pulse signal sequence based on the foreground target image.

[0108] In some embodiments, the execution subject may generate a corresponding neuron pulse signal sequence based on the foreground target image. The method of generating the neuron pulse sequence may refer to the specific implementation of steps 101 to 1043, which will not be described in detail here.

[0109] Step 2023, input the neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the neuron pulse signal sequence.

[0110] In some embodiments, the execution subject may input the neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the neuron pulse signal sequence. The image classification model is trained based on the neuron pulse signal sequence stored in the output buffer. The neuron pulse signal sequence stored in the output buffer is trained based on the image classification model. Figure 1 The steps in the corresponding embodiments are generated.

[0111] In some optional implementations of some embodiments, the image classification model may be obtained by training the execution subject through the following steps:

[0112] The first step is to obtain a sample set from the output buffer. The samples in the sample set include an image, a sample neuron pulse signal sequence corresponding to the image, and sample image label information corresponding to the image. The sample neuron pulse signal sequence may be a neuron pulse signal sequence corresponding to the image in the sample. The sample image label information may be image label information corresponding to the image in the sample.

[0113] In the second step, the following training steps are performed based on the sample set:

[0114] In the first sub-step, the sample neuron pulse signal sequence of at least one sample in the sample set is respectively input into the initial neural network to obtain the image label information corresponding to each sample in the at least one sample. The initial neural network includes a feature extraction network and an output layer. The feature extraction network can be a neural network that can extract features from the neuron pulse signal sequence. For example, the feature extraction network can be a convolutional neural network. The output layer can be an activation function that can map the extracted features to the probability that the image belongs to each image label information. For example, the activation function can be a normalized exponential function (softmax).

[0115] The second sub-step is to compare the image label information corresponding to each sample in the at least one sample with the corresponding sample image label information. In practice, first, the execution subject may generate the probability distribution of the image label information corresponding to each sample in the at least one sample through a normalized exponential function. Then, the execution subject may generate the probability distribution of the sample image label information corresponding to each sample in the at least one sample through a normalized exponential function. Finally, the execution subject may generate the loss value between the probability distribution of the image label information corresponding to each sample in the at least one sample and the probability distribution of the corresponding sample image category information through a cross entropy loss function.

[0116] The third sub-step is to determine whether the initial neural network has achieved the preset optimization goal based on the comparison result. In practice, when the loss value between the image label information corresponding to a sample and the corresponding sample image label information is less than the preset loss threshold, the sample is determined to be a positive sample. The positive sample can be used to characterize samples that meet the loss value condition. The loss value condition can be that the loss value between the image label information corresponding to a sample and the corresponding sample image label information is less than the preset loss threshold. The optimization goal can be that the proportion of positive samples in all samples is greater than a preset accuracy threshold. The loss threshold can be a preset value. Here, there is no limitation on the specific setting of the loss threshold. The accuracy threshold can be a preset value. Here, there is no limitation on the specific setting of the accuracy threshold.

[0117] In a fourth sub-step, in response to determining that the initial neural network achieves the above-mentioned optimization goal, the initial neural network is determined as an image classification model.

[0118] The fifth sub-step is, in response to determining that the initial neural network does not achieve the above optimization goal, adjusting the network parameters of the initial neural network, using unused samples to form a sample set, using the adjusted initial neural network as the initial neural network, and performing the above training step again. In practice, the above execution subject can use the back propagation algorithm (BackPropagation Algorithm, BP algorithm) and the gradient descent method (such as the mini-batch gradient descent algorithm) to adjust the network parameters of the above initial neural network.

[0119] Step 2024: Determine the category corresponding to the foreground target image based on the image label information.

[0120] In some embodiments, the execution subject may determine the category corresponding to the foreground target image based on the image label information. In practice, the execution subject may determine the category corresponding to the foreground target image through the image label information. For example, when the image label information is "fruit", the category corresponding to the foreground target image is fruit. When the image category information is "animal", the category corresponding to the foreground target image is animal.

[0121] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the image classification method of some embodiments of the present disclosure, the reliability of the image classification model can be improved, the accuracy of image classification can be improved, and the waste of computing resources can be reduced. Specifically, the reliability of the image classification model is low, the accuracy of image classification is low, and the waste of computing resources is low because: the asynchronous processor has limited ability to process data in parallel in each processing unit, resulting in a slow processing speed of data processing. And the accuracy of the data generated by the asynchronous processor depends on the hardware quality of the asynchronous processor. The accuracy of the data generated by the asynchronous processor with low quality is low, which in turn leads to a low accuracy of the generated pulse signal, resulting in a low reliability of the image classification model obtained by training with the pulse signal, resulting in more errors in image classification, and causing a waste of computing resources during image classification. Based on this, the image classification method of some embodiments of the present disclosure, first, obtains an image data set. Thus, the original data to be processed can be obtained. Then, for each image data in the above image data set, the following steps are performed: First, the image data is segmented to obtain a foreground target image. Thus, the foreground target to be processed can be quickly located, and the processing speed and accuracy of the subsequent image classification processing can be improved. Then, based on the above foreground target image, a corresponding neuron pulse signal sequence is generated. Thus, the neuron pulse signal sequence corresponding to the foreground target image can be obtained. Then, the neuron pulse signal sequence is input into a pre-trained image classification model to obtain the image label information corresponding to the neuron pulse signal sequence, wherein the image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is obtained by Figure 1 The steps in the corresponding embodiments are generated. Thus, the image label information corresponding to the foreground target image can be generated by the obtained neuron pulse signal sequence. Finally, based on the image label information, the category corresponding to the foreground target image is determined. Thus, the category of the foreground target image can be obtained. Also, because the foreground target images to be identified in each image data can be segmented first, and then each foreground target image can be classified, the accuracy of image classification can be improved, the erroneous results of image classification can be reduced, and the waste of computing resources can be reduced.

[0122] Further references Figure 3 As an implementation of the methods shown in the above figures, the present disclosure provides some embodiments of a pulse sequence processing device for image classification. These device embodiments are similar to Figure 1 Corresponding to the method embodiments shown, the device can be specifically applied to various electronic devices.

[0123] like Figure 3As shown, the pulse sequence processing device 300 for image classification of some embodiments includes: a receiving unit 301, a generating unit 302, a first determining unit 303, an executing unit 304, a second determining unit 305 and a storage unit 306. The receiving unit 301 is configured to receive image data, wherein the image data corresponds to image label information; the generating unit 302 is configured to generate an image pulse signal sequence corresponding to the image data based on the image data, wherein the image pulse signal sequence corresponds to each time step; the first determining unit 303 is configured to determine the image pulse signal sequence as a pulse signal sequence to be input; the executing unit 304 is configured to perform the following steps for each hidden layer in a preset number of hidden layers: determine a time window sequence based on each time step corresponding to the pulse signal sequence to be input; for each time window in the time window sequence, perform the following steps: generate a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input; for each initial neuron in each initial neuron, input the weighted pulse signal sequence into the initial neuron; Neuron, obtain the corresponding activated neuron, wherein each of the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neuron corresponds to an activated membrane potential; for each of the obtained activated neurons, based on the above-mentioned activated neurons, generate at least one neuron pulse signal, and update the initial neuron and the initial membrane potential corresponding to the above-mentioned activated neuron; based on the generated neuron pulse signals, generate a neuron pulse signal sequence; determine the above-mentioned neuron pulse signal sequence as a pulse signal sequence to be input, so as to update the input pulse signal sequence; the second determination unit 305 is configured to determine the hidden layer that meets the preset processing conditions among the above-mentioned preset number of hidden layers as the hidden layer to be processed; the storage unit 306 is configured to store the neuron pulse signal sequence corresponding to the above-mentioned hidden layer to be processed into the output buffer for training the image classification model.

[0124] It is understood that the units described in the device 300 are similar to those described in the reference Figure 1 Therefore, the operations, features and beneficial effects described above for the method are also applicable to the device 300 and the units contained therein, and will not be described in detail here.

[0125] Further references Figure 4 As an implementation of the methods shown in the above figures, the present disclosure provides some embodiments of an image classification device. These device embodiments are similar to Figure 2 Corresponding to the method embodiments shown, the device can be specifically applied to various electronic devices.

[0126] like Figure 4As shown, the image classification device 400 of some embodiments includes: an acquisition unit 401 and an execution unit 402. The acquisition unit 401 is configured to acquire an image data set; the execution unit 402 is configured to perform the following steps for each image data in the above image data set: perform image segmentation processing on the above image data to obtain a foreground target image; based on the above foreground target image, generate a corresponding neuron pulse signal sequence; input the above neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the above neuron pulse signal sequence, wherein the above image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is obtained by Figure 1 The steps in the corresponding embodiments are generated; based on the above image label information, the category corresponding to the above foreground target image is determined.

[0127] It is understood that the units described in the device 400 are similar to those described in the reference Figure 2 Therefore, the operations, features and beneficial effects described above for the method are also applicable to the device 400 and the units included therein, and will not be described in detail here.

[0128] Reference below Figure 5 , which shows a structural schematic diagram of an electronic device 500 suitable for implementing some embodiments of the present disclosure. Figure 5 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0129] like Figure 5 As shown, the electronic device 500 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 501, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 502 or a program loaded from a storage device 508 into a random access memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the electronic device 500 are also stored. The processing device 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.

[0130] Typically, the following devices may be connected to the I / O interface 505: an input device 506 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 507 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 508 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 509. The communication device 509 may allow the electronic device 500 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 5 The electronic device 500 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead. Figure 5 Each block shown in the figure may represent one device, or may represent multiple devices as required.

[0131] In particular, according to some embodiments of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, some embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In some such embodiments, the computer program can be downloaded and installed from the network through the communication device 509, or installed from the storage device 508, or installed from the ROM 502. When the computer program is executed by the processing device 501, the above-mentioned functions defined in the method of some embodiments of the present disclosure are executed.

[0132] It should be noted that the computer-readable medium recorded in some embodiments of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In some embodiments of the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In some embodiments of the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0133] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0134] The above-mentioned computer-readable medium may be included in the above-mentioned electronic device; or it may exist independently and not be assembled into the electronic device. The above-mentioned computer-readable medium carries one or more programs. When the above-mentioned one or more programs are executed by the electronic device, the electronic device: receives image data, wherein the above-mentioned image data corresponds to image label information; based on the above-mentioned image data, generates an image pulse signal sequence corresponding to the above-mentioned image data, wherein the above-mentioned image pulse signal sequence corresponds to each time step; determines the above-mentioned image pulse signal sequence as a pulse signal sequence to be input; for each hidden layer in a preset number of hidden layers, performs the following steps: based on each time step corresponding to the pulse signal sequence to be input, determines a time window sequence; for each time window in the above-mentioned time window sequence, performs the following steps: based on the above-mentioned time window and the pulse signal sequence to be input, generates a weighted pulse signal sequence corresponding to the above-mentioned time window; for each initial neuron in each initial neuron, the above-mentioned weighted pulse signal sequence is determined as a pulse signal sequence to be input; The impulse signal sequence is input into the above-mentioned initial neurons to obtain corresponding activated neurons, wherein each of the above-mentioned initial neurons corresponds to an initial membrane potential, and the above-mentioned activated neurons correspond to an activated membrane potential; for each of the obtained activated neurons, based on the above-mentioned activated neurons, at least one neuron impulse signal is generated, and the initial neurons and initial membrane potentials corresponding to the above-mentioned activated neurons are updated; based on the generated neuron impulse signals, a neuron impulse signal sequence is generated; the above-mentioned neuron impulse signal sequence is determined as a pulse signal sequence to be input, so as to update the input pulse signal sequence; the hidden layer that meets the preset processing conditions among the above-mentioned preset number of hidden layers is determined as a hidden layer to be processed; the neuron impulse signal sequence corresponding to the above-mentioned hidden layer to be processed is stored in the output buffer for training the image classification model.

[0135] Or the electronic device: obtains an image data set; for each image data in the above image data set, performs the following steps: performs image segmentation processing on the above image data to obtain a foreground target image; based on the above foreground target image, generates a corresponding neuron pulse signal sequence; inputs the above neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the above neuron pulse signal sequence, wherein the above image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is obtained by Figure 1 The steps in the corresponding embodiments are generated; based on the above image label information, the category corresponding to the above foreground target image is determined.

[0136] Computer program code for performing the operations of some embodiments of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0137] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0138] The units described in some embodiments of the present disclosure may be implemented by software or by hardware. The units described may also be provided in a processor, for example, may be described as: a processor includes a receiving unit, a generating unit, a first determining unit, an executing unit, a second determining unit and a storage unit. The names of these units do not constitute limitations on the units themselves in certain circumstances, for example, the receiving unit may also be described as a "unit for receiving image data".

[0139] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0140] The above descriptions are only some preferred embodiments of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the embodiments of the present disclosure is not limited to the technical solutions formed by a specific combination of the above-mentioned technical features, but should also cover other technical solutions formed by any combination of the above-mentioned technical features or their equivalent features without departing from the above-mentioned inventive concept. For example, the above-mentioned features are replaced with the technical features with similar functions disclosed in the embodiments of the present disclosure (but not limited to) and the technical solutions formed.

Claims

1. A pulse sequence processing method for image classification, include: Receiving image data, wherein the image data corresponds to image tag information; Based on the image data, generating an image pulse signal sequence corresponding to the image data, wherein the image pulse signal sequence corresponds to each time step; Determining the image pulse signal sequence as a pulse signal sequence to be input; For each hidden layer in the preset number of hidden layers, perform the following steps: Determine a time window sequence based on each time step corresponding to the pulse signal sequence to be input; For each time window in the sequence of time windows, perform the following steps: Based on the time window and the pulse signal sequence to be input, generating a weighted pulse signal sequence corresponding to the time window; For each initial neuron among the initial neurons, input the weighted pulse signal sequence into the initial neuron to obtain a corresponding activated neuron, wherein each initial neuron among the initial neurons corresponds to an initial membrane potential, and the activated neuron corresponds to an activated membrane potential; For each activated neuron among the obtained activated neurons, generating at least one neuron pulse signal based on the activated neuron, and updating an initial neuron and an initial membrane potential corresponding to the activated neuron; generating a neuron pulse signal sequence based on the generated individual neuron pulse signals; Determine the neuron pulse signal sequence as a pulse signal sequence to be input, so as to update the pulse signal sequence to be input; Determine a hidden layer that meets a preset processing condition among the preset number of hidden layers as a hidden layer to be processed; The neuron pulse signal sequence corresponding to the hidden layer to be processed is stored in the output buffer for training the image classification model.

2. The method according to claim 1, in, The image data includes pixels, each of the pixels corresponds to a first color channel value, a second color channel value, and a third color channel value, and generating an image pulse signal sequence corresponding to the image data based on the image data includes: For each pixel point included in the image data, the following steps are performed: Determine the product of the first color channel value corresponding to the pixel and the first preset weight value as the first color value; Determine the product of the second color channel value corresponding to the pixel and the second preset weight value as the second color value; Determine the product of the third color channel value corresponding to the pixel point and the third preset weight value as the third color value; Determine the sum of the first color value, the second color value and the third color value as the grayscale value corresponding to the pixel; Based on the grayscale value corresponding to the pixel point, generate a normalized value corresponding to the pixel point; Based on the normalized value, generating a pixel pulse probability corresponding to the pixel point; Based on the pixel pulse probability and a preset pixel time window, generating each pixel pulse signal corresponding to the pixel point, wherein each of the pixel pulse signals corresponds to a timestamp; An image pulse signal sequence is generated based on the generated pixel pulse signals and the time stamp corresponding to each pixel pulse signal in the pixel pulse signals.

3. The method according to claim 1, in, The step of generating a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input includes: Determine each of the to-be-input pulse signals corresponding to the time window in the to-be-input pulse signal sequence as each time pulse signal; Based on the respective time pulse signals, generating a corresponding time pulse signal sequence; Based on the respective time pulse signals, generating the number of time pulses corresponding to the time pulse signal sequence; Based on the number of time pulses, a weighted pulse signal sequence corresponding to the time pulse signal sequence is generated.

4. The method according to claim 1, in, The generating at least one neuron pulse signal based on the activated neuron, and updating the initial neuron and the initial membrane potential corresponding to the activated neuron, comprises: generating an activation membrane potential value corresponding to the activated neuron based on the activation membrane potential corresponding to the activated neuron; Determine the initial neuron corresponding to the activated neuron as the target neuron; determining the initial membrane potential corresponding to the target neuron as the target membrane potential; Based on the target membrane potential, generating a target membrane potential value; determining the sum of the activation membrane potential value and the target membrane potential value as a cumulative membrane potential value; Based on the accumulated membrane potential value, at least one neuron pulse signal is generated, and the initial neuron and the initial membrane potential corresponding to the activated neuron are updated.

5. The method according to claim 4, in, The generating at least one neuron pulse signal based on the accumulated membrane potential value, and updating the initial neuron and the initial membrane potential corresponding to the activated neuron, comprises: In response to determining that the accumulated membrane potential value satisfies a preset threshold condition, performing the following steps: Determining the activated neuron as the corresponding initial neuron to update the initial neuron; Performing data conversion processing on the cumulative membrane potential value to obtain the cumulative membrane potential; Determining the accumulated membrane potential as the initial membrane potential corresponding to the updated initial neuron, so as to update the initial membrane potential; A null value signal is generated as a neuron pulse signal, wherein the neuron pulse signal corresponds to a timestamp.

6. A method for image classification, include: Get image dataset; For each image data in the image data set, the following steps are performed: Performing image segmentation processing on the image data to obtain a foreground target image; Based on the foreground target image, generating a corresponding neuron pulse signal sequence; Inputting the neuron pulse signal sequence into a pre-trained image classification model to obtain image label information corresponding to the neuron pulse signal sequence, wherein the image classification model is trained based on the neuron pulse signal sequence stored in the output buffer, and the neuron pulse signal sequence stored in the output buffer is generated by the method according to any one of claims 1 to 6; Based on the image label information, a category corresponding to the foreground target image is determined.

7. The method according to claim 6, in, The image classification model is trained in the following way: Acquire a sample set from the output buffer, wherein the samples in the sample set include an image, a sample neuron pulse signal sequence corresponding to the image, and sample image label information corresponding to the image; Perform the following training steps based on the sample set: Inputting the sample neuron pulse signal sequences of at least one sample in the sample set into the initial neural network respectively to obtain image label information corresponding to each sample in the at least one sample, wherein the initial neural network includes a feature extraction network and an output layer; Comparing the image label information corresponding to each sample in the at least one sample with the corresponding sample image label information; Determine whether the initial neural network reaches the preset optimization goal according to the comparison result; In response to determining that the initial neural network achieves the optimization goal, determining the initial neural network as an image classification model; In response to determining that the initial neural network does not achieve the optimization goal, the network parameters of the initial neural network are adjusted, and unused samples are used to form a sample set, and the adjusted initial neural network is used as the initial neural network to perform the training step again.

8. A pulse sequence processing device for image classification, include: A receiving unit, configured to receive image data, wherein the image data corresponds to image tag information; A generating unit is configured to generate an image pulse signal sequence corresponding to the image data based on the image data, wherein the image pulse signal sequence corresponds to each time step; A first determining unit is configured to determine the image pulse signal sequence as a pulse signal sequence to be input; The execution unit is configured to perform the following steps for each hidden layer in a preset number of hidden layers: determine a time window sequence based on each time step corresponding to the pulse signal sequence to be input; for each time window in the time window sequence, perform the following steps: generate a weighted pulse signal sequence corresponding to the time window based on the time window and the pulse signal sequence to be input; for each initial neuron in each initial neuron, input the weighted pulse signal sequence into the initial neuron to obtain a corresponding activated neuron, wherein each initial neuron in the initial neurons corresponds to an initial membrane potential, and the activated neuron corresponds to an activated membrane potential; for each activated neuron in the obtained activated neurons, generate at least one neuron pulse signal based on the activated neuron, and update the initial neuron and the initial membrane potential corresponding to the activated neuron; generate a neuron pulse signal sequence based on each generated neuron pulse signal; determine the neuron pulse signal sequence as the pulse signal sequence to be input, so as to update the pulse signal sequence to be input; A second determining unit is configured to determine a hidden layer that meets a preset processing condition among the preset number of hidden layers as a hidden layer to be processed; The storage unit is configured to store the neuron pulse signal sequence corresponding to the hidden layer to be processed into an output buffer for training the image classification model.

9. An electronic device, include: one or more processors; a storage device having one or more programs stored thereon; When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.

10. A computer readable medium having a computer program stored thereon, in, When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.