Person Recognition Method, Device, Electronic Device and Storage Medium Based on Complex Number Field
By adopting a personnel recognition method based on the complex domain in human image recognition, global and local feature vectors are processed and fused feature vectors are calculated, and the low retrieval accuracy problem caused by ignoring feature connections in the prior art is solved, and more efficient and accurate human image recognition is achieved.
Patent Information
- Application Number
- CN202410660773.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-27
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2044-05-27
AI Technical Summary
The prior art ignores the intrinsic connection between local image features and the intrinsic connection between local features and global features in human body image recognition, resulting in low retrieval accuracy.
Using a personnel recognition method based on complex domains, the global eigenvector and local eigenvector are obtained, and input them into the vector complex domain transformation model, output the real-part matrix and imaginary matrix, calculate the fused eigenvector, and perform vector search to achieve recognition.
Effectively capture the complex relationships and subtle changes between local features in the image and between local features and global features, deeply explore the implicit relationships in the data, enhance feature expression capabilities, and improve recognition accuracy and stability.
Smart Images

Figure CN118587737B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of image recognition processing, and in particular, to a person recognition method, device, electronic device, and storage medium based on the complex domain. Background Art
[0002] In current security inspection and capture systems, the human body capture technology has attracted increasing attention due to its image search function. In general application scenarios, the local image features and global image features of human body capture are independently modeled and retrieved respectively. However, in some scenarios, it is necessary to fuse these two retrieval methods. A common fusion method is to perform weighted averaging on multiple similarities obtained by local feature retrieval and the similarity of global retrieval. However, this method ignores the internal relationship between local image features and the internal relationship between local features and global features, resulting in low retrieval accuracy. Summary of the Invention
[0003] Embodiments of this application provide a person recognition method, device, electronic device, and storage medium based on the complex domain to solve the problem of low retrieval accuracy caused by ignoring the internal relationship between local image features and the internal relationship between local features and global features.
[0004] In a first aspect, embodiments of this application provide a person recognition method based on the complex domain, which is characterized by including:
[0005] Obtain a global feature vector and multiple local feature vectors determined based on a human body image; where the length of each local feature vector and the global feature vector is the same;
[0006] Input the global feature vector and each local feature vector into a vector complex domain transformation model, and output a real part matrix and an imaginary part matrix;
[0007] Calculate a fusion feature vector according to the real part matrix and the imaginary part matrix;
[0008] Perform vector retrieval according to the fusion feature vector to complete the recognition of the person corresponding to the human body image.
[0009] In a possible implementation manner, the vector complex domain transformation model includes: an input layer, a complex domain transformation layer, a fully connected network layer, and a complex domain inverse transformation layer;
[0010] The input layer is used to merge the global feature vector and each local feature vector to obtain a merged vector;
[0011] The complex domain transformation layer is used to transform the merged vector into the complex domain to obtain a modulus matrix and an angle matrix;
[0012] The fully connected network layer is used to calculate the modulus matrix and the angle matrix respectively to obtain the linearly transformed angle matrix and the exponential part of the modulus matrix;
[0013] The complex domain inverse transformation layer is used to transform the linearly transformed modulus matrix and angle matrix back to the real part matrix and the imaginary part matrix;
[0014] Among them, the complex domain transformation layer and the complex domain inverse transformation layer perform the conversion between vectors and the complex domain based on Euler's formula.
[0015] In a possible implementation, when the input layer combines the global feature vector and each local feature vector, it is based on the following formula:
[0016]
[0017]
[0018] Among them, is the dot product of vectors; is the global feature vector; is k local feature vectors; n is the vector fusion order; is the combined output vector; is the l column combined vector; is a parameter matrix with a dimension of ; is the j row and the l column parameter; .
[0019] In a possible implementation, when the complex domain transformation layer transforms the combined vector into the complex domain, it is based on the following formula:
[0020]
[0021] Among them, ; ; is the real part; is the imaginary part; is the modulus vector; ; is the angle vector; ; Among them, , and are all d dimensional vectors; is k dimensional vector learnable parameters; is the j th parameter;
[0022] Then the combined vector is transformed into:
[0023]
[0024]
[0025]
[0026] where is matrix multiplication; is the l th column of the combined vector; is the modulus vector; is the j th row and l th column of the parameter; ; is the angle vector; ; is the complex modulus; is the complex argument.
[0027] In a possible implementation, when the complex domain inverse transformation layer transforms the linearly transformed modulus matrix and angle matrix back to the real part matrix and imaginary part matrix, it is based on the following formula:
[0028]
[0029] where is the l th column of the combined vector; both the real part matrix and the imaginary part matrix are matrices with a dimension of n×d ; the real part is ; the imaginary part is ; ; is the complex modulus; is the complex argument.
[0030] In a possible implementation, the vector complex domain transformation model further includes: a normalization layer for normalizing the real part matrix and the imaginary part matrix output by the complex domain inverse transformation layer.
[0031] In a possible implementation, calculating the fusion feature vector based on the real part matrix and the imaginary part matrix includes:
[0032] Calculating the fusion feature vector based on the normalization results of the real part matrix and the imaginary part matrix according to the following formula:
[0033]
[0034] Among them, is the fused feature vector; n is the order of vector fusion; is the real part of; is the imaginary part of; is the merged vector of the l th column; .
[0035] In a possible implementation, it further includes:
[0036] Construct original training data according to the global feature vectors and multiple local feature vectors of multiple human body pictures;
[0037] Label the original training data according to the service, and calibrate the similarity of pairwise combinations of feature vectors in the original training data according to the labeling results to generate training data;
[0038] Train the fused feature vector algorithm according to the training data;
[0039] Among them, the pairwise combination of the feature vectors includes: taking the global feature vector corresponding to the human body picture and multiple local feature vectors as a group, and pairwise combining the feature vector groups corresponding to different human body pictures.
[0040] In a second aspect, an embodiment of the present application provides a personnel recognition device based on the complex number domain, including:
[0041] An acquisition module, configured to acquire a global feature vector and multiple local feature vectors determined based on a human body image; wherein, the lengths of each local feature vector and the global feature vector are the same;
[0042] A complex number domain transformation module, configured to input the global feature vector and each local feature vector into a vector complex number domain transformation model, and output a real part matrix and an imaginary part matrix;
[0043] A calculation module, configured to calculate a fused feature vector according to the real part matrix and the imaginary part matrix;
[0044] An identification module, configured to perform vector retrieval according to the fused feature vector to complete the identification of the personnel corresponding to the human body image.
[0045] In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the method in the first aspect or any possible implementation manner of the first aspect above.
[0046] Fourthly, an embodiment of the present application provides a computer-readable storage medium storing a computer program, and when the computer program is executed by a processor, the steps of the method in the first aspect or any possible implementation manner of the first aspect are implemented.
[0047] An embodiment of the present application provides a person recognition method, device, electronic device and storage medium based on the complex domain. By obtaining a global feature vector and multiple local feature vectors based on a human body image, the length of each local feature vector is the same as that of the global feature vector. These vectors are input into a vector complex domain transformation model to output a real part matrix and an imaginary part matrix. A fused feature vector is calculated through the real part matrix and the imaginary part matrix, and retrieval is performed based on this vector to realize the recognition of the person corresponding to the human body image. The vector complex domain transformation model can effectively capture the complex relationships and subtle changes between local features in the image, between local features and the global feature, deeply excavate the implicit associations in the data, and enhance the feature expression ability. Using the fused feature vector for retrieval can improve the recognition accuracy and stability, and realize more efficient and accurate human body image recognition. Description of the Drawings
[0048] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for use in the embodiments or the description of the prior art. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0049] Figure 1 is a flowchart of the implementation of the person recognition method based on the complex domain provided by an embodiment of the present application;
[0050] Figure 2 is a schematic diagram of the structure of a feature fusion network based on the complex domain provided by an embodiment of the present application;
[0051] Figure 3 is a schematic diagram of the training architecture of the fused feature vector algorithm provided by an embodiment of the present application;
[0052] Figure 4 is a schematic diagram of the structure of the person recognition device based on the complex domain provided by an embodiment of the present application;
[0053] Figure 5 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present application. Detailed Embodiments
[0054] In the following description, specific details such as specific system architectures and technologies are presented for purposes of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, those skilled in the art should understand that the present application can also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to avoid unnecessary details from obscuring the description of the present application.
[0055] In the specification, claims, and above-mentioned drawings of the embodiments of the present application, terms such as "first" and "second" are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances so as to implement the embodiments of the present application described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion.
[0056] Unless otherwise specified, the term "plurality" means two or more. The character " / " indicates that the objects before and after are in an "or" relationship. For example, A / B means: A or B. The term "and / or" is an associative relationship describing an object and indicates that three relationships can exist. For example, A and / or B means: A or B, or, the three relationships of A and B.
[0057] The terms used in the present application are only for describing the embodiments and are not used to limit the claims. As used in the description of the embodiments and claims, unless the context clearly indicates otherwise, the singular forms "a", "an", and "the" are also intended to include the plural forms. Similarly, as used in the present application, the term "and / or" refers to any and all possible combinations including one or more of the associated listed items. Additionally, when used in the present application, the term "comprise" and its variants "comprises" and / or "comprising" etc. mean the presence of the stated features, wholes, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components, and / or groupings of these. Without further limitation, an element defined by the statement "comprising one..." does not exclude the presence of another identical element in the process, method, or device comprising the element.
[0058] In the present application, each embodiment may focus on the differences from other embodiments, and the same or similar parts between the various embodiments may be referred to each other. For the methods, products, etc. disclosed in the embodiments, if they correspond to the method part disclosed in the embodiments, the relevant parts may refer to the description of the method part.
[0059] This solution aims to apply the feature fusion algorithm based on Euler's formula to the human body capture model fusion service, directly use the local image feature vectors and global image feature vectors of the human body constructed by the upstream system, and through training, automatically fuse the local image features and global image features of the human body to generate fused feature vectors. The generated fused feature vectors are used for vector retrieval to improve the accuracy of fused retrieval.
[0060] The solution provided in this embodiment provides strong support for fields such as public safety and social governance, improves the accuracy and real-time performance of personnel recognition to meet the ever-changing application requirements.
[0061] To make the objectives, technical solutions, and advantages of this application clearer, the following will be described through specific embodiments with reference to the accompanying drawings.
[0062] Figure 1 It is the implementation flowchart of the personnel recognition method based on the complex number domain provided by an embodiment of this application. As Figure 1 shown, the method includes the following steps:
[0063] S101, obtain a global feature vector and multiple local feature vectors determined based on a human body image; where the lengths of each local feature vector and the global feature vector are the same.
[0064] The execution subjects of the method provided in the embodiments of this application include, but are not limited to, devices with data processing functions such as servers, processors, and microprocessors. In the actual operation process, the specific implementation method of the execution subject can be selected according to actual needs. This embodiment does not set special restrictions on this, and only needs to have data processing functions. The objectives of the execution subject for personnel recognition include completing security inspection tasks, monitoring specific personnel or categories of personnel, and the camera tracking and capturing of moving targets, etc.
[0065] In a possible implementation manner, before the execution subject performs personnel recognition, directly obtain the vector modeling processing results of the human body images output by the upstream system or external image processing devices, that is, obtain a global feature vector and multiple local feature vectors determined based on the human body images. In the actual application scenario, the execution subject often needs to process a large amount of image data. At this time, by using an external image processing device to share part of the computing tasks and giving full play to its processing capabilities, it helps to reduce the computing burden of the execution subject and enables it to complete the personnel recognition task more efficiently. In addition, in a complex environment, the execution subject can cooperate with other external devices, such as external image processing devices, to achieve more efficient information processing and personnel recognition. By directly obtaining the processing results of the external image processing device, the execution subject can obtain effective information faster, thereby improving its cooperation efficiency with other related devices.
[0066] In a possible implementation, the execution subject establishes a corresponding processing module to perform vector modeling processing operations of human body images to improve the performance of the overall system.
[0067] First, the human body image is semantically segmented, and the segmented local features are modeled separately, such as selecting the left hip, right hip, left shoulder, right shoulder and other local images for vector modeling to generate local feature vectors of the same length. At the same time, the entire human body image is feature modeled to generate a global feature vector. In order to enhance the comparability between the features, the length of the local feature vector and the global feature vector are the same.
[0068] S102, inputting the global eigenvector and each local eigenvector into a vector complex domain transformation model, and outputting a real part matrix and an imaginary part matrix.
[0069] Among them, the vector complex domain transformation model has a strong expressive ability and can effectively capture the complex relationship and subtle changes between local features and between local features and global features in the image. After model processing, the real part matrix and the imaginary part matrix are obtained.
[0070] S103, calculating a fused eigenvector according to the real matrix and the imaginary matrix.
[0071] Compared with the weighted average of the multiple different similarities obtained by independent local feature retrieval and the similarity of global retrieval, step S103 calculates the fused feature vector based on the real matrix and the imaginary matrix. By integrating these two parts of information, it is possible to deeply explore the implicit associations in the data and enhance the feature expression ability. This process usually adopts various fusion strategies, such as weighted summation, multiplication fusion, etc. Therefore, in actual operation, before calculating the fused feature vector of the real matrix and the imaginary matrix, the fused feature vector algorithm needs to be pre-trained to improve the efficiency of feature extraction and fusion.
[0072] S104, performing vector retrieval based on the fused feature vector to complete the identification of the person corresponding to the human image.
[0073] Among them, the recognition of the person corresponding to the human image is performed based on the fused feature vector. The purpose is to use the fused feature vector to improve the accuracy and stability of recognition, so as to achieve more efficient and accurate human image recognition.
[0074] In an embodiment of the present application, by obtaining a global feature vector and multiple local feature vectors based on a human body image, the length of each local feature vector is the same as that of the global feature vector. These vectors are input into a vector complex domain transformation model, and a real part matrix and an imaginary part matrix are output. A fused feature vector is calculated based on the real part matrix and the imaginary part matrix, and retrieval is performed according to this vector to achieve the identification of the person corresponding to the human body image. The vector complex domain transformation model can effectively capture the complex relationships and subtle changes between local features in the image, between local features and global features, deeply excavate the implicit associations in the data, and enhance the feature expression ability. Using the fused feature vector for retrieval can improve the recognition accuracy and stability, and achieve more efficient and accurate human body image recognition.
[0075] In a possible implementation manner, the vector complex domain transformation model includes: an input layer, a complex domain transformation layer, a fully connected network layer, and a complex domain inverse transformation layer;
[0076] The input layer is used to merge the global feature vector and each local feature vector to obtain a merged vector;
[0077] The complex domain transformation layer is used to transform the merged vector into the complex domain to obtain a modulus matrix and an angle matrix;
[0078] The fully connected network layer is used to calculate the modulus matrix and the angle matrix respectively to obtain a linearly transformed angle matrix and an exponential part of the modulus matrix;
[0079] The complex domain inverse transformation layer is used to transform the linearly transformed modulus matrix and angle matrix back into a real part matrix and an imaginary part matrix.
[0080] In a possible implementation manner, the complex domain transformation layer and the complex domain inverse transformation layer perform the conversion between the vector and the complex domain based on Euler's formula. In other possible implementation manners, the global feature vector and each local feature vector can be transformed into the complex domain by other means to deeply analyze the complex relationships and subtle changes between local features, between local features and global features.
[0081] For the convenience of understanding the execution order of each layer, Figure 2 is taken as an example for illustration.
[0082] Figure 2 is a schematic diagram of a feature fusion network structure based on the complex domain provided by an embodiment of the present application. As Figure 2 shown, the overall network structure is as Figure 1 shown. The entire network consists of an input layer, a complex domain transformation layer, a fully connected network layer, a complex domain inverse transformation layer, and a normalization layer.
[0083] Input 1 global feature vector and k local feature vector human body feature vectors, and output a fused feature vector. Among them, the output dimension of the input layer is d×(k + 1).
[0084] The complex domain transformation layer transforms the input vector into the complex space. Among them, after the modulus vector performs a log operation (here, the natural logarithm e is selected as the base), it is input into the fully connected network layer; the angle vector is directly input into the fully connected network layer. The output of the complex domain transformation layer is two matrices with dimensions of d×(k + 1), namely the modulus matrix and the angle matrix respectively.
[0085] The parameters of the fully connected network layer are , and the bias is 0. Calculate the exponential part of the modulus matrix and the angle matrix respectively:
[0086] The modulus matrix (exponential part) passes through the fully connected network layer:
[0087] The angle matrix passes through the fully connected network layer:
[0088] The output of the fully connected network layer is two matrices with dimensions of n×d, namely the exponential part of the modulus matrix after linear transformation and the angle matrix respectively. Before inputting into the complex domain inverse transformation layer, the exponential part of the modulus needs to perform the exponential operation of e.
[0089] The complex domain inverse transformation layer transforms the modulus matrix and the angle matrix output by the fully connected network layer back into the real part matrix and the imaginary part matrix.
[0090] The real part is:
[0091] The imaginary part is:
[0092] The complex domain inverse transformation layer outputs two matrices with dimensions of n×d, representing the transformed real part and imaginary part matrices respectively.
[0093] The normalization layer performs layer normalization on the real part and imaginary part matrices output by the complex domain inverse transformation layer respectively, and this layer does not change the dimensions of the input and output.
[0094] Above, Figure 2 The overall vector complex domain transformation model is introduced. The main execution processes of each layer are described separately below.
[0095] In a possible implementation, when the input layer combines the global feature vector and each local feature vector, it is based on the following formula:
[0096]
[0097]
[0098] Among them, is the dot product of vectors; is the global feature vector; is k a local feature vector; n is the vector fusion order; is the combined output vector; is the l combined vector of the th column; is a parameter matrix of dimension is the j th row and the l th column parameter; .
[0099] In a possible implementation, when the complex domain transformation layer transforms the combined vector into the complex domain, it is based on the following formula:
[0100]
[0101] where, ; ; is the real part; is the imaginary part; is the modulus vector; ; is the angle vector; ; where, , and are all d dimensional vectors; is the k dimensional vector learnable parameter; is the th j parameter of;
[0102] Then the combined vector is converted to:
[0103]
[0104]
[0105]
[0106] where, is matrix multiplication; is the l th column combined vector; is the modulus vector; is the j th row and the l th column parameter; ; is the angle vector; ; is the complex modulus; is the argument of a complex number.
[0107] In a possible implementation, when the complex-domain inverse transformation layer converts the linearly transformed magnitude matrix and angle matrix back to the real-part matrix and the imaginary-part matrix, it is based on the following formula:
[0108]
[0109] where is the combined vector of the l column; both the real-part matrix and the imaginary-part matrix are matrices with a dimension of n×d ; the real part is ; the imaginary part is ; ; is the modulus of a complex number; is the argument of a complex number.
[0110] In a possible implementation, the vector complex-domain transformation model further includes: a normalization layer for normalizing the real-part matrix and the imaginary-part matrix output by the complex-domain inverse transformation layer.
[0111] In a possible implementation, calculating the fused feature vector based on the real-part matrix and the imaginary-part matrix in step S103 includes:
[0112] Calculating the fused feature vector based on the normalization results of the real-part matrix and the imaginary-part matrix according to the following formula:
[0113]
[0114] where is the fused feature vector; n is the vector fusion order; is the real part of; is the imaginary part of; is the combined vector of the l column; .
[0115] In a possible implementation, it further includes:
[0116] Constructing original training data based on the global feature vectors and multiple local feature vectors of multiple human body pictures;
[0117] Labeling the original training data according to the service, and calibrating the similarity of pairwise combinations of feature vectors in the original training data according to the labeling results to generate training data;
[0118] Training the fused feature vector algorithm according to the training data;
[0119] Among them, the pairwise combination of feature vectors includes: taking the global feature vector corresponding to the human body picture and multiple local feature vectors as a group, and pairwise combining the feature vector groups corresponding to different human body pictures.
[0120] Figure 3 It is a schematic diagram of the training architecture of the fusion feature vector algorithm provided by an embodiment of the present application.
[0121] Specifically, each piece of training data needs to consist of two groups of feature vectors and an expected similarity. In the specific implementation process, the similarity metric used is the cosine distance, with a value range of -1 to 1. The similarity is divided into 4 levels (target similarity): completely similar (1.0), generally similar (0.3), generally dissimilar (-0.3), and completely dissimilar (-1.0). From the original training data, pairwise combinations are used for similarity calibration to generate formal training data. For the final training data set, the number of training data corresponding to the 4 levels of similarity should be roughly the same.
[0122] In this embodiment, the fusion feature vector algorithm is trained with the training data, aiming to improve the expression accuracy of the complex relationships and subtle changes between human body local features and between local features and global features by the fusion feature vector, so as to improve the accuracy of personnel retrieval and recognition, which is helpful for fields such as public safety and social governance.
[0123] It should be understood that the magnitudes of the sequence numbers of the steps in the above embodiments do not mean the order of execution. The execution order of each process should be determined according to its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
[0124] The following is the device embodiment of the present application. For the details not described in detail, reference can be made to the corresponding method embodiment above.
[0125] Figure 4 It is a schematic diagram of the structure of a personnel recognition device based on the complex number domain provided by an embodiment of the present application. As Figure 4 shown, for the sake of convenience of description, only the parts related to the embodiments of the present application are shown. As Figure 4 shown, the device includes:
[0126] An acquisition module 401, configured to acquire a global feature vector and multiple local feature vectors determined based on a human body image; among them, the lengths of each local feature vector and the global feature vector are the same;
[0127] A complex number domain transformation module 402, configured to input the global feature vector and each local feature vector into a vector complex number domain transformation model, and output a real part matrix and an imaginary part matrix;
[0128] A calculation module 403, configured to calculate a fused feature vector based on a real part matrix and an imaginary part matrix;
[0129] An identification module 404, configured to perform vector retrieval based on the fused feature vector to complete the identification of the person corresponding to the human body image.
[0130] In a possible implementation manner, it further includes a training module, configured to construct original training data according to the global feature vectors and multiple local feature vectors of multiple human body pictures; label the original training data according to the service, and calibrate the similarity of pairwise combinations of feature vectors in the original training data according to the labeling result to generate training data; and train the fused feature vector algorithm according to the training data;
[0131] Among them, the pairwise combination of the feature vectors includes: taking the global feature vector corresponding to the human body picture and multiple local feature vectors as a group, and making pairwise combinations with the feature vector groups corresponding to different human body pictures.
[0132] In the embodiment of the present application, by obtaining the global feature vector and multiple local feature vectors based on the human body image, the length of each local feature vector is the same as that of the global feature vector. These vectors are input into the vector complex domain transformation model, and a real part matrix and an imaginary part matrix are output. The fused feature vector is calculated based on the real part matrix and the imaginary part matrix, and retrieval is performed according to this vector to realize the identification of the person corresponding to the human body image. The vector complex domain transformation model can effectively capture the complex relationships and subtle changes between local features in the image, between local features and global features, deeply excavate the implicit associations in the data, and enhance the feature expression ability. Using the fused feature vector for retrieval can improve the recognition accuracy and stability, and realize more efficient and accurate human body image recognition.
[0133] Figure 5 It is a schematic structural diagram of an electronic device provided by an embodiment of the present application. As Figure 5 shown, the electronic device 5 in this embodiment includes: a processor 50, a memory 51, and a computer program 52 stored in the memory 51 and executable on the processor 50. When the processor 50 executes the computer program 52, the steps in the above-mentioned various embodiments of the person identification method based on the complex domain are implemented, such as Figure 1 the steps shown. Alternatively, when the processor 50 executes the computer program 52, the functions of each module / unit in the above-mentioned various device embodiments are implemented, such as Figure 4 the functions of the various modules shown.
[0134] Exemplarily, the computer program 52 can be divided into one or more modules / units. One or more modules / units are stored in the memory 51 and executed by the processor 50 to complete this application. One or more modules / units can be a series of computer program instruction segments capable of performing specific functions, and these instruction segments are used to describe the execution process of the computer program 52 in the electronic device 5. For example, the computer program 52 can be divided into Figure 4 each of the modules shown.
[0135] The electronic device 5 can be a computing device such as a desktop computer, a notebook, a palm computer, and a cloud server. The electronic device 5 may include, but is not limited to, a processor 50 and a memory 51. Those skilled in the art can understand that Figure 5 merely examples of the electronic device 5 do not constitute a limitation on the electronic device 5, and it may include more or fewer components than shown in the figure, or combine certain components, or different components. For example, the electronic device may also include input / output devices, network access devices, a bus, etc.
[0136] The so-called processor 50 may be a central processing unit (CPU), or may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0137] The memory 51 may be an internal storage unit of the electronic device 5, such as the hard disk or memory of the electronic device 5. The memory 51 may also be an external storage device of the electronic device 5, such as a plug-in hard disk equipped on the electronic device 5, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. Further, the memory 51 may also include both the internal storage unit and the external storage device of the electronic device 5. The memory 51 is used to store the computer program and other programs and data required by the electronic device. The memory 51 may also be used to temporarily store the data that has been output or will be output.
[0138] Those skilled in the art can clearly understand that, for the convenience and brevity of description, only the above division of each functional unit and module is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiments can be integrated into a processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit. In addition, the specific names of each functional unit and module are only for the convenience of mutual distinction and do not limit the protection scope of this application. The specific working processes of the units and modules in the above system can refer to the corresponding processes in the foregoing method embodiments and will not be elaborated here.
[0139] In the above embodiments, the descriptions of the respective embodiments have their own emphases. For parts not detailed or recorded in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0140] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed in this application can be implemented by electronic hardware, or by a combination of computer software and electronic hardware. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of this application.
[0141] In the embodiments provided in this application, it should be understood that the disclosed device / electronic device and method can be implemented in other ways. For example, the device / electronic device embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there can be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection between each other can be through some interfaces, and the indirect coupling or communication connection of the device or unit can be in an electrical, mechanical or other form.
[0142] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0143] In addition, in each embodiment of the present application, each functional unit can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
[0144] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, to implement all or part of the processes in the above-described embodiment methods of the present application, it can also be completed by a computer program instructing relevant hardware. The computer program can be stored in a computer-readable storage medium. When the computer program is executed by a processor, the steps of the above-described various embodiments of the personnel recognition method based on the complex domain can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in the form of source code, object code, executable file, or some intermediate form, etc. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disc, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc.
[0145] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present application, and should all be included within the protection scope of the present application.
Claims
1. A method for identifying people based on a complex domain, characterized in that: include: Acquire a global feature vector and a plurality of local feature vectors determined based on a human body image; wherein the lengths of the local feature vectors and the global feature vector are the same; Input the global eigenvector and each local eigenvector into a vector complex domain transformation model, and output a real matrix and an imaginary matrix; Calculate a fused eigenvector according to the real matrix and the imaginary matrix; Performing vector retrieval according to the fused feature vector to complete the identification of the person corresponding to the human image; The vector complex domain transformation model includes: an input layer, a complex domain transformation layer, a fully connected network layer and a complex domain inverse transformation layer; The input layer is used to merge the global feature vector and each local feature vector to obtain a merged vector; The complex domain transformation layer is used to transform the combined vector into the complex domain to obtain a modulus matrix and an angle matrix; The fully connected network layer is used to calculate the module value matrix and the angle matrix respectively to obtain the angle matrix and the module value matrix exponential part after linear transformation; The complex domain inverse transformation layer is used to transform the module value matrix and the angle matrix after the linear transformation back into the real part matrix and the imaginary part matrix; The complex domain transformation layer and the complex domain inverse transformation layer perform conversion between vectors and the complex domain based on the Euler formula; When the input layer combines the global feature vector and each local feature vector, it is based on the following formula: Among them, ⊙ is the vector dot product; v0 is the global eigenvector; v1~v k is k local feature vectors; n is the vector fusion order; Δ merge is the merged output vector; is the merged vector of the lth column; α is a parameter matrix with dimension (k+1)×n; α jl is the parameter of the j-th row and the l-th column; 1≤l≤n.
2. The method according to claim 1, characterized in that When the complex domain transform layer transforms the merged vector to the complex domain, it is based on the following formula: Among them, r j =μ j cos(v j );p j =μ j sin(v j );r j is the real part; p j is the imaginary part; j is the modulus value vector; θ j is the angle vector; θ j = atan2(p j ,r j ), where p j , j and θ j are all d-dimensional vectors; μ is a k-dimensional vector learnable parameter; μ j is the jth parameter of μ; Then merge the vector Converts to: Where × is matrix multiplication; is the merged vector of the lth column; j is the modulus vector; α jl is the parameter of the jth row and the lth column; 1≤l≤n; θ j is the angle vector; θ j = atan2(p j ,r j ); is the complex modulus; is the complex angle.
3. The method according to claim 2, characterized in that The complex domain inverse transformation layer converts the linearly transformed modulus matrix and angle matrix back to the real matrix and imaginary matrix based on the following formula: in, is the combined vector of the lth column; the real matrix and the imaginary matrix are both matrices of dimension n×d; the real part is The imaginary part is is the complex modulus; is the complex angle.
4. The method according to claim 1, characterized in that The vector complex domain transformation model also includes: a normalization layer, which is used to normalize the real matrix and the imaginary matrix output by the complex domain inverse transformation layer.
5. The method according to any one of claims 1 to 4, characterized in that The step of calculating the fused feature vector according to the real matrix and the imaginary matrix includes: According to the normalized results of the real matrix and the imaginary matrix, the fused feature vector is calculated based on the following formula: in, is the fusion feature vector; n is the vector fusion order; for The real part of for The imaginary part of is the merged vector of the lth column; 1≤l≤n.
6. A plural domain-based personnel identification device for executing the plural domain-based personnel identification method according to any one of claims 1 to 5, characterized in that: include: An acquisition module, used to acquire a global feature vector and a plurality of local feature vectors determined based on a human body image; wherein the length of each local feature vector is the same as that of the global feature vector; A complex domain transformation module, used for inputting the global eigenvector and each local eigenvector into a vector complex domain transformation model, and outputting a real matrix and an imaginary matrix; A calculation module, used for calculating a fused eigenvector according to the real matrix and the imaginary matrix; The recognition module is used to perform vector retrieval based on the fused feature vector to complete the recognition of the person corresponding to the human image.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and capable of running on the processor, characterized in that: When the processor executes the computer program, the steps of any one of the methods in claims 1 to 5 are implemented.
8. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Maneuvering space target identification method based on plural region graph Transform
CN116994143A