Waist-hip ratio automatic calculation method based on image analysis

Through image analysis technology, deep learning models and multiple image processing methods are used to solve the subjective error of traditional waist-to-hip ratio measurement methods and the recognition problems in complex scenarios, and automatic and accurate measurement of waist-to-hip ratio is achieved, which is suitable for multiple Health and fitness field.

CN119205677AInactive Publication Date: 2024-12-27WUXI DISCOVERER NETWORK TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411280814.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-13
Publication Date
2024-12-27
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Traditional waist-to-hip ratio measurement methods have problems of large subjective errors, poor repetition and low efficiency. The existing image analysis-based methods are difficult to accurately identify waist and hip positions in different postures and complex scenarios, and cannot provide stable and reliable measurement results.

Method used

Using automatic calculation methods of waist-to-hip ratio based on image analysis, including image acquisition, preprocessing, human area segmentation, key point detection and waist-to-hip ratio calculation, using deep learning models and multiple image processing technologies, through high-resolution camera equipment and Convolutional neural networks identify human contours and key points, and calculate waist and hip circumference.

Benefits of technology

It realizes automatic and accurate measurement of waist-hip ratio, improves the degree of automation and accuracy of measurement, and is suitable for medical, health, fitness and other fields, providing users with reliable health monitoring and body shape assessment tools.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119205677A_ABST
    Figure CN119205677A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of image analysis, in particular to an automatic waist-hip ratio calculation method based on image analysis, which comprises the following steps: acquiring front and side images of a target individual, preprocessing the acquired images, segmenting a human body region, identifying a human body contour, detecting key points of a waist and a hip, and calculating the perimeter of a waist circumference and a hip circumference. And calculating the waist-hip ratio of the target individual. According to the automatic calculation method for the waist-hip ratio based on image analysis, the high-resolution camera shooting equipment, the deep learning model and various image processing technologies are introduced, automatic and accurate measurement of the waist-hip ratio is achieved, and the method has the advantages of being high in automation degree, wide in application range, high in intelligent level and the like; the method is suitable for the fields of medical health, fitness, physical training and the like, provides a reliable health monitoring and body shape evaluation tool for the user, and has remarkable innovativeness and practical value.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image analysis, and in particular to an automatic waist-to-hip ratio calculation method based on image analysis. Background Art

[0002] In the field of medical health and fitness, waist-to-hip ratio (WHR) has been widely used as an important indicator for assessing individual health status and body proportions. The waist-to-hip ratio not only reflects a person's body fat distribution, but also has a significant correlation with chronic diseases such as cardiovascular disease and diabetes. The traditional waist-to-hip ratio measurement method relies on manual measurement of waist and hip circumferences and then calculation.

[0003] However, the inventors have discovered that this technical solution still has at least the following defects:

[0004] First, the traditional waist-to-hip ratio measurement method mainly relies on manual measurement of waist and hip circumferences and then calculation. This method has problems such as large subjective errors, poor repeatability and low efficiency, and it is difficult to meet the needs of modern medical and fitness fields for accurate and fast measurement.

[0005] Second, the existing waist-to-hip ratio calculation methods based on image analysis still face many technical difficulties in practical applications. For example, how to accurately identify the waist and hip positions in different postures and backgrounds, and how to improve the accuracy and stability of the measurement. These methods often lack pertinence and optimization, and cannot provide stable and reliable measurement results in complex practical scenarios. Summary of the invention

[0006] Based on the above purpose, the present invention provides a method for automatically calculating waist-to-hip ratio based on image analysis.

[0007] The method for automatically calculating waist-to-hip ratio based on image analysis comprises the following steps:

[0008] S1, image acquisition: collecting front and side images of the target individual through a camera device;

[0009] S2, image preprocessing: preprocessing the collected images, including image denoising, grayscale conversion and contrast enhancement;

[0010] S3, human body region segmentation: perform human body region segmentation on the preprocessed image and identify the human body contour;

[0011] S4, key point detection: in the segmented human body area, detect the key points of the waist and buttocks, specifically including the upper edge of the waist, the lower edge of the waist, the upper edge of the buttocks and the lower edge of the buttocks;

[0012] S5, waist and hip measurement: according to the detected key point positions, the circumferences of the waist and hip are calculated, the waist circumference is the distance between the upper edge of the waist and the lower edge of the waist, and the hip circumference is the distance between the upper edge of the hip and the lower edge of the hip;

