Target detection method, device and storage medium

Through the pre-trained classification network model, multi-layer initial feature maps are generated and cascaded. Combined with the non-maximum suppression algorithm, the robustness of object detection under complex background and dark light conditions is solved, and image object detection is improved accuracy.

CN113221876BActive Publication Date: 2025-01-03BOE TECHNOLOGY GROUP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010069499.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-01-21
Publication Date
2025-01-03
Estimated Expiration
2040-06-19

Smart Images

  • Figure CN113221876B_ABST
    Figure CN113221876B_ABST
Patent Text Reader

Abstract

The present disclosure provides a target detection method, device and storage medium, wherein the target detection method comprises: using a pre-trained classification network model to obtain an image to be detected; generating an n-layer initial feature map of the image to be detected, wherein n is a positive integer not less than 2; amplifying the k+1-th layer feature map in the n-layer initial feature map; cascading the amplified k+1-th layer feature map and the k-th layer feature map to obtain a cascaded n-layer feature map, wherein the value range of k is [1, n-1], and k is a positive integer; generating candidate boxes corresponding to each layer of the feature maps in each layer of the n-layer feature maps obtained after the cascade; screening from the candidate boxes corresponding to each layer of the feature maps to obtain a boundary box of the target to be detected in the image to be detected; and presenting the boundary box in the image to be detected.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of artificial intelligence technology, and in particular to a target detection method, device and storage medium. Background Art

[0002] In the development of intelligent modern life, human-computer interaction plays an important role. A typical human-computer interaction, for example, is to control electronic equipment to perform corresponding operations by detecting a specified target in an image as a trigger condition. At present, objects in images can be detected through artificially designed features, but this method is not very robust. For images acquired under some complex backgrounds and dark lighting conditions, it is difficult to achieve accurate detection results. Summary of the invention

[0003] In view of this, the purpose of the present disclosure is to provide a target detection method, device and storage medium, which can effectively improve the accuracy of target detection in an image.

[0004] Based on the above objectives, the present disclosure provides a target detection method, comprising:

[0005] Use the pre-trained classification network model to obtain the image to be detected;

[0006] Generate an n-layer initial feature map of the image to be detected, where n is a positive integer not less than 2;

[0007] Amplifying the k+1th layer feature map in the n-layer initial feature map;

[0008] Cascading the amplified k+1th layer feature map and the kth layer feature map to obtain a cascaded n-layer feature map, where the value range of k is [1, n-1], and k is a positive integer;

[0009] Generate candidate boxes corresponding to the feature maps of each layer on the feature maps of each layer in the n layers of feature maps obtained after cascading;

[0010] Filtering from the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected;

[0011] The bounding box is presented in the image to be detected.

[0012] Optionally, filtering the candidate boxes corresponding to the feature maps of each layer to obtain a bounding box of the target to be detected in the image to be detected includes:

[0013] The candidate boxes corresponding to the feature maps of each layer are processed by a non-maximum suppression algorithm, and one or more candidate boxes are screened from the candidate boxes to be obtained as the bounding boxes of the target to be detected in the image to be detected.

[0014] Optionally, presenting the bounding box in the image to be detected includes:

[0015] The category confidence of the target to be detected and the bounding box of the target to be detected in the image to be detected are presented in the image to be detected.

[0016] Optionally, enlarging the k+1th layer feature map in the n layers of feature maps includes:

[0017] A deconvolution operation is performed on the feature map of the k+1th layer to obtain a feature map with the same size as the feature map of the kth layer.

[0018] Optionally, the target to be detected includes at least one preset gesture.

[0019] Optionally, the method further comprises:

[0020] Training the classification network model;

[0021] The training of the classification network model comprises:

[0022] Acquiring a sample image containing the target to be detected;

[0023] Identifying the position of the target to be detected in the sample image and identifying the category information of the target to be detected by using an identification frame;

[0024] The marked sample images are used as training samples to train the classification network model to obtain a trained classification network model.

[0025] Optionally, acquiring an image of the target to be detected includes:

[0026] The sample images containing the target to be detected are obtained by taking pictures under different background environments, different light intensities, different shooting distances and different shooting angles.

[0027] Optionally, the classification network model is a single-shot multi-frame detector network model.

