A pet identification method and system
Patent Information
- Application Number
- CN202610848357.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-12
- Publication Date
- 2026-10-27
AI Technical Summary
本实施例的一种宠物识别方法,包括:获取宠物靠近所述宠物喂食设备时的多模态数据,所述多模态数据至少包括所述宠物的位姿特征和形变鼻纹图像;根据所述位姿特征对所述形变鼻纹图像进行校正,得到具有校正鼻纹特征的正视鼻纹图像;基于所述正视鼻纹图像中的校正鼻纹特征确定对所述宠物的第一目标识别得分,根据所述第一目标识别得分确定是否识别到所述宠物。基于上述方案,该宠物识别方法能够对形变鼻纹图像捕捉的畸变鼻纹特征进行校正,提高视觉模态下对宠物识别的准确性,显著提高宠物识别准确性。
Smart Images

Figure CN122990749A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of pet detection technology, and in particular to a pet identification method and system. Background Technology
[0002] Currently, pet identification mainly relies on implanted chips, wearable RFID tags, or single visual / nose print recognition. However, in practical applications (such as smart feeding), the following technical shortcomings exist: unstable data collection, the pet's head-down movement while eating, hair obscuring the view, or drastic changes in lighting can lead to insufficient completeness of visual modality feature extraction, making it impossible to accurately identify the pet. Summary of the Invention
[0003] In view of this, embodiments of this application provide a pet identification method and system that can effectively solve problems such as low accuracy in pet identification.
[0004] In a first aspect, embodiments of this application provide a pet identification method, including: Acquire multimodal data when a pet approaches the pet feeding device, wherein the multimodal data includes at least the pet's pose features and deformed nose print images; The deformed nasal print image is corrected based on the pose features to obtain a frontal nasal print image with corrected nasal print features. A first target recognition score for the pet is determined based on the corrected nasal print features in the frontal nasal print image, and the pet is then identified based on the first target recognition score.
[0005] In a first possible embodiment of the first aspect, the multimodal data further includes one or more of acoustic and mechanical features, and the method further includes: The acoustic recognition score of the pet is determined based on the pet's voiceprint features in the acoustic features, and the mechanical recognition score of the pet is determined based on the mechanical features. A second target recognition score for the pet is determined based on the first target recognition score, the acoustic recognition score, and the mechanical recognition score. The pet is then identified based on the second target recognition score.
[0006] In a second possible embodiment of the first aspect, prior to acquiring multimodal data on the pet's proximity to the pet feeding device, the method further includes: Monitor the real-time acoustic features of the environment surrounding the pet feeding device, and extract the time-domain and frequency-domain features from the acoustic features; Under the condition that the time domain features match the preset acoustic time domain features of the pet, and the frequency domain features match the preset acoustic frequency domain features of the pet, real-time mechanical features around the pet feeding device are collected, including the movement trajectory of the weight and dynamic pressure center around the pet feeding device. The multimodal data is collected when the weight suddenly changes to the pet's weight range and the movement trajectory of the dynamic pressure center matches the pet's gait trajectory.
[0007] In a third possible embodiment of the first aspect, the pose features include the pet's head tilt angle and the pet's center offset angle relative to the pet feeding device, and the acquisition of multimodal data when the pet is near the pet feeding device includes: Acquire plantar pressure data of the pet, the plantar pressure data including multiple pressure sampling values of the pet's forelegs and multiple pressure sampling values of the pet's hindlegs; The ratio of the combined pressure of each front leg pressure sample value of the pet to the combined pressure of each hind leg pressure sample value of the pet is calculated to obtain the current front and hind leg pressure ratio of the pet. The pet's head tilt angle corresponding to the current front and rear leg pressure ratio is determined based on the mapping table between the front and rear leg pressure ratio and the pet's head tilt angle. The pressure center of the pet is determined based on the pressure sampling values of each of the pet's front paws and the pressure sampling values of each of the pet's hind paws. The lateral offset angle of the pressure center relative to the center of the pet feeding device is calculated to obtain the center offset angle.
[0008] In a fourth possible embodiment of the first aspect, correcting the deformed nasal print image based on the pose features includes: A scaling correction matrix is constructed based on the top-down view of the pet's head to scale and correct the deformed nose print image; Based on the center offset angle, a rotation transformation matrix is constructed to construct a rotation correction matrix for rotating and correcting the deformed nose print image; Calculate the product of the scaling correction matrix and the rotation correction matrix to obtain the correction transformation matrix; After transforming the nasal texture coordinates in the deformed nasal texture image using the correction transformation matrix, the frontal nasal texture image is obtained.
[0009] In a fifth possible embodiment of the first aspect, determining the first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image includes: Calculate the visual similarity between the corrected nose print features and the pet's real nose print features to obtain the first target recognition score; The step of determining the acoustic recognition score of the pet based on the pet's voiceprint features in the acoustic features includes: The irrelevant acoustic features in the acoustic features are filtered out to obtain the filtered acoustic features; Extract the pet's fundamental frequency fluctuation features from the filtered acoustic features, calculate the similarity between the pet's fundamental frequency fluctuation features and the pet's actual fundamental frequency fluctuation features, and obtain the acoustic recognition score.
[0010] In a sixth possible embodiment of the first aspect, the mechanical features include pet weight and pet gait parameters, and determining a mechanical identification score for the pet based on the mechanical features includes: Calculate the similarity between the pet's weight and the pet's actual weight to obtain a first similarity score; Calculate the similarity between the pet's gait parameters and the pet's actual gait parameters to obtain a second similarity score; The first similarity score and the second similarity score are weighted and summed to obtain the mechanical recognition score.
[0011] In a seventh possible embodiment of the first aspect, determining a second target recognition score for the pet based on the first target recognition score, the acoustic recognition score, and the mechanical recognition score includes: The first weight corresponding to the first target recognition score is set according to the current light intensity; The second weight corresponding to the acoustic recognition score is set according to the current ambient noise intensity; Calculate the third weight corresponding to the mechanical recognition score based on the first weight and the second weight; The first target recognition score, the acoustic recognition score, and the mechanical recognition score are weighted, summed, and normalized based on the first weight, the second weight, and the third weight to obtain the second target recognition score.
[0012] In an eighth possible embodiment of the first aspect, determining whether the pet was identified based on the first target recognition score includes: If the first target recognition score is greater than the first preset score, the pet is identified. If the first target recognition score is less than or equal to the second preset score, it is determined that the pet was not recognized. If the first target recognition score is greater than the second preset score and less than or equal to the first preset score, the multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data. The step of determining whether the pet has been identified based on the second target recognition score includes: If the second target recognition score is greater than the first preset score, the pet is identified. If the second target recognition score is less than or equal to the second preset score, it is determined that the pet was not recognized. If the second target recognition score is greater than the second preset score and less than or equal to the first preset score, the multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data.
[0013] Secondly, embodiments of this application provide a pet identification system, including: The data acquisition module is used to acquire multimodal data when a pet approaches the pet feeding device. The multimodal data includes the pet's pose features, deformed nose print images, acoustic features, and mechanical features. An image correction module is used to correct the deformed nasal print image based on the pose features to obtain a frontal nasal print image with corrected nasal print features. The first recognition module is used to determine a first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image; The target recognition module is used to determine whether the pet has been recognized based on the first target recognition score.
[0014] Thirdly, this application provides a pet feeding device, which includes a processor and a memory. The memory stores a computer program, and the processor executes the computer program to implement the above-described pet feeding recognition method.
[0015] The embodiments of this application have the following beneficial effects: This embodiment of a pet recognition method includes: acquiring multimodal data of a pet approaching a pet feeding device, the multimodal data including at least the pet's pose features and a deformed nasal print image; correcting the deformed nasal print image based on the pose features to obtain a frontal nasal print image with corrected nasal print features; determining a first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image; and determining whether the pet has been recognized based on the first target recognition score. Based on the above scheme, this pet recognition method can correct the distorted nasal print features captured by the deformed nasal print image, improving the accuracy of pet recognition in visual modalities and significantly enhancing pet recognition accuracy. Attached Figure Description
[0016] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 This paper illustrates a first flowchart of a pet identification method according to an embodiment of this application. Figure 2 A second flowchart of the pet identification method according to an embodiment of this application is shown; Figure 3 A third flowchart of the pet identification method according to an embodiment of this application is shown; Figure 4 A schematic diagram of the fourth process of the pet identification method according to an embodiment of this application is shown; Figure 5 A schematic diagram of a first structure of the pet recognition system according to an embodiment of this application is shown; Figure 6 A second structural schematic diagram of the pet recognition system according to an embodiment of this application is shown.
[0018] Explanation of key component symbols: 200 - Pet recognition system; 210 - Data acquisition module; 220 - Image correction module; 230 - Nose print recognition module; 240 - Target recognition module; 250 - Acoustic recognition module; 260 - Mechanical recognition module; 270 - Data acquisition and wake-up module. Detailed Implementation
[0019] The technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments.
[0020] The components of the embodiments of this application described and illustrated in the accompanying drawings can be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of this application provided in the drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0021] In the following text, the terms "comprising," "having," and their cognates, which may be used in various embodiments of this application, are intended only to indicate a particular feature, number, step, operation, element, component, or combination thereof, and should not be construed as primarily excluding the presence of one or more other features, numbers, steps, operations, elements, components, or combinations thereof, or adding the possibility of one or more combinations thereof. Furthermore, the terms "first," "second," "third," etc., are used only for distinguishing descriptions and should not be construed as indicating or implying relative importance.
[0022] Unless otherwise specified, all terms used herein (including technical and scientific terms) shall have the same meaning as commonly understood by one of ordinary skill in the art to which the various embodiments of this application pertain. Terms (such as those defined in a generally used dictionary) shall be interpreted as having the same meaning as in the context of the relevant technical field and shall not be interpreted as having an idealized or overly formal meaning, unless clearly defined in the various embodiments of this application.
[0023] The following detailed description of some embodiments of this application is provided in conjunction with the accompanying drawings. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0024] The following examples illustrate the pet identification method.
[0025] Figure 1 A flowchart of a pet identification method according to an embodiment of this application is shown. Exemplarily, the pet identification method includes the following steps: S110, acquire multimodal data when the pet approaches the pet feeding device, the multimodal data including at least the pet's pose features and deformed nose print image.
[0026] As an example, to avoid power consumption caused by long-term continuous collection of multimodal data, we first check whether the pet is near the pet feeding device. Only when it is confirmed that the pet is near the pet feeding device will we start collecting multimodal data.
[0027] In one embodiment, the real-time acoustic features of the environment surrounding the pet feeding device are monitored, and the time-domain features and frequency-domain features of the acoustic features are extracted. Under the condition that the time-domain features match the preset acoustic time-domain features of the pet, and the frequency-domain features match the preset acoustic frequency-domain features of the pet, the real-time mechanical features around the pet feeding device are collected.
[0028] In this embodiment, acoustic features are first used as the logical wake-up source. The time-domain feature describes the signal envelope of the sound amplitude (intensity) changing over time, and the frequency-domain feature describes the non-linguistic formant frequency range of the sound spectrum (pitch / timbre). The mechanical sensor array is triggered only when the time-domain feature and the frequency-domain feature are synchronously matched with preset acoustic time-domain features (such as the 200ms rise-300ms decay envelope unique to a cat begging for food) and preset acoustic frequency-domain features (such as a stable double peak within 1.8–3.2kHz). This avoids false wake-ups caused by environmental noise (such as opening and closing doors, dripping water) or irrelevant animal sounds, significantly reducing system power consumption and false trigger rate.
[0029] In one embodiment, the mechanical characteristics include the weight around the pet feeding device and the movement trajectory of the dynamic pressure center; multimodal data collection begins when the weight abruptly changes to the pet's weight range and the movement trajectory of the dynamic pressure center matches the pet's gait trajectory.
[0030] In this embodiment, a secondary verification is performed by combining weight changes and pressure trajectories. A pressure sensor array monitors sudden changes in total weight around the pet feeding device in real time, quickly eliminating non-target pets. Further analysis of the movement trajectory of the dynamic pressure center reveals patterns such as cats exhibiting a diagonal gait with a quincunx-shaped periodic displacement, and dogs displaying a wavy trajectory with alternating forelimb and hindlimb movements. Multimodal data acquisition is only activated when the weight falls within the pet's weight range and the movement trajectory matches the pet's gait. This effectively eliminates interference from environmental noise (such as appliance operation sounds or non-target moving objects) on pet recognition, significantly reducing the false wake-up rate while lowering device standby power consumption.
[0031] In one embodiment, a microphone array can be used to monitor the sounds around the pet feeding device in real time to obtain acoustic characteristics. To suppress environmental noise, a dual-microphone array can be used to perform beamforming to lock onto the direction of the pet's mouth and nose area, physically suppressing environmental noise from the sides and rear. A pressure sensor array at the bottom of the feeding platform can collect the pet's mechanical characteristics and foot pressure data in real time, and a camera can capture images of the pet's nose print when it approaches the pet feeding device.
[0032] In another embodiment, the average ambient noise level can be set to 12 dB. If the ambient noise intensity exceeds this average ambient noise level for a continuous period of time (e.g., 200 ms) and conforms to the bioacoustic envelope, the acoustic feature is considered a valid input, thus avoiding invalid acoustic feature inputs that reduce recognition efficiency. A pressure consistency threshold can also be set, which is set to a value equal to the pet's actual weight. g is used to quickly exclude weight features of non-target objects (such as heavy objects falling or light small animals) to avoid invalid mechanical feature inputs.
[0033] Exemplary features include the pet's head tilt angle and the pet's center offset angle relative to the pet feeding device. The pet's head tilt angle reflects the degree of head tilt, such as the angle of the pet's head relative to the horizontal plane above its head when it is eating with its head down. The center offset angle characterizes the horizontal turning angle of the body relative to the vertical centerline of the pet feeding device, i.e., the degree of left and right head tilt.
[0034] In one embodiment, such as Figure 2 As shown, calculating the pet's head tilt angle and center offset angle includes the following steps: S111, acquire plantar pressure data of the pet, including multiple pressure samples of the pet's forelegs and multiple pressure samples of the pet's hindlegs.
[0035] S112, calculate the ratio of the combined pressure of the front paw pressure samples of each pet to the combined pressure of the hind paw pressure samples of each pet, and obtain the current front and hind paw pressure ratio of the pet.
[0036] In this embodiment, the pressure sampling value of the pet's front paws is the pressure collected by the pressure sensing array when the pet's forelimbs (below the shoulders) contact the feeding platform, and the pressure sampling value of the pet's hind paws is the pressure generated by the pet's hind limbs (below the hips) on the feeding platform.
[0037] As an example, the formula for calculating the front and rear foot pressure ratio is: ; In the formula, This indicates the pressure sampling value of the pet's front paws. This indicates the pressure sample value of the pet's hind legs. This indicates the pressure ratio between the front and rear feet.
[0038] S113, Determine the pet's head tilt angle corresponding to the current pet's front and rear leg pressure ratio based on the mapping table between the front and rear leg pressure ratio and the pet's head tilt angle.
[0039] As an example, when a pet lowers its head to eat, its center of gravity shifts forward, resulting in increased weight distribution on its front legs and decreased weight distribution on its hind legs. This means the pressure on the front legs is greater than the pressure on the hind legs. For instance, a higher pressure ratio indicates a more forward-leaning center of gravity and a larger head-down angle. The mapping table between the front-to-back leg pressure ratio and the pet's head-down angle is a pre-built table that uniquely matches each pet's head-down angle with the front-to-back leg pressure ratio. This table is used to convert the front-to-back leg pressure ratio into the pet's head-down angle in real time with low latency.
[0040] S114. Based on the pressure sampling values of each pet's front paws and hind paws, determine the pet's pressure center, calculate the lateral offset angle of the pressure center relative to the center of the pet feeding device, and obtain the center offset angle.
[0041] Exemplary, the pressure center is the point of application of the equivalent resultant force of all vertical pressure distributions on the contact surface between the pet's four paws and the feeding platform. This pressure center can be determined by identifying the point of application of the resultant force for each pressure sample value. The center offset angle can be obtained by determining the horizontal azimuth angle of the pressure center relative to the origin of the feeding device's coordinate system (the geometric center of the feeding trough).
[0042] S120, the deformed nasal print image is corrected according to the pose characteristics to obtain a frontal nasal print image with corrected nasal print characteristics.
[0043] As an example, when a pet lowers its head to eat or shifts its head from side to side, it can cause distorted nose print images, leading to inaccurate nose print feature recognition based on these images, and consequently, inaccurate pet identification. Therefore, these distorted nose print images can be corrected to obtain frontal nose print images, improving the accuracy of pet identification based on nose print features.
[0044] In one embodiment, firstly, a correction transformation matrix for correcting the deformed nose print image is calculated; secondly, a scaling correction matrix for scaling the deformed nose print image is constructed based on the top-down view of the pet's head; and thirdly, a rotation correction matrix for rotating the deformed nose print image is constructed based on the center offset angle. Finally, the product of the scaling correction matrix and the rotation correction matrix is calculated to obtain the correction transformation matrix.
[0045] In this embodiment, the scaling correction matrix is used to compensate for the vertical compression / stretching of the image caused by the pet tilting its head down. Let the pet's head tilt angle be... Then the scaling correction matrix can be expressed as: ; In the formula, This represents the scaling correction matrix.
[0046] The rotation correction matrix is used to counteract the image rotation caused by left and right offsets. Let the center offset angle be... Then the rotation correction matrix can be expressed as: ; In the formula, The scaling correction matrix is represented by the rotation correction matrix. By multiplying the scaling correction matrix and the scaling correction matrix, the correction transformation matrix is obtained. The correction transformation matrix is a 3×3 affine transformation matrix, which is used to perform joint geometric correction on distorted nasal print images.
[0047] In one embodiment, the nasal vein coordinates in the deformed nasal vein image are transformed using a correction transformation matrix to obtain a frontal nasal vein image. Exemplarily, let the correction transformation matrix obtained by multiplying the scaling correction matrix and the rotation correction matrix be... The formula for transforming the nasal texture coordinates in the deformed nasal texture image is: ; In the formula, This represents the coordinates of the nasal print in a distorted nasal print image directly captured by a camera, which contains original perspective distortion (such as longitudinal compression caused by tilting the head down while eating). This represents the transformed nasal vein coordinates. All the transformed nasal vein coordinates constitute the frontal nasal vein image.
[0048] In this embodiment, by acquiring plantar pressure data in real time, the anatomically significant downward head angle of the pet while eating, as well as the center offset angle relative to the pet feeding device, are inversely affinely transformed to correct the distorted nasal print image captured by the visual module. This solves the problem of severe distortion of nasal print features caused by the pet tilting its head down or turning its head during eating, thus improving the accuracy of pet visual recognition.
[0049] S130, determine the first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image, and determine whether the pet has been recognized based on the first target recognition score.
[0050] Exemplary, the first target recognition score is a quantification of identity recognition confidence in the visual modality, representing the degree of consistency between the corrected nasal print features and the real nasal print features.
[0051] In one embodiment, the visual similarity between the corrected nasal print features and the pet's real nasal print features is calculated to obtain a first target recognition score. In this embodiment, the corrected nasal print features are the coordinates of nasal print detail points in a frontal nasal print image. These coordinates can be compared with the coordinates of nasal print detail points in the real nasal print features to determine the degree of matching between the nasal print details and coordinates, thus obtaining the first target recognition score. Alternatively, the corrected nasal print features and the real nasal print features can be converted into unified semantic embedding vectors through deep network encoding, and the Euclidean distance or cosine similarity between the two semantic embedding vectors can be calculated to obtain the visual similarity, i.e., the first target recognition score.
[0052] In another embodiment, if the first target recognition score is greater than the first preset score, it is determined that a pet has been identified; if the first target recognition score is less than or equal to the second preset score, it is determined that a pet has not been identified; if the first target recognition score is greater than the second preset score and less than or equal to the first preset score, multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data. In this embodiment, a first target recognition score is used as the judgment standard. A first preset score is a set high-confidence threshold, used to directly confirm the pet's identity when the score is higher than the first preset score. A second preset score is set as a low-confidence threshold, used to decisively reject the pet when the score is lower than or equal to the second preset score, preventing accidental opening of the feeding trough. When the first target recognition score is between the first and second preset scores, adaptive re-sampling of multimodal data is triggered to re-identify the pet. This pet identification process is consistent with the pet identification method described above and will not be elaborated here. Exemplarily, to address the problem of insufficient recognition accuracy of single visual / nose print recognition, this application also implements pet recognition in both mechanical and acoustic modal modes, combining the multimodal recognition results to further improve the accuracy of pet recognition.
[0053] In one embodiment, such as Figure 3 As shown, the pet identification method also includes: S140, determine the acoustic recognition score of the pet based on the pet's voiceprint features in the acoustic features, and determine the mechanical recognition score of the pet based on the mechanical features.
[0054] Exemplary examples include one or more of acoustic and mechanical features. Pet voiceprint features are fundamental frequency fluctuation characteristics unique to each pet. For instance, the fundamental frequency fluctuation characteristic of a cat's begging sound typically features a gradually rising question-like glissando, with its fundamental frequency fluctuation exhibiting a specific sinusoidal envelope. Dogs of different sizes have unique fundamental frequency fluctuation frequencies and amplitudes due to variations in vocal cord length. Therefore, pets can be identified using their unique fundamental frequency fluctuation characteristics. Acoustic features include not only pet voiceprint features but also environmental noise; therefore, environmental noise must be filtered out before identifying pets based on their voiceprint features.
[0055] In one embodiment, irrelevant acoustic features are filtered from the acoustic features to obtain filtered acoustic features. In this embodiment, irrelevant acoustic features refer to interference sound signals not emitted by pets, mainly including: ambient noise (air conditioner / refrigerator operation sound), sudden transient noise (thunder, door closing sound), mechanical vibration noise (feeder motor sound), etc. Spectral subtraction can be used to remove persistent irrelevant acoustic features, and a bandpass filter can be used to retain the frequency band corresponding to the fundamental frequency fluctuation feature in the acoustic features, such as the 150Hz~8kHz band. Spectral subtraction is a frequency domain speech enhancement algorithm used to first estimate the power spectrum of the irrelevant acoustic feature, then subtract the power spectrum of the irrelevant acoustic feature from the short-time Fourier transform amplitude spectrum containing the noise acoustic feature, and finally combine it with the original phase to reconstruct the time-frequency signal.
[0056] In another embodiment, the fundamental frequency fluctuation features of the pet are extracted from the filtered acoustic features, and the similarity between the fundamental frequency fluctuation features of the pet and the actual fundamental frequency fluctuation features of the pet is calculated to obtain an acoustic recognition score.
[0057] In this embodiment, the pet's fundamental frequency fluctuation features are compared with the real fundamental frequency fluctuation features to calculate the alignment degree between the pet's fundamental frequency fluctuation features and the real fundamental frequency fluctuation features, thereby obtaining the similarity between the pet's fundamental frequency fluctuation features and the pet's real fundamental frequency fluctuation features. Alternatively, the pet's fundamental frequency fluctuation features and the real fundamental frequency fluctuation features are encoded into embedding vectors and then the cosine similarity is calculated to obtain the similarity, which is the acoustic recognition score.
[0058] In another embodiment, the mechanical characteristics include pet weight and pet gait parameters, which include, but are not limited to, the time difference between the front and hind feet touching the ground on the same side, the smoothness of foot landing / lifting, the spatial dispersion of pressure points on all four feet, and the duration of plantar pressure decay.
[0059] In one embodiment, the similarity between the pet's weight and the pet's actual weight is calculated to obtain a first similarity; the similarity between the pet's gait parameters and the pet's actual gait parameters is calculated to obtain a second similarity; the first similarity and the second similarity are weighted and summed to obtain a mechanical recognition score.
[0060] In this embodiment, firstly, the measured pet weight is compared with the actual weight to calculate the first similarity, such as calculating the Gaussian weighted distance between the two to reflect the consistency of weight; secondly, the gait parameters extracted in real time are compared with the actual gait parameters one by one to calculate the second similarity, such as calculating the proportion of gait parameters that are consistent to obtain the second similarity, which characterizes the gait dynamics matching degree.
[0061] In one embodiment, a first similarity weight is set for the first similarity, and a second similarity weight is set for the second similarity. The product of the first similarity and the first similarity weight is calculated to obtain the first similarity weighted value. The product of the second similarity and the second similarity weight is calculated to obtain the second similarity calculated value. The sum of the first similarity weighted value and the second similarity weighted value is calculated to obtain the mechanical recognition score.
[0062] In this embodiment, the first similarity weight is a confidence adjustment coefficient dynamically assigned to the weight matching item, reflecting the reliability of the current weight signal, while the second similarity weight characterizes the observable quality of the gait parameters. The sum of the first and second similarity weights is one. This similarity weight can be set according to the actual situation and is not limited here.
[0063] As an example, the pet's real nose print features, real weight, and real gait parameters are the actual data collected or input for identifying the target pet. This is to avoid the problem of insufficient identification accuracy caused by the slow shift in the pet's weight and gait parameters as it ages.
[0064] In another implementation, when a pet is successfully identified as pet A multiple times with high confidence (first target recognition score or second target recognition score greater than 0.95), the average weight, gait parameters, and frontal nasal print features of the pet during that feeding process are automatically extracted. Using a moving average filter or incremental learning algorithm, the true nasal print features, true weight, and true gait parameters of pet A in the memory are finely adjusted and updated according to preset weights (such as 5% new data + 95% historical data). This solves the problem of recognition failure caused by weight changes and joint development during the growth period of young pets, and ensures that it can automatically adapt to the growth and development changes of pets.
[0065] S150, based on the first target recognition score, acoustic recognition score and mechanical recognition score, determine the second target recognition score for the pet, and determine whether the pet has been recognized based on the second target recognition score.
[0066] In one embodiment, such as Figure 4 As shown, the formula for calculating the second target recognition score is: S151, set the first weight corresponding to the first target recognition score according to the current light intensity.
[0067] In this embodiment, the quality of the deformed nose print image is related to the light intensity. If the light intensity is below a certain level, the quality of the deformed nose print image is poor, and the pet recognition result based on the deformed nose print image is inaccurate. In this case, the first weight corresponding to the first target recognition score can be reduced. For example, when the light intensity is below 10 lux, the first weight is reduced from 0.7 to 0.2.
[0068] S152, set the second weight corresponding to the acoustic recognition score based on the current ambient noise intensity.
[0069] In this embodiment, the intensity of ambient noise is positively correlated with the quality of the extracted pet voiceprint features. If the ambient background noise increases (such as thunder), the second weight corresponding to the acoustic recognition score is automatically reduced. Exemplarily, the weights of the recognition scores are all related to the quality of each modality (sound, force, and vision) feature. The confidence level of the recognition score can be determined based on the quality of the corresponding feature; the higher the quality, the higher the corresponding confidence level. Furthermore, the weight of each recognition score is determined based on the confidence level and the quality of the corresponding feature. The formula for calculating the weight of the recognition score is as follows: ; In the formula, Indicates the first The weights of the recognition scores for each modality (sound, force, vision) in the current environment. Indicates the first The confidence level of the recognition score extracted from each modality. Indicates the first Quality indicators corresponding to each mode It represents the sum of the products of confidence scores and quality indices for all modalities.
[0070] S153, calculate the third weight corresponding to the mechanical recognition score based on the first weight and the second weight.
[0071] S154. The first target recognition score, acoustic recognition score, and mechanical recognition score are weighted, summed, and normalized based on the first weight, the second weight, and the third weight to obtain the second target recognition score.
[0072] In this embodiment, the sum of the first weight, the second weight, and the third weight is 1. After determining two of these weights, the remaining weights can be determined. The formula for calculating the weighted sum is: ; In the formula, This represents the weighted summation result. Indicates the first weight. This represents the score for identifying the first target. Indicates the second weight. Indicates the acoustic recognition score. Indicates the third weight. This represents the mechanical identification score. The weighted summation result can be mapped to the [0, 1] interval using the Softmax function to obtain the second target identification score.
[0073] In another embodiment, if the second target recognition score is greater than the first preset score, it is determined that a pet has been identified; if the second target recognition score is less than or equal to the second preset score, it is determined that a pet has not been identified; if the second target recognition score is greater than the second preset score and less than or equal to the first preset score, multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data.
[0074] In this embodiment, the second target recognition score is used as the judgment criterion. When the second target recognition score is between the first preset score and the second preset score, adaptive re-sampling of multimodal data is triggered to re-identify the pet. This pet identification process is consistent with the pet identification method described above and will not be elaborated here. This approach balances recognition accuracy with avoiding missed identifications due to momentary interference, significantly improving the user experience.
[0075] For example, the first preset score is set to 0.9, and the second preset score is set to 0.6. If the second target recognition score is greater than 0.9, the pet is confirmed as an authorized individual, and the pet feeder's actuator opens the corresponding feeding trough and records the feeding data. If the second target recognition score is greater than 0.6 but less than or equal to 0.9, it enters a continuous observation state, acquiring multimodal data to re-determine whether a pet has been identified. If the second target recognition score is less than or equal to 0.6, it is determined that no pet has been identified, possibly an illegal or conflicting individual (such as a food snatcher), and the actuator remains in the off state.
[0076] Figure 5 A schematic diagram of a pet identification system 200 according to an embodiment of this application is shown. Exemplarily, the pet identification system 200 includes: The data acquisition module 210 is used to acquire multimodal data when a pet approaches a pet feeding device. The multimodal data includes at least the pet's pose features and deformed nose print images.
[0077] In one embodiment, such as Figure 5 As shown, the pet recognition system 200 also includes: a data acquisition and wake-up module 270, used to monitor the real-time acoustic features of the environment around the pet feeding device, and extract the time-domain features and frequency-domain features from the acoustic features; under the condition that the time-domain features match the pet's preset acoustic time-domain features and the pet's preset acoustic frequency-domain features, the system begins to acquire real-time mechanical features around the pet feeding device, including the weight around the pet feeding device and the movement trajectory of the dynamic pressure center; under the condition that the weight suddenly changes to the pet's weight and the movement trajectory of the dynamic pressure center matches the pet's walking gait features, the system begins to acquire multimodal data.
[0078] In one embodiment, the pose features include the pet's head tilt angle and the pet's center offset angle relative to the pet feeding device. The data acquisition module 210 is also used to acquire the pet's plantar pressure data, which includes multiple pet foreleg pressure sampling values and multiple pet hindleg pressure sampling values. The module calculates the ratio of the combined pressure of each pet foreleg pressure sampling value to the combined pressure of each pet hindleg pressure sampling value to obtain the current pet's foreleg-hindleg pressure ratio. Based on the mapping table between the foreleg-hindleg pressure ratio and the pet's head tilt angle, the module determines the pet's head tilt angle corresponding to the current pet's foreleg-hindleg pressure ratio. Based on each pet's foreleg pressure sampling value and each pet hindleg pressure sampling value, the module determines the pet's pressure center and calculates the lateral offset angle of the pressure center relative to the center of the pet feeding device to obtain the center offset angle.
[0079] The image correction module 220 is used to correct the deformed nasal print image according to the pose features to obtain a frontal nasal print image with corrected nasal print features.
[0080] In one embodiment, the image correction module 220 is further configured to construct a scaling correction matrix for scaling correction of the deformed nose print image based on the top-down view of the pet's head; construct a rotation correction matrix for rotating correction of the deformed nose print image based on the center offset angle; calculate the product of the scaling correction matrix and the rotation correction matrix to obtain the correction transformation matrix; and transform the nose print coordinates in the deformed nose print image through the correction transformation matrix to obtain the frontal nose print image.
[0081] The nose print recognition module 230 is used to determine the first target recognition score for a pet based on the corrected nose print features in the frontal nose print image.
[0082] In one embodiment, the nose print recognition module 230 is further used to calculate the visual similarity between the corrected nose print features and the pet's real nose print features to obtain a first target recognition score.
[0083] The target recognition module 240 is used to determine whether a pet has been recognized based on the first target recognition score.
[0084] In one embodiment, the target recognition module 240 is further configured to set a first weight corresponding to the first target recognition score based on the current light intensity; set a second weight corresponding to the acoustic recognition score based on the current ambient noise intensity; calculate a third weight corresponding to the mechanical recognition score based on the first weight and the second weight; and perform weighted summation and normalization on the first target recognition score, the acoustic recognition score and the mechanical recognition score based on the first weight, the second weight and the third weight to obtain a second target recognition score.
[0085] In one embodiment, the target recognition module 240 is further configured to: determine that a pet has been identified if the second target recognition score is greater than the first preset score; determine that a pet has not been identified if the second target recognition score is less than or equal to the second preset score; and reacquire multimodal data and re-identify the pet based on the reacquired multimodal data if the second target recognition score is greater than the second preset score and less than or equal to the first preset score.
[0086] In one embodiment, such as Figure 6 As shown, the multimodal data also includes one or more of acoustic and mechanical features. The pet recognition system further includes an acoustic recognition module 250 and a mechanical recognition module 260. The acoustic recognition module 250 is used to determine the acoustic recognition score of the pet based on the pet's voiceprint features in the acoustic features, and to determine the mechanical recognition score of the pet based on the mechanical features. The mechanical recognition module 260 is used to determine the second target recognition score of the pet based on the first target recognition score, the acoustic recognition score, and the mechanical recognition score.
[0087] In one embodiment, the target recognition module 240 is further configured to determine whether a pet has been recognized based on a second target recognition score. If the first target recognition score is greater than a first preset score, the pet is determined to have been recognized; if the first target recognition score is less than or equal to the second preset score, the pet is determined not to have been recognized; if the first target recognition score is greater than the second preset score and less than or equal to the first preset score, multimodal data is reacquired, and the pet is re-recognized based on the reacquired multimodal data.
[0088] It is understood that the system in this embodiment corresponds to the pet recognition method in the above embodiment, and the options in the above embodiment are also applicable to this embodiment, so they will not be described again here.
[0089] This application also provides a pet feeding device, exemplary of which includes a processor and a memory, wherein the memory stores a computer program, and the processor, by running the computer program, enables the pet feeding device to perform the functions of the pet identification method or the various modules in the pet identification system described above.
[0090] The processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including at least one of a Central Processing Unit (CPU), Graphics Processing Unit (GPU), Network Processor (NP), Digital Signal Processor (DSP), Application-Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application.
[0091] Memory can be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), and Electrically Erasable Programmable Read-Only Memory (EEPROM). Memory is used to store computer programs, and the processor can execute these programs upon receiving execution instructions.
[0092] This application also provides a computer-readable storage medium for storing the computer program used in the aforementioned pet feeding device. For example, the computer-readable storage medium may include, but is not limited to, various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0093] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code, which contains one or more executable instructions for implementing a specified logical function. It should also be noted that, as an alternative implementation, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.
[0094] In addition, the functional modules or units in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0095] If a function is implemented as a software module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a smartphone, personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application.
[0096] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.
Claims
1. A pet identification method, characterized in that, include: Acquire multimodal data when a pet approaches the pet feeding device, wherein the multimodal data includes at least the pet's pose features and deformed nose print images; The deformed nasal print image is corrected based on the pose features to obtain a frontal nasal print image with corrected nasal print features. A first target recognition score for the pet is determined based on the corrected nasal print features in the frontal nasal print image, and the pet is then identified based on the first target recognition score.
2. The pet identification method according to claim 1, characterized in that, The multimodal data further includes one or more of acoustic and mechanical features, and the method further includes: The acoustic recognition score of the pet is determined based on the pet's voiceprint features in the acoustic features, and the mechanical recognition score of the pet is determined based on the mechanical features. A second target recognition score for the pet is determined based on the first target recognition score, the acoustic recognition score, and the mechanical recognition score. The pet is then identified based on the second target recognition score.
3. The pet identification method according to claim 1, characterized in that, Before acquiring multimodal data on the pet's proximity to the pet feeding device, the method further includes: Monitor the real-time acoustic features of the environment surrounding the pet feeding device, and extract the time-domain and frequency-domain features from the acoustic features; Under the condition that the time domain features match the preset acoustic time domain features of the pet, and the frequency domain features match the preset acoustic frequency domain features of the pet, real-time mechanical features around the pet feeding device are collected, including the movement trajectory of the weight and dynamic pressure center around the pet feeding device. The multimodal data is collected when the weight suddenly changes to the pet's weight range and the movement trajectory of the dynamic pressure center matches the pet's gait trajectory.
4. The pet identification method according to claim 1, characterized in that, The pose features include the pet's head tilt angle and the pet's center offset angle relative to the pet feeding device. Acquiring multimodal data when the pet is near the pet feeding device includes: Acquire plantar pressure data of the pet, the plantar pressure data including multiple pressure sampling values of the pet's forelegs and multiple pressure sampling values of the pet's hindlegs; The ratio of the combined pressure of each front leg pressure sample value of the pet to the combined pressure of each hind leg pressure sample value of the pet is calculated to obtain the current front and hind leg pressure ratio of the pet. The pet's head tilt angle corresponding to the current front and rear leg pressure ratio is determined based on the mapping table between the front and rear leg pressure ratio and the pet's head tilt angle. The pressure center of the pet is determined based on the pressure sampling values of each of the pet's front paws and the pressure sampling values of each of the pet's hind paws. The lateral offset angle of the pressure center relative to the center of the pet feeding device is calculated to obtain the center offset angle.
5. The pet identification method according to claim 3, characterized in that, The step of correcting the deformed nasal texture image based on the pose features includes: A scaling correction matrix is constructed based on the top-down view of the pet's head to scale and correct the deformed nose print image; Based on the center offset angle, a rotation transformation matrix is constructed to construct a rotation correction matrix for rotating and correcting the deformed nose print image; Calculate the product of the scaling correction matrix and the rotation correction matrix to obtain the correction transformation matrix; After transforming the nasal texture coordinates in the deformed nasal texture image using the correction transformation matrix, the frontal nasal texture image is obtained.
6. The pet identification method according to claim 2, characterized in that, The step of determining the first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image includes: Calculate the visual similarity between the corrected nose print features and the pet's real nose print features to obtain the first target recognition score; The step of determining the acoustic recognition score of the pet based on the pet's voiceprint features in the acoustic features includes: The irrelevant acoustic features in the acoustic features are filtered out to obtain the filtered acoustic features; Extract the pet's fundamental frequency fluctuation features from the filtered acoustic features, calculate the similarity between the pet's fundamental frequency fluctuation features and the pet's actual fundamental frequency fluctuation features, and obtain the acoustic recognition score.
7. The pet identification method according to claim 2, characterized in that, The mechanical features include pet weight and pet gait parameters. Determining a mechanical recognition score for the pet based on these mechanical features includes: Calculate the similarity between the pet's weight and the pet's actual weight to obtain a first similarity score; Calculate the similarity between the pet's gait parameters and the pet's actual gait parameters to obtain a second similarity score; The first similarity score and the second similarity score are weighted and summed to obtain the mechanical recognition score.
8. The pet identification method according to claim 2, characterized in that, The step of determining a second target recognition score for the pet based on the first target recognition score, the acoustic recognition score, and the mechanical recognition score includes: The first weight corresponding to the first target recognition score is set according to the current light intensity; The second weight corresponding to the acoustic recognition score is set according to the current ambient noise intensity; Calculate the third weight corresponding to the mechanical recognition score based on the first weight and the second weight; The first target recognition score, the acoustic recognition score, and the mechanical recognition score are weighted, summed, and normalized based on the first weight, the second weight, and the third weight to obtain the second target recognition score.
9. The pet identification method according to claim 2, characterized in that, The step of determining whether the pet has been identified based on the first target recognition score includes: If the first target recognition score is greater than the first preset score, the pet is identified. If the first target recognition score is less than or equal to the second preset score, it is determined that the pet was not recognized. If the first target recognition score is greater than the second preset score and less than or equal to the first preset score, the multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data. The step of determining whether the pet has been identified based on the second target recognition score includes: If the second target recognition score is greater than the first preset score, the pet is identified. If the second target recognition score is less than or equal to the second preset score, it is determined that the pet was not recognized. If the second target recognition score is greater than the second preset score and less than or equal to the first preset score, the multimodal data is reacquired, and the pet is re-identified based on the reacquired multimodal data.
10. A pet identification system, characterized in that, include: The data acquisition module is used to acquire multimodal data when a pet approaches the pet feeding device. The multimodal data includes the pet's pose features, deformed nose print images, acoustic features, and mechanical features. An image correction module is used to correct the deformed nasal print image based on the pose features to obtain a frontal nasal print image with corrected nasal print features. The first recognition module is used to determine a first target recognition score for the pet based on the corrected nasal print features in the frontal nasal print image; The target recognition module is used to determine whether the pet has been recognized based on the first target recognition score.