[0013] S6, waist-to-hip ratio calculation: Calculate the waist-to-hip ratio of the target individual.

[0014] Optionally, S1 includes:

[0015] S11, position determination: the target individual stands at a pre-set marked position;

[0016] S12, image acquisition: start the camera device to acquire the front image and the side image of the target individual;

[0017] S13, image quality check: perform a preliminary quality check on the collected front and side images;

[0018] S14, image storage: images that pass the quality inspection are stored in a local storage device or a cloud database.

[0019] Optionally, S2 includes:

[0020] S21, image reading: reading the collected front and side images;

[0021] S22, image denoising: performing denoising on the read image, using a method combining Gaussian filtering and median filtering to remove noise in the image;

[0022] S23, image grayscale: converting the denoised color image into a grayscale image;

[0023] S24, contrast enhancement: performing contrast enhancement processing on the grayscale image, using histogram equalization and adaptive contrast enhancement algorithm to increase the contrast of the image;

[0024] S25, edge detection: edge detection is performed on the contrast-enhanced image, using the Canny edge detection algorithm to highlight the edge information in the image;

[0025] S26, image cropping: cropping the image to remove redundant background parts;

[0026] S27, Image formatting: Convert the preprocessed image to a uniform format and size.

[0027] Optionally, S3 includes:

[0028] S31, model loading: loads a pre-trained deep learning model based on a convolutional neural network;

[0029] S32, image input: input the preprocessed image into the deep learning model;

[0030] S33, feature extraction: use the convolutional layer of the deep learning model to perform multi-level feature extraction on the input image to obtain a high-dimensional feature representation of the image;

[0031] S34, region candidate generation: Generate candidate boxes that may contain human body regions through the model’s region proposal network;

[0032] S35, precise segmentation: input the filtered candidate boxes into the fully convolutional network of the model, accurately segment the image area within each candidate box, and generate a binary segmentation map of the human body area;

[0033] S36, contour extraction: performing contour extraction on the binary segmentation image, and obtaining the human body contour using an edge detection algorithm;

[0034] S37, human body region labeling: labeling the segmented human body region on the original image.

[0035] Optionally, the S36 includes:

[0036] S361, Gaussian filtering: Gaussian filtering is performed on the binary segmentation image to smooth the image and remove noise;

[0037] S362, gradient calculation: use the Sobel operator to calculate the gradient strength and direction of each pixel in the image;

[0038] S363, gradient magnitude and direction calculation: calculating gradient magnitude and direction;

[0039] S364, non-maximum suppression: perform non-maximum suppression on the gradient amplitude, retain the local maximum value, and eliminate non-edge points;

[0040] S365, dual threshold detection: Use dual threshold method to detect the edge of the image, set high threshold and low threshold;

[0041] S366, edge connection: edge connection is performed on the double threshold detection result;

[0042] S367, Contour Extraction: Use the Canny edge detection algorithm to extract the human body contour in the image and generate a complete contour line.

[0043] Optionally, S4 includes:

[0044] S41, model initialization: load the pre-trained key point detection model, which is based on convolutional neural network and regression network;

[0045] S42, image input: inputting the segmented human body region image into the key point detection model;

[0046] S43, feature extraction: using the feature extraction layer of the convolutional neural network, multi-level feature extraction is performed on the input image to generate a high-dimensional feature map;

[0047] S44, heat map generation: The model generates a heat map of each key point, and the heat map represents the probability distribution of each pixel being a key point;

[0048] S45, key point positioning: extract the pixel with the highest probability from the generated heat map as the initial key point position;

[0049] S46, waist key point detection: locate two key points of the upper edge of the waist and the lower edge of the waist;

[0050] S47, hip key point detection: locate the two key points of the upper edge of the hip and the lower edge of the hip;

[0051] S48, position verification: perform position verification on the four detected key points.

[0052] Optionally, the S41 includes:

[0053] S411, data preparation: collect and annotate a training data set containing four key points: upper waist edge, lower waist edge, upper hip edge, and lower hip edge;

[0054] S412, data enhancement: performing data enhancement operations on the training data set, including rotation, scaling, translation, and mirroring;

[0055] S413, model training: use the enhanced data set to train the model, using the cross entropy loss function and the mean square error loss function;

[0056] S414, model loading: loading a pre-trained model from a file at runtime;

[0057] S415, Environment Configuration: Configure the computing environment required to run the model, including loading the deep learning framework.