[0028] Optionally, candidate boxes corresponding to the feature maps of each layer are generated on the n layers of feature maps obtained after cascading, including:

[0029] The candidate boxes corresponding to the feature maps of each layer and the category probability of each candidate box are generated on the n layers of feature maps obtained after cascading.

[0030] Optionally, the method further comprises:

[0031] After the candidate boxes corresponding to the feature maps of each layer are processed by the non-maximum suppression algorithm and the bounding box of the target to be detected in the image to be detected is obtained by screening, the category probability corresponding to the bounding box is used as the category confidence.

[0032] Optionally, generating n layers of initial feature maps of the image to be detected includes:

[0033] Initial feature maps of different sizes are outputted respectively by the n-layer convolutional layers of the pre-trained classification network model to obtain the n-layer initial feature maps.

[0034] Optionally, among the n layers of initial feature maps, starting from the first layer of initial feature maps, the sizes of the initial feature maps of each layer decrease successively.

[0035] The present disclosure provides a target detection device, comprising:

[0036] An acquisition module is used to acquire the image to be detected using a pre-trained classification network model;

[0037] A first generating module is used to generate an n-layer initial feature map of the image to be detected, where n is a positive integer not less than 2;

[0038] An enlargement module, used for enlarging the k+1th layer feature map in the n layers of initial feature maps;

[0039] A cascade module, used for cascading the feature map of the k+1th layer after the enlargement process and the feature map of the kth layer to obtain a cascaded feature map of the nth layer, wherein the value range of k is [1, n-1], and k is a positive integer;

[0040] The second generation module is used to generate a candidate box corresponding to each layer of the feature map in each layer of the n layers of feature maps obtained after cascading;

[0041] A screening module, used for screening the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected;

[0042] A presentation module is used to present the bounding box in the image to be detected.

[0043] The present disclosure provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the target detection method is implemented when the processor executes the program.

[0044] The present disclosure provides a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the target detection method.

[0045] From the above, it can be seen that according to the target detection method of one or more embodiments of the present specification, by generating n layers of feature maps based on the image to be detected through a classification network model, and cascading the feature maps of adjacent layers, it is possible to achieve the fusion of different high-level features and low-level features, and the feature map fused with high-level features and low-level features is used to generate detection results, which can improve the accuracy of image-based target detection. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0047] Figure 1 is a flow chart of a target detection method according to one or more embodiments of this specification;

[0048] Figure 2 is a schematic diagram of a target detection method according to one or more embodiments of this specification;

[0049] Figure 3 is a schematic diagram showing a detection result in an image according to one or more embodiments of the present specification;

[0050] Figure 4 is a block diagram of an electronic device according to one or more embodiments of the present specification. DETAILED DESCRIPTION

[0051] In order to make the objectives, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.

[0052] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present disclosure should be understood by people with ordinary skills in the field to which the present disclosure belongs. The "first", "second" and similar words used in the present disclosure do not represent any order, quantity or importance, but are only used to distinguish different components. "Including" or "comprising" and similar words mean that the elements or objects appearing in front of the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0053] Figure 1 is a flowchart of a target detection method according to an exemplary embodiment of the present disclosure, which can be performed by a pre-trained classification network model, such as Figure 1 As shown, the method includes:

[0054] Step 101: using a pre-trained classification network model to obtain an image to be detected;

[0055] For example, the preset classification network model is a pre-trained neural network model for detecting the target to be detected in the image. The preset classification network model can be a network model based on SSD (Single Shot multibox Detection) as an example.

[0056] Step 102: Generate n-layer initial feature maps of the image to be detected, where n is a positive integer not less than 2, and n can be set to different values ​​according to the different classification network models adopted. For example, n can be set to 4, 6 or 8, etc.

[0057] Still taking the SSD-based network model as an example, SSD uses VGG-16 as the basic model, and adds an average pool layer and three convolution layers on the basis of VGG-16. The newly added convolution layers can obtain more feature maps for target detection, and convert the two fully connected layers fc6 and fc7 of VGG16 into convolution layers conv6 and conv7 respectively. The Conv4_3 layer in VGG16 will be used as the first feature map for detection. Conv7, Conv8_2, Conv9_2, Conv10_2, and Conv11_2 are extracted from the newly added convolution layers as feature maps for detection. Together with the Conv4_3 layer, a total of 6 (an example of the above n) layers of feature maps are extracted.