[0058] Optionally, the S5 includes:

[0059] S51, reading key point coordinates: reading the coordinate positions of the upper edge of the waist, the lower edge of the waist, the upper edge of the hips and the lower edge of the hips from the stored key point data;

[0060] S52, waist circumference calculation: calculating the actual waist circumference according to the vertical distance between the upper edge of the waist and the lower edge of the waist and the actual size ratio of the image;

[0061] S53, hip circumference calculation: calculate the actual hip circumference according to the vertical distance between the upper edge of the hip and the lower edge of the hip and the actual size ratio of the image;

[0062] S54, waist and hip circumference fitting: using human body contour data, performing circular or elliptical fitting on the waist and hips, and calculating the circumference of the waist and hips according to the fitting results;

[0063] S55, result output: the calculated waist circumference and hip circumference results are stored in a local storage device or a cloud database, and output for user viewing and analysis.

[0064] Optionally, S6 includes:

[0065] S61, data reading: reading the calculated waist and hip circumference data from a storage device or a cloud database;

[0066] S62, data verification: verify the read waist and hip circumference data to ensure the integrity and accuracy of the data and exclude abnormal data;

[0067] S63, waist-to-hip ratio calculation: input the verified waist and hip circumference data into a calculation formula to calculate the waist-to-hip ratio, and divide the waist circumference by the hip circumference to obtain the waist-to-hip ratio;

[0068] S65, result storage: storing the calculated waist-to-hip ratio result in a local storage device or a cloud database;

[0069] S66, result output: display the calculation results to the user through a display device, and provide relevant health advice or analysis reports.

[0070] Beneficial effects of the present invention:

[0071] The present invention provides an automatic calculation method of waist-to-hip ratio based on image analysis, which realizes automatic and accurate measurement of waist-to-hip ratio by introducing high-resolution camera equipment, deep learning models and multiple image processing technologies.

[0072] The present invention has the advantages of high degree of automation, wide application range, high level of intelligence, etc. It is suitable for multiple fields such as medical health, fitness, sports training, etc., and provides users with reliable health monitoring and body shape assessment tools, with significant innovation and practical value. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0074] Figure 1 Schematic diagram of a method for automatically calculating waist-to-hip ratio based on image analysis according to an embodiment of the present invention. DETAILED DESCRIPTION

[0075] The present invention is described in detail below in conjunction with the accompanying drawings and specific embodiments. At the same time, it is explained here that in order to make the embodiments more detailed, the following embodiments are the best and preferred embodiments, and those skilled in the art may also adopt other alternatives to implement some known technologies; and the accompanying drawings are only for more specific description of the embodiments, and are not intended to specifically limit the present invention.

[0076] It should be noted that the references to "one embodiment", "an embodiment", "an exemplary embodiment", "some embodiments" and the like in the specification indicate that the embodiments described may include specific features, structures or characteristics, but not every embodiment may include the specific features, structures or characteristics. In addition, when a specific feature, structure or characteristic is described in conjunction with an embodiment, it should be within the knowledge of a person skilled in the art to implement such feature, structure or characteristic in conjunction with other embodiments (whether or not explicitly described).

[0077] In general, a term can be understood, at least in part, from its use in context. For example, depending, at least in part, on the context, the term "one or more" as used herein can be used to describe any feature, structure, or characteristic in the singular sense, or can be used to describe a combination of features, structures, or characteristics in the plural sense. Additionally, the term "based on" can be understood as not necessarily intended to convey an exclusive set of factors, but can instead, depending, at least in part, on the context, allow for the presence of other factors that are not necessarily explicitly described.

[0078] like Figure 1 As shown, the waist-to-hip ratio automatic calculation method based on image analysis includes the following steps:

[0079] S1, image acquisition: collecting front and side images of the target individual through a camera device;

[0080] S2, image preprocessing: preprocessing the collected images, including image denoising, grayscale conversion and contrast enhancement;

[0081] S3, human body region segmentation: perform human body region segmentation on the preprocessed image and identify the human body contour;

[0082] S4, key point detection: in the segmented human body area, detect the key points of the waist and buttocks, specifically including the upper edge of the waist, the lower edge of the waist, the upper edge of the buttocks and the lower edge of the buttocks;