[0058] Step 103: enlarging the k+1th layer feature map in the n layers of initial feature maps;

[0059] For example, the feature map of the k+1th layer may be processed and enlarged to be the same size as the feature map of the kth layer.

[0060] Step 104: cascading the feature map of the k+1th layer and the feature map of the kth layer after the amplification process to obtain a cascaded feature map of the nth layer, wherein the value range of k is [1, n-1], and k is a positive integer;

[0061] The classification network model is still used as the SDD-based network model, n = 6, such as Figure 2 As shown, the second-layer feature map of the six-layer feature map is enlarged in sequence to obtain a feature map with the same size as the first-layer feature map, the enlarged second-layer feature map is cascaded with the first-layer feature map, and the cascaded feature map is used as the first-layer feature map of the image to be detected; the third-layer feature map is enlarged to obtain a feature map with the same size as the second-layer feature map, the enlarged third-layer feature map is cascaded with the second-layer feature map, and the cascaded feature map is used as the second-layer feature map of the image to be detected, ... the sixth-layer feature map is enlarged to obtain a feature map with the same size as the fifth-layer feature map, the enlarged sixth-layer feature map is cascaded with the fifth-layer feature map, and the cascaded feature map is used as the fifth-layer feature map of the image to be detected; it should be noted that for the last layer of feature maps, that is, the sixth-layer feature map, since there is no seventh-layer feature map, the sixth-layer feature map is still used as the sixth-layer feature map of the image to be detected. In addition, it should be noted that Figure 2 The feature maps of the first to sixth layers shown in are only examples of feature maps of each layer. In fact, the feature maps of each layer based on the above classification network model are a feature map set including multiple feature maps. Figure 2The prediction result 1 shown in is a feature map set obtained by concatenating the second-layer feature map and the first-layer feature map. The feature map of this size (referring to the size of the first-layer feature map obtained after the concatenation) is obtained through a fully connected layer at each pixel position, with the pixel position as the center. The size of the candidate box, the classification result (wherein the classification result may include background class and target class, and the target class may include gesture categories such as "ok" gesture, scissor hand, thumbs up and heart gesture), and the category confidence can be obtained. Then, the candidate boxes of all sizes are screened out by the NMS algorithm to obtain the detection results. Similarly, prediction results 2 to 5 are also obtained based on the same principle and will not be repeated here. Prediction result 6 is obtained based on the original sixth-layer feature map set in the classification network model.

[0062] It should be noted that the above classification network model can also be implemented based on algorithms such as SNIPER (Scale Normalization for Image Pyramids with Efficient Resampling) or FPN (Feature Pyramid Networks).

[0063] Step 105: generating candidate boxes corresponding to the feature maps of each layer on the feature maps of each layer in the n-layer feature maps obtained after cascading;

[0064] Step 106: Screening the candidate boxes corresponding to the feature maps of each layer to obtain a bounding box of the target to be detected in the image to be detected;

[0065] For step 105 and step 106, still taking the SSD network model as an example, after selecting the above 6 layers of feature maps, candidate boxes of different scales are generated on these feature maps, and finally the candidate boxes of different scales are combined and screened through the non-maximum suppression algorithm to obtain the final set of bounding boxes, that is, the detection result.

[0066] The number of targets to be detected may be one or more.

[0067] Step 107: Present the bounding box in the image to be detected.

[0068] For example, the classification network model performs target detection based on the input image to be detected and outputs a detection result, which includes the output image to be detected. In the output image to be detected, the position of the target to be detected in the image to be detected can be identified by a rectangular box (an example of the above-mentioned bounding box).

[0069] According to the target detection method of one or more embodiments of the present specification, n layers of feature maps are generated based on the image to be detected through a classification network model, and the feature maps of adjacent layers are cascaded, so as to achieve the fusion of different high-level features and low-level features. The feature map fused with high-level features and low-level features is used to generate detection results, which can improve the accuracy of image-based target detection.