[0083] S5, waist and hip measurement: according to the detected key point positions, the circumferences of the waist and hip are calculated, the waist circumference is the distance between the upper edge of the waist and the lower edge of the waist, and the hip circumference is the distance between the upper edge of the hip and the lower edge of the hip;

[0084] S6, waist-to-hip ratio calculation: Calculate the waist-to-hip ratio of the target individual.

[0085] S1 includes:

[0086] S11, position determination: the target individual stands at a pre-set marked position;

[0087] S12, image acquisition: start the camera device to acquire the front image and the side image of the target individual;

[0088] S13, image quality check: perform a preliminary quality check on the collected front and side images;

[0089] S14, image storage: images that pass the quality inspection are stored in a local storage device or a cloud database.

[0090] S2 includes:

[0091] S21, image reading: reading the collected front and side images;

[0092] S22, image denoising: performing denoising on the read image, using a method combining Gaussian filtering and median filtering to remove noise in the image;

[0093] S23, image grayscale: converting the denoised color image into a grayscale image;

[0094] S24, contrast enhancement: performing contrast enhancement processing on the grayscale image, using histogram equalization and adaptive contrast enhancement algorithm to increase the contrast of the image;

[0095] S25, edge detection: edge detection is performed on the contrast-enhanced image, using the Canny edge detection algorithm to highlight the edge information in the image;

[0096] S26, image cropping: cropping the image to remove redundant background parts;

[0097] S27, Image formatting: Convert the preprocessed image to a uniform format and size.

[0098] S3 includes:

[0099] S31, model loading: loads a pre-trained deep learning model based on a convolutional neural network;

[0100] S32, image input: input the preprocessed image into the deep learning model;

[0101] S33, feature extraction: Use the convolutional layer of the deep learning model to perform multi-level feature extraction on the input image to obtain the high-dimensional feature representation of the image, which is expressed as:

[0102] f l+1 =σ(W l *f l +b l );

[0103] Among them, f l is the input feature map of the lth layer, W l is the convolution kernel, b l is the bias term, σ is the activation function, and * represents the convolution operation;

[0104] S34, region candidate generation: Generate candidate boxes that may contain human regions through the model's region proposal network, expressed as:

[0105]

[0106] Among them, L cls is the classification loss, L reg is the bounding box regression loss, p i is the predicted class probability, is the true category label, t i and are the predicted and true bounding box parameters respectively, and λ is the balancing factor;

[0107] S35, precise segmentation: input the filtered candidate boxes into the fully convolutional network of the model, accurately segment the image area within each candidate box, and generate a binary segmentation map of the human body area;

[0108] S36, contour extraction: performing contour extraction on the binary segmentation image, and obtaining the human body contour using an edge detection algorithm;

[0109] S37, human body region labeling: labeling the segmented human body region on the original image.

[0110] S36 includes:

[0111] S361, Gaussian filtering: Gaussian filtering is performed on the binary segmentation image to smooth the image and remove noise;

[0112] S362, gradient calculation: use the Sobel operator to calculate the gradient strength and direction of each pixel in the image;

[0113] S363, gradient magnitude and direction calculation: calculating gradient magnitude and direction;

[0114] S364, non-maximum suppression: perform non-maximum suppression on the gradient amplitude, retain the local maximum value, and eliminate non-edge points;

[0115] S365, dual threshold detection: Use dual threshold method to detect the edge of the image, set high threshold and low threshold;

[0116] S366, edge connection: edge connection is performed on the double threshold detection result;

[0117] S367, Contour Extraction: Use the Canny edge detection algorithm to extract the human body contour in the image and generate a complete contour line.

[0118] S4 includes:

[0119] S41, model initialization: load the pre-trained key point detection model, which is based on convolutional neural network and regression network;

[0120] S42, image input: inputting the segmented human body region image into the key point detection model;

[0121] S43, feature extraction: using the feature extraction layer of the convolutional neural network, multi-level feature extraction is performed on the input image to generate a high-dimensional feature map;

[0122] S44, heat map generation: The model generates a heat map of each key point, and the heat map represents the probability distribution of each pixel being a key point;

[0123] S45, key point positioning: extract the pixel with the highest probability from the generated heat map as the initial key point position;

[0124] S46, waist key point detection: locate the two key points of the upper edge of the waist and the lower edge of the waist;

[0125] S47, hip key point detection: locate the two key points of the upper edge of the hip and the lower edge of the hip;

[0126] S48, position verification: perform position verification on the four detected key points.

[0127] S41 includes:

[0128] S411, data preparation: collect and annotate a training data set containing four key points: upper waist edge, lower waist edge, upper hip edge, and lower hip edge;

[0129] S412, data enhancement: performing data enhancement operations on the training data set, including rotation, scaling, translation, and mirroring;

[0130] S413, model training: use the enhanced data set to train the model, using the cross entropy loss function and the mean square error loss function;

[0131] S414, model loading: loading a pre-trained model from a file at runtime;

[0132] S415, Environment Configuration: Configure the computing environment required to run the model, including loading the deep learning framework.

[0133] S5 includes:

[0134] S51, reading key point coordinates: reading the coordinate positions of the upper edge of the waist, the lower edge of the waist, the upper edge of the hips and the lower edge of the hips from the stored key point data;

[0135] S52, waist circumference calculation: calculating the actual waist circumference according to the vertical distance between the upper edge of the waist and the lower edge of the waist and the actual size ratio of the image;

[0136] S53, hip circumference calculation: calculate the actual hip circumference according to the vertical distance between the upper edge of the hip and the lower edge of the hip and the actual size ratio of the image;

[0137] S54, waist and hip circumference fitting: using human body contour data, performing circular or elliptical fitting on the waist and hips, and calculating the circumference of the waist and hips according to the fitting results;

[0138] S55, result output: the calculated waist circumference and hip circumference results are stored in a local storage device or a cloud database, and output for user viewing and analysis.

[0139] S6 includes:

[0140] S61, data reading: reading the calculated waist and hip circumference data from a storage device or a cloud database;

[0141] S62, data verification: verify the read waist and hip circumference data to ensure the integrity and accuracy of the data and exclude abnormal data;

[0142] S63, waist-to-hip ratio calculation: input the verified waist and hip circumference data into a calculation formula to calculate the waist-to-hip ratio, and divide the waist circumference by the hip circumference to obtain the waist-to-hip ratio;

[0143] S65, result storage: storing the calculated waist-to-hip ratio result in a local storage device or a cloud database;

[0144] S66, result output: display the calculation results to the user through a display device, and provide relevant health advice or analysis reports.

[0145] The present invention covers any substitution, modification, equivalent method and scheme made on the essence and scope of the present invention. In order to make the public have a thorough understanding of the present invention, specific details are described in detail in the following preferred embodiments of the present invention, but those skilled in the art can fully understand the present invention without the description of these details. In addition, in order to avoid unnecessary confusion about the essence of the present invention, well-known methods, processes, procedures, components and circuits are not described in detail.

[0146] The above are only preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A method for automatically calculating waist-to-hip ratio based on image analysis, characterized in that: The following steps are involved: S1, image acquisition: collecting front and side images of the target individual through a camera device; S2, image preprocessing: preprocessing the collected images, including image denoising, grayscale conversion and contrast enhancement; S3, human body region segmentation: perform human body region segmentation on the preprocessed image and identify the human body contour; S4, key point detection: in the segmented human body area, detect the key points of the waist and buttocks, specifically including the upper edge of the waist, the lower edge of the waist, the upper edge of the buttocks and the lower edge of the buttocks; S5, waist and hip measurement: according to the detected key point positions, the circumferences of the waist and hip are calculated, the waist circumference is the distance between the upper edge of the waist and the lower edge of the waist, and the hip circumference is the distance between the upper edge of the hip and the lower edge of the hip; S6, waist-to-hip ratio calculation: Calculate the waist-to-hip ratio of the target individual.

2. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S1 includes: S11, position determination: the target individual stands at a pre-set marked position; S12, image acquisition: start the camera device to acquire the front image and the side image of the target individual; S13, image quality check: perform a preliminary quality check on the collected front and side images; S14, image storage: images that pass the quality inspection are stored in a local storage device or a cloud database.

3. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S2 includes: S21, image reading: reading the collected front and side images; S22, image denoising: performing denoising on the read image, using a method combining Gaussian filtering and median filtering to remove noise in the image; S23, image grayscale: converting the denoised color image into a grayscale image; S24, contrast enhancement: performing contrast enhancement processing on the grayscale image, using histogram equalization and adaptive contrast enhancement algorithm to increase the contrast of the image; S25, edge detection: edge detection is performed on the contrast-enhanced image, using the Canny edge detection algorithm to highlight the edge information in the image; S26, image cropping: cropping the image to remove redundant background parts; S27, Image formatting: Convert the preprocessed image to a uniform format and size.

4. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S3 includes: S31, model loading: loads a pre-trained deep learning model based on a convolutional neural network; S32, image input: input the preprocessed image into the deep learning model; S33, feature extraction: use the convolutional layer of the deep learning model to perform multi-level feature extraction on the input image to obtain a high-dimensional feature representation of the image; S34, region candidate generation: Generate candidate boxes that may contain human body regions through the model’s region proposal network; S35, precise segmentation: input the filtered candidate boxes into the fully convolutional network of the model, accurately segment the image area within each candidate box, and generate a binary segmentation map of the human body area; S36, contour extraction: performing contour extraction on the binary segmentation image, and obtaining the human body contour using an edge detection algorithm; S37, human body region labeling: labeling the segmented human body region on the original image.

5. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 4, characterized in that: The S36 includes: S361, Gaussian filtering: Gaussian filtering is performed on the binary segmentation image to smooth the image and remove noise; S362, gradient calculation: use the Sobel operator to calculate the gradient strength and direction of each pixel in the image; S363, gradient magnitude and direction calculation: calculating gradient magnitude and direction; S364, non-maximum suppression: perform non-maximum suppression on the gradient amplitude, retain the local maximum value, and eliminate non-edge points; S365, dual threshold detection: Use dual threshold method to detect the edge of the image, set high threshold and low threshold; S366, edge connection: edge connection is performed on the double threshold detection result; S367, Contour Extraction: Use the Canny edge detection algorithm to extract the human body contour in the image and generate a complete contour line.

6. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S4 includes: S41, model initialization: load the pre-trained key point detection model, which is based on convolutional neural network and regression network; S42, image input: inputting the segmented human body region image into the key point detection model; S43, feature extraction: using the feature extraction layer of the convolutional neural network, multi-level feature extraction is performed on the input image to generate a high-dimensional feature map; S44, heat map generation: The model generates a heat map of each key point, and the heat map represents the probability distribution of each pixel being a key point; S45, key point positioning: extract the pixel with the highest probability from the generated heat map as the initial key point position; S46, waist key point detection: locate two key points of the upper edge of the waist and the lower edge of the waist; S47, hip key point detection: locate the two key points of the upper edge of the hip and the lower edge of the hip; S48, position verification: perform position verification on the four detected key points.

7. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 6, characterized in that: The S41 includes: S411, data preparation: collect and annotate a training data set containing four key points: upper waist edge, lower waist edge, upper hip edge, and lower hip edge; S412, data enhancement: performing data enhancement operations on the training data set, including rotation, scaling, translation, and mirroring; S413, model training: use the enhanced data set to train the model, using the cross entropy loss function and the mean square error loss function; S414, model loading: loading a pre-trained model from a file at runtime; S415, Environment Configuration: Configure the computing environment required to run the model, including loading the deep learning framework.

8. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S5 includes: S51, reading key point coordinates: reading the coordinate positions of the upper edge of the waist, the lower edge of the waist, the upper edge of the hips and the lower edge of the hips from the stored key point data; S52, waist circumference calculation: calculating the actual waist circumference according to the vertical distance between the upper edge of the waist and the lower edge of the waist and the actual size ratio of the image; S53, hip circumference calculation: calculate the actual hip circumference according to the vertical distance between the upper edge of the hip and the lower edge of the hip and the actual size ratio of the image; S54, waist and hip circumference fitting: using human body contour data, performing circular or elliptical fitting on the waist and hips, and calculating the circumference of the waist and hips according to the fitting results; S55, result output: the calculated waist circumference and hip circumference results are stored in a local storage device or a cloud database, and output for user viewing and analysis.

9. The method for automatically calculating waist-to-hip ratio based on image analysis according to claim 1, characterized in that: The S6 includes: S61, data reading: reading the calculated waist and hip circumference data from a storage device or a cloud database; S62, data verification: verify the read waist and hip circumference data to ensure the integrity and accuracy of the data and exclude abnormal data; S63, waist-to-hip ratio calculation: input the verified waist and hip circumference data into a calculation formula to calculate the waist-to-hip ratio, and divide the waist circumference by the hip circumference to obtain the waist-to-hip ratio; S65, result storage: storing the calculated waist-to-hip ratio result in a local storage device or a cloud database; S66, result output: display the calculation results to the user through a display device, and provide relevant health advice or analysis reports.