[0070] In one or more embodiments of the present specification, filtering the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected may include: processing the candidate boxes corresponding to the feature maps of each layer by a non-maximum suppression algorithm (NMS, NonMaximum Suppression), and filtering to obtain the bounding box of the target to be detected in the image to be detected. For example, a series of candidate boxes B and corresponding scores S are generated in the image to be detected. When the maximum score S is selected max The candidate box M is removed from the set B and put into the final detection result set D. At the same time, any candidate box in the set B whose overlap with the candidate box M is greater than the overlap threshold Nt will also be removed. The resulting set of bounding boxes D is the detection result.

[0071] In one or more embodiments of the present specification, presenting the bounding box in the image to be detected may include: presenting the category confidence of the target to be detected and the bounding box of the target to be detected in the image to be detected. The category confidence is used to represent the probability value that the image content identified by the bounding box is the target to be detected. Figure 3 In the example shown in the figure, after the input image is detected by the above classification network model, Figure 3 From the detection results shown, it can be seen that the detected target is a gesture for indicating "ok", wherein the position of the "ok" gesture in the image is framed in the image by a rectangular bounding box, and the type of the detected gesture is marked as "ok" above the bounding box, and the image content in the bounding box is marked as the type of "OK" gesture with a confidence level of 99%.

[0072] In one or more embodiments of the present specification, enlarging the k+1th layer feature map among the n layers of feature maps may include: performing a deconvolution operation on the k+1th layer feature map to obtain a feature map with the same size as the kth layer feature map.

[0073] In one or more embodiments of the present specification, the target to be detected includes at least one preset gesture. For example, the category of preset gestures may include "ok" gesture, scissors hand, thumbs up, heart gesture and other types of gestures.

[0074] In one or more embodiments of the present specification, the target detection method may further include: training the classification network model, wherein the training of the classification network model may include: collecting sample images containing the target to be detected; for example, collecting sample images of the target to be detected in various scenes by an image collector. The position of the target to be detected and the category information of the target to be detected may be identified in the sample image by an identification frame; for example, the position of the target to be detected may be framed in the image by a rectangular frame. The identified sample image is used as a training sample to train the classification network model to obtain a trained classification network model. For example, the SSD network may be improved first. On the basis that the SSD network has 6 layers of feature images, for each layer of feature images (for example, the k+1th layer image in the above example), the feature image of the previous layer (for example, the kth layer image in the above example) is expanded to the same size as the feature image of the current layer through a deconvolution operation, and then the expanded or cascaded image is cascaded with the current layer image, and the cascaded image is used as the current layer image, which is used together to generate candidate frames of several targets to be detected, and to obtain the coordinates of the candidate frame positions and the category labels.

[0075] Using the above example, we collected images of the above five gestures in different background environments, different lighting conditions, different distances from the camera, and different shooting angles. We marked the position of the gesture in the image with a rectangular frame (an example of the above identification frame) and annotated the category information of the gesture. In this example, the category information is the category of the gesture, such as the OK, scissor hand, thumbs up, heart, and other gestures mentioned above. We then used the annotated images as a training data set, trained the training data set, and obtained a trained classification network model.

[0076] In addition, after collecting images for training (i.e., training data sets), the images can also be enhanced. For example, for the collected images, their brightness, contrast, or folding operations can be randomly changed to increase the complexity of the samples, thereby enhancing the training data. This can make the classification network model trained based on the training data have better generalization.

[0077] In one or more embodiments of the present specification, collecting the image of the target to be detected may include: the sample image containing the target to be detected obtained by shooting in different background environments, different light intensities, different shooting distances, and different shooting angles. Based on this, the features of the same target to be detected in different scenes can be obtained, thereby improving the accuracy of identifying the target to be detected in complex scenes.

[0078] In one or more embodiments of the present specification, generating candidate frames corresponding to each layer of feature maps on the n layers of feature maps obtained after cascading may include: generating candidate frames corresponding to each layer of feature maps and the category probability of each candidate frame on the n layers of feature maps obtained after cascading. For example, for each layer of feature maps of the n layers of feature maps obtained after cascading, the location of the target area (i.e., the positions of multiple candidate frames in each layer of feature maps are determined), and category prediction (i.e., the probability that the object in each candidate frame belongs to the category of the target to be detected) will be performed, wherein the category probability distribution of each candidate frame can be obtained by a softmax logistic regression model.

[0079] In one or more embodiments of the present specification, the target detection method may further include: after processing the candidate boxes corresponding to the feature maps of each layer by a non-maximum suppression algorithm and screening out the bounding box of the target to be detected in the image to be detected, the category probability corresponding to the bounding box is used as the category confidence. Optionally, the final one or more candidate boxes are screened out from the candidate boxes of the feature maps of each layer by a non-maximum suppression algorithm as the bounding box in the detection result. In the aforementioned processing of the method, each candidate box corresponds to a category probability. After the bounding box is determined, the candidate box corresponding to the bounding box is the above-mentioned category confidence.

[0080] In one or more embodiments of the present specification, generating the n-layer initial feature map of the image to be detected may include: outputting initial feature maps of different sizes through the n-layer convolution layers of the pre-trained classification network model to obtain the n-layer initial feature map. In the n-layer initial feature map, starting from the first layer initial feature map, the size of each layer initial feature map decreases in sequence. Figure 2 For example, the feature Figure 1 Feature map 6 is the initial feature map, feature Figure 1 The sizes of feature map 6 decrease successively.

[0081] One or more embodiments of the present specification also provide a target detection device, the device comprising:

[0082] An acquisition module is used to acquire the image to be detected using a pre-trained classification network model;

[0083] A first generating module is used to generate an n-layer initial feature map of the image to be detected, where n is a positive integer not less than 2;

[0084] An enlargement module, used for enlarging the k+1th layer feature map in the n layers of initial feature maps;

[0085] A cascade module, used for cascading the feature map of the k+1th layer after the enlargement process and the feature map of the kth layer to obtain a cascaded feature map of the nth layer, wherein the value range of k is [1, n-1], and k is a positive integer;

[0086] The second generation module is used to generate a candidate box corresponding to each layer of the feature map in each layer of the n layers of feature maps obtained after cascading;

[0087] A screening module, used for screening the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected;

[0088] A presentation module is used to present the bounding box in the image to be detected.

[0089] One or more embodiments of the present specification also provide an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, any one of the target detection methods described above is implemented.

[0090] One or more embodiments of the present specification also provide a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer instructions, wherein the computer instructions are used to enable the computer to execute any one of the above-mentioned target detection methods.

[0091] It should be noted that the method of the embodiment of the present disclosure can be performed by a single device, such as a computer or a server. The method of the present embodiment can also be applied in a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of the embodiment of the present disclosure, and the multiple devices will interact with each other to complete the described method.

[0092] The apparatus of the above-mentioned embodiment is used to implement the corresponding method in the above-mentioned embodiment, and has the beneficial effects of the corresponding method embodiment, which will not be described in detail here.

[0093] Figure 4 A more specific schematic diagram of the hardware structure of an electronic device provided in this embodiment is shown, and the device may include: a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040 are connected to each other through the bus 1050 in the device.

[0094] The processor 1010 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0095] The memory 1020 may be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1020 may store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1020 and are called and executed by the processor 1010.

[0096] The input / output interface 1030 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.

[0097] The communication interface 1040 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).

[0098] The bus 1050 includes a path that transmits information between the various components of the device (eg, the processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040).

[0099] It should be noted that, although the above device only shows the processor 1010, the memory 1020, the input / output interface 1030, the communication interface 1040 and the bus 1050, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.

[0100] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.

[0101] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present disclosure (including the claims) is limited to these examples. Based on the concept of the present disclosure, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the present disclosure as described above, which are not provided in detail for the sake of simplicity.

[0102] In addition, to simplify the description and discussion, and in order not to obscure the present disclosure, known power / ground connections to integrated circuit (IC) chips and other components may or may not be shown in the provided figures. In addition, the devices may be shown in the form of block diagrams to avoid obscuring the present disclosure, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform on which the present disclosure will be implemented (i.e., these details should be fully within the scope of understanding of those skilled in the art). Where specific details (e.g., circuits) are set forth to describe exemplary embodiments of the present disclosure, it will be apparent to those skilled in the art that the present disclosure may be implemented without these specific details or with variations in these specific details. Therefore, these descriptions should be considered illustrative rather than restrictive.

[0103] Although the present disclosure has been described in conjunction with specific embodiments of the present disclosure, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.

[0104] The embodiments of the present disclosure are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present disclosure should be included in the protection scope of the present disclosure.

Claims

1. A target detection method, characterized in that: include: Use the pre-trained classification network model to obtain the image to be detected; Generate an n-layer initial feature map of the image to be detected, where n is a positive integer not less than 2; Amplifying the k+1th layer feature map in the n-layer initial feature map; Cascading the amplified k+1th layer feature map and the kth layer feature map to obtain a cascaded n-layer feature map, where the value range of k is [1, n-1], and k is a positive integer; Generate candidate boxes corresponding to the feature maps of each layer on the feature maps of each layer in the n layers of feature maps obtained after cascading; Filtering from the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected; The bounding box is presented in the image to be detected.

2. The method according to claim 1, characterized in that The bounding box of the target to be detected in the image to be detected is obtained by screening from the candidate boxes corresponding to the feature maps of each layer, including: The candidate boxes corresponding to the feature maps of each layer are processed by a non-maximum suppression algorithm, and one or more candidate boxes are screened from the candidate boxes to be obtained as the bounding boxes of the target to be detected in the image to be detected.

3. The method according to claim 1, characterized in that Presenting the bounding box in the image to be detected includes: The category confidence of the target to be detected and the bounding box of the target to be detected in the image to be detected are presented in the image to be detected.

4. The method according to claim 1, characterized in that: The k+1th layer feature map in the n layers feature map is enlarged, including: A deconvolution operation is performed on the feature map of the k+1th layer to obtain a feature map with the same size as the feature map of the kth layer.

5. The method according to claim 1, characterized in that The target to be detected includes at least one preset gesture.

6. The method according to claim 1, characterized in that The method further comprises: Training the classification network model; The training of the classification network model comprises: Acquiring a sample image containing the target to be detected; Identifying the position of the target to be detected in the sample image and identifying the category information of the target to be detected by using an identification frame; The marked sample images are used as training samples to train the classification network model to obtain a trained classification network model.

7. The method according to claim 6, characterized in that Acquiring an image of the target to be detected includes: The sample images containing the target to be detected are obtained by taking pictures under different background environments, different light intensities, different shooting distances and different shooting angles.

8. The method according to claim 1, characterized in that The classification network model is a single-shot multi-frame detector network model.

9. The method according to claim 2, characterized in that: Generate candidate boxes corresponding to each layer of feature maps on the n layers of feature maps obtained after cascading, including: The candidate boxes corresponding to the feature maps of each layer and the category probability of each candidate box are generated on the n layers of feature maps obtained after cascading.

10. The method according to claim 9, characterized in that The method further comprises: After the candidate boxes corresponding to the feature maps of each layer are processed by the non-maximum suppression algorithm and the bounding box of the target to be detected in the image to be detected is obtained by screening, the category probability corresponding to the bounding box is used as the category confidence.

11. The method according to claim 1, characterized in that: Generating n layers of initial feature maps of the image to be detected, including: Initial feature maps of different sizes are outputted respectively by the n-layer convolutional layers of the pre-trained classification network model to obtain the n-layer initial feature maps.

12. The method according to claim 1, characterized in that Among the n layers of initial feature maps, starting from the first layer of initial feature maps, the sizes of the initial feature maps of each layer decrease in sequence.

13. A target detection device, characterized in that: include: An acquisition module is used to acquire the image to be detected using a pre-trained classification network model; A first generating module is used to generate an n-layer initial feature map of the image to be detected, where n is a positive integer not less than 2; An enlargement module, used for enlarging the k+1th layer feature map in the n layers of initial feature maps; A cascade module, used for cascading the feature map of the k+1th layer after the enlargement process and the feature map of the kth layer to obtain a cascaded feature map of the nth layer, wherein the value range of k is [1, n-1], and k is a positive integer; The second generation module is used to generate a candidate box corresponding to each layer of the feature map in each layer of the n layers of feature maps obtained after cascading; A screening module, used for screening the candidate boxes corresponding to the feature maps of each layer to obtain the bounding box of the target to be detected in the image to be detected; A presentation module is used to present the bounding box in the image to be detected.

14. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the target detection method according to any one of claims 1 to 12 is implemented.

15. A non-transitory computer-readable storage medium, characterized in that: The non-transitory computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the target detection method according to any one of claims 1 to 12.