Image processing and measuring system based on edge calculation
By deploying edge computing nodes and image acquisition equipment in the target area and combining them with image processing algorithms, the problem of low efficiency in image style transfer processing in traditional cloud computing is solved, and real-time and efficient image style transfer and feature retention are achieved.
Patent Information
- Application Number
- CN202510822527.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-09-26
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional image style transfer processing methods rely on cloud computing, which leads to limited computing resources and difficulty in balancing the image style transfer effect, thus reducing processing efficiency.
An image processing and measurement system based on edge computing is adopted. By deploying edge computing nodes in the target area and combining them with image acquisition equipment, real-time image acquisition, data transmission and image contrast enhancement are performed. Edge computing nodes are used to measure image features and perform style transfer. Finally, the style transfer effect is evaluated through similarity and difference measurements.
It realizes the real-time acquisition and efficient processing of target object image data, improves image recognition and accuracy, ensures that the image after style transfer is consistent with the original features, and improves processing efficiency and style transfer quality.
Smart Images

Figure CN120707525A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of migration measurement technology, and in particular to an image processing measurement system based on edge computing. Background Art
[0002] Image style transfer technology uses deep learning methods to apply the style of one image to the content of another, thereby generating an image with a specific artistic style. This technology has been widely used in various fields such as artistic creation, image enhancement, and image restoration, and is gaining increasing popularity in industries such as multimedia entertainment, advertising design, and game development. Edge computing, as a computing architecture that pushes computing, storage, and network services to the edge of the network, closer to the data source, can effectively address the latency issues of traditional cloud computing architectures. By deploying image style transfer processing tasks on edge devices, data upload and transmission delays can be significantly reduced, ensuring real-time performance and fast response. However, traditional image style transfer processing methods typically rely on cloud computing or centralized servers for computation. While they perform well in converting the artistic style of static images, style transfer tasks not only require coping with limited computing resources but also require overcoming the balance between image style transfer effects, which reduces the processing efficiency of image style transfer. Summary of the Invention
[0003] Based on this, it is necessary for the present invention to provide an image processing measurement system based on edge computing to solve at least one of the above technical problems.
[0004] To achieve the above objectives, an image processing measurement system based on edge computing includes the following modules:
[0005] The target image real-time acquisition module is used to arrange edge computing nodes next to the image acquisition device corresponding to the target area, and use the image acquisition device to perform real-time image acquisition of the target object corresponding to the target area by setting corresponding image acquisition parameters to obtain the target object image data and transmit it to the edge computing node;
[0006] A target object feature measurement module is used to generate target object comparison standard image data by performing image contrast enhancement on the target object image data on the edge computing node; perform target object feature measurement on the target object comparison standard image data to obtain the corresponding target object image measurement features before style transfer;
[0007] The similarity measurement module before and after the migration is used to obtain the target object reference image data corresponding to the target area, and perform image style migration on the target object compared with the standard image data based on the target object reference image data to obtain the target object image data after migration; based on the measured features of the target object image before the style migration, the similarity measurement before and after the style migration of the target object image after migration is performed to obtain the feature similarity before and after the style migration of the target object image;
[0008] The module for measuring the difference between the style before and after migration is used to measure the style difference between the target object and the standard image data and the image data after migration of the target object based on the feature similarity before and after the style migration corresponding to the target object image, so as to obtain the difference between the style before and after migration corresponding to the target object image.
[0009] Furthermore, the target image real-time acquisition module includes the following functions:
[0010] By arranging corresponding edge computing nodes next to the image acquisition devices corresponding to the target area;
[0011] Obtaining a corresponding target measurement object and target measurement requirements through a target object in a target area, and appropriately setting acquisition parameters of an image acquisition device based on the target measurement object and target measurement requirements to generate corresponding image acquisition parameters, including resolution, frame rate, and exposure time;
[0012] Based on the image acquisition parameters, the image acquisition device is started to perform real-time image acquisition of the target object corresponding to the target area to obtain image data of the target object;
[0013] The target object image data is transmitted to the edge computing node via wireless transmission.
[0014] Furthermore, the target object feature measurement module includes the following functions:
[0015] By gray-scaling the target object image data on the edge computing node, gray-scale image data of the target object is obtained;
[0016] Calculating pixel fuzziness of the grayscale image data of the target object to obtain pixel fuzziness of the target object image;
[0017] Performing fuzzy noise filtering on the target object image data based on the pixel fuzziness of the target object image to obtain fuzzy denoised image data of the target object;
[0018] Performing histogram equalization enhancement on the blurred denoised image data of the target object to generate target object contrast standard image data;
[0019] The target object is compared with the standard image data to measure the target object features and obtain the corresponding target object image measurement features before style transfer, including the image measurement features corresponding to the target image color, texture and structural dimensions.
[0020] Furthermore, measuring the characteristics of the target object by comparing the target object with the standard image data includes:
[0021] Performing multi-channel separation on the target object image corresponding to the target object comparison standard image data to obtain a multi-channel image of the target object;
[0022] Based on the multi-channel image of the target object and combined with the principles of physical optics, the color features of the corresponding target object image are quantified to obtain the image measurement features corresponding to the color dimension of the target image, including the Lab color space mean, Lab color space standard deviation and color area distribution ratio corresponding to the target object image;
[0023] Performing multi-scale texture feature measurement on the target object image corresponding to the target object comparison standard image data, decomposing the target object image into frequency sub-bands at different scales using wavelet transform, and calculating the texture contrast, texture correlation, texture energy and texture entropy features corresponding to the target object image using the gray level co-occurrence matrix at each frequency sub-band to obtain image measurement features corresponding to the texture dimension of the target image;
[0024] Performing topological geometric structural feature measurement on the target object image corresponding to the target object comparison standard image data, so as to extract the corresponding outline and shape size of the target object from the target object image using morphological operations, calculate the number of connected regions and the number of holes corresponding to the target object using the Euler number in topology, and calculate the center of gravity, principal axis direction and structural degree parameters of the target object, including circularity and rectangularity, using geometric moments to obtain image measurement features corresponding to the structural dimensions of the target image;
[0025] The image measurement features corresponding to the color, texture and structural dimensions of the target image are weightedly fused before verification to obtain the target object image measurement features corresponding to the style transfer.
[0026] Furthermore, the target object multi-channel image specifically includes target object images corresponding to the R channel, the G channel, and the B channel.
[0027] Furthermore, the color feature quantification of the corresponding target object image based on the multi-channel image of the target object and in combination with the principles of physical optics includes:
[0028] Based on the multi-channel image of the target object and combined with the principles of physical optics, the corresponding target object image is converted to Lab color space to generate the corresponding target object image in Lab color space, where L represents brightness, and a and b represent the chromaticity corresponding to the color area;
[0029] Perform color space statistical calculation on the target object image corresponding to the Lab color space to obtain the Lab color space mean and Lab color space standard deviation corresponding to the target object image;
[0030] The color region distribution of the target object image corresponding to the Lab color space is determined based on the Lab color space mean and the Lab color space standard deviation, so as to obtain the color distribution range corresponding to different color regions in the target object image on the ab plane;
[0031] The color distribution ratio of the target object image corresponding to the Lab color space is obtained by obtaining the color center coordinate points of different color areas on the ab plane. Based on the color distribution range and color center coordinate points of different color areas on the ab plane, the color distribution ratio of the target object image corresponding to the Lab color space is analyzed to obtain the color area distribution ratio corresponding to the target object image.
[0032] The Lab color space mean, Lab color space standard deviation, and color area distribution ratio corresponding to the target object image are feature merged to obtain the image measurement features corresponding to the color dimension of the target image.
[0033] Furthermore, the similarity measurement module before and after migration includes the following functions:
[0034] Acquire reference image data of the target object corresponding to the target area;
[0035] Performing consistent target feature measurements on the target object reference image corresponding to the target object reference image data to obtain corresponding image measurement features of the target reference image in color, texture, and structure dimensions;
[0036] Using edge computing nodes, the image measurement features corresponding to the target reference image in color, texture, and structure dimensions are used to perform image style transfer on the target object image corresponding to the standard image data. The image data of the target object after transfer is obtained based on the computing resources and performance optimization of the edge computing nodes.
[0037] Re-measure the target object features of the target object image corresponding to the target object image data after the target object is transferred, and obtain the measured features of the target object image corresponding to the style transfer;
[0038] Based on the measured features of the target object image corresponding to the style transfer before style transfer, the measured features of the target object image corresponding to the style transfer after style transfer are measured to obtain the feature similarity before and after style transfer corresponding to the target object image.
[0039] Furthermore, performing similarity measurement before and after style transfer on the measured features of the target object image corresponding to the style transfer based on the measured features of the target object image corresponding to the style transfer includes:
[0040] The color distribution information entropy of the image measurement features corresponding to the color dimension before style migration is calculated based on the image measurement features corresponding to the color dimension after style migration, and the color distribution information entropy difference before and after style migration is obtained;
[0041] Based on the image measurement features corresponding to the texture dimension before style transfer and combined with the gray-level co-occurrence matrix, the texture frequency analysis is performed on the image measurement features corresponding to the texture dimension after style transfer to obtain the texture pattern frequency before and after style transfer.
[0042] Based on the image measurement features corresponding to the structural dimension before style transfer, the image measurement features corresponding to the structural dimension after style transfer are calculated to obtain the object contour structure similarity index before and after style transfer;
[0043] Based on the color distribution information entropy difference, texture pattern occurrence frequency and object contour structure similarity index before and after style transfer, the similarity calculation formula before and after style transfer is used to measure the measured features of the target object image before and after style transfer to obtain the feature similarity before and after style transfer corresponding to the target object image.
[0044] Furthermore, the similarity calculation formula before and after style transfer is specifically as follows:
[0045]
[0046] Where S is the feature similarity before and after style transfer, ΔH c is the color distribution information entropy difference before and after style transfer, α is the color information entropy similarity weight, n is the total number of texture patterns in the target object image, ΔP i is the frequency of texture pattern occurrence corresponding to the i-th texture pattern in the target object image, β i is the similarity weight of the frequency of occurrence corresponding to the i-th texture pattern in the target object image, Ω is the spatial domain range corresponding to the target object image, x is the spatial domain position parameter, I s (x) is the size of the target object contour structure corresponding to the style transfer at position x, I t(x) is the size of the target object contour structure before style transfer at position x, δ is the object contour structure similarity index, and λ is the contour structure similarity weight.
[0047] Furthermore, the module for measuring the difference between before and after migration includes the following functions:
[0048] The target object image is compared with the pre- and post-style transfer feature similarity based on the preset pre- and post-style transfer similarity threshold (0.9, 1.1). If the pre- and post-style transfer feature similarity of the target object image is within the interval corresponding to the pre- and post-style transfer similarity threshold, it is considered that the target object image has no significant change before and after the style transfer; if the pre- and post-style transfer feature similarity of the target object image is outside the interval corresponding to the pre- and post-style transfer similarity threshold, it is considered that there are feature differences before and after the style transfer of the target object image.
[0049] Perform deep feature decomposition on the target object with feature differences compared to the standard image data and the image data after style transfer. In terms of color, independent component analysis is used to separate the main color, auxiliary color, and color deviation components of the corresponding target object image. In terms of texture, contourlet transform is used to decompose the texture features into texture sub-features of different scales and directions. In terms of structure, shape decomposition is used to decompose the target object structure into basic geometric shapes. Based on the decomposed image features, the features of the target object images before and after style transfer are reconstructed to obtain the feature expressions of the target object images before and after style transfer.
[0050] Based on the feature expression of the target object image before and after style transfer, the style transfer difference of the target object image before and after style transfer is measured to calculate the information interaction between the color components before and after style transfer in terms of color, calculate the complementarity between texture features of different scales and directions before and after style transfer in terms of texture, and calculate the shape matching between the topological structures before and after style transfer in terms of structure. A weighted average calculation of the differences is performed based on the information interaction, complementarity and shape matching to obtain the difference before and after style transfer corresponding to the target object image.
[0051] Beneficial effects of the present invention:
[0052] The image processing and measurement system based on edge computing proposed in the present invention is composed of a target image real-time acquisition module, a target object feature measurement module, a similarity measurement module before and after migration, and a difference measurement module before and after migration. Compared with the prior art, the beneficial effect of the present application is that by arranging edge computing nodes in the target area and combining the use of image acquisition equipment, real-time acquisition of target object image data can be achieved. By configuring appropriate image acquisition parameters, the image acquisition equipment can accurately capture the relevant image data of objects in the target area and transmit these data to the nearest edge computing node for further processing. Such a setting can play a vital role in real-time performance, avoiding the delay that may be caused when image data is transmitted to a remote data center, and the introduction of edge computing nodes can sink data processing, analysis and other tasks to a location closer to the data source, reducing dependence on network bandwidth, improving the speed and efficiency of data processing, and enabling the system to respond quickly. Secondly, by performing contrast enhancement processing on the target object image data on the edge computing node, the image recognizability and accuracy can be effectively improved. The image contrast enhancement algorithm can strengthen the important feature areas in the image, remove or suppress background noise, highlight the key features of the target object, and make subsequent feature measurements more accurate. In addition, the target object feature measurement after image enhancement lays a solid foundation for subsequent analysis. By performing accurate feature measurement on the target object, the image features of the target object before style transfer can be obtained. These features provide a comparative reference for subsequent image style transfer and feature similarity analysis. Furthermore, these feature data can be used to evaluate whether the effect after style transfer is consistent with the original object image features, thereby ensuring the quality and accuracy of style transfer. Then, by performing style transfer on the target object image after obtaining the reference image data of the target object, the image style of the target object can be adjusted to a style similar to the reference image. Style transfer can not only change the appearance of the image, so that the target object visually presents the style characteristics of the reference image, but also enhance the visual appeal and artistic sense of the target object by changing the details, color, texture and other levels of the image. The key to this process is that through image style transfer technology, the original style of the target object can be retained while adopting a certain artistic style to make it more expressive and diverse, thereby meeting the requirements of visual effects in different application scenarios. In this process, the similarity comparison between the features of the style-transferred image and the original image is also performed to ensure that the image style transfer will not cause too much interference with the core features of the target object, and ensure that the style-transferred image maintains the recognizability of the target object.Finally, by measuring the effect of style transfer based on the feature similarity before and after style transfer, a scientific basis can be provided for the optimization of the style transfer algorithm. The feature similarity value before and after style transfer can effectively reflect whether the key features of the target object (such as shape, size, position, etc.) have changed significantly during the image style transfer process. If the difference between the image after style transfer and the image before style transfer is small, it means that the style transfer process maintains the core features of the target object, which can effectively ensure that the style of the target object is improved in visual effects without losing its original physical features. By measuring the style transfer difference, the success of image style transfer can be evaluated, and the style transfer parameters can be adjusted to ensure that the final generated target object image can meet the needs of style conversion while maintaining high image quality and feature consistency. This can overcome the balance between the image style transfer effects, thereby improving the processing efficiency of the target object image style transfer. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Other features, objects and advantages of the present invention will become more apparent upon reading the detailed description of non-limiting embodiments thereof made with reference to the following drawings:
[0054] Figure 1 This is a module diagram of the image processing and measurement system based on edge computing of the present invention;
[0055] Figure 2 for Figure 1 Schematic diagram of the functional flow of the target image real-time acquisition module;
[0056] Figure 3 for Figure 1 Schematic diagram of the functional flow of the target object feature measurement module. DETAILED DESCRIPTION
[0057] The following is a clear and complete description of the technical system of the present invention in conjunction with the accompanying drawings. Obviously, the embodiments described are part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making any creative efforts are within the scope of protection of the present invention.
[0058] In addition, the accompanying drawings are merely schematic illustrations of the present invention and are not necessarily drawn to scale. Identical reference numerals in the figures denote identical or similar parts, and thus repetitive descriptions thereof will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities that do not necessarily correspond to physically or logically independent entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different networks and / or processor systems and / or microcontroller systems.
[0059] It should be understood that although the terms "first," "second," and the like may be used herein to describe various elements, these elements should not be limited by these terms. These terms are used solely to distinguish one element from another. For example, a first element may be referred to as a second element, and similarly, a second element may be referred to as a first element, without departing from the scope of the exemplary embodiments. The term "and / or" as used herein includes any and all combinations of one or more of the listed associated items.
[0060] To achieve this, please refer to Figures 1 to 3 The present invention provides an image processing measurement system based on edge computing, which includes the following modules:
[0061] The target image real-time acquisition module is used to arrange edge computing nodes next to the image acquisition device corresponding to the target area, and use the image acquisition device to perform real-time image acquisition of the target object corresponding to the target area by setting corresponding image acquisition parameters to obtain the target object image data and transmit it to the edge computing node;
[0062] A target object feature measurement module is used to generate target object comparison standard image data by performing image contrast enhancement on the target object image data on the edge computing node; perform target object feature measurement on the target object comparison standard image data to obtain the corresponding target object image measurement features before style transfer;
[0063] The similarity measurement module before and after the migration is used to obtain the target object reference image data corresponding to the target area, and perform image style migration on the target object compared with the standard image data based on the target object reference image data to obtain the target object image data after migration; based on the measured features of the target object image before the style migration, the similarity measurement before and after the style migration of the target object image after migration is performed to obtain the feature similarity before and after the style migration of the target object image;
[0064] The module for measuring the difference between the style before and after migration is used to measure the style difference between the target object and the standard image data and the image data after migration of the target object based on the feature similarity before and after the style migration corresponding to the target object image, so as to obtain the difference between the style before and after migration corresponding to the target object image.
[0065] In the embodiment of the present invention, please refer to Figure 1 FIG. 1 is a schematic diagram of a module of an image processing and measurement system based on edge computing according to the present invention. In this example, the image processing and measurement system based on edge computing includes the following modules:
[0066] S1: Target image real-time acquisition module, which is used to arrange edge computing nodes next to image acquisition devices corresponding to the target area, and use the image acquisition devices to acquire images of the target objects corresponding to the target area in real time by setting corresponding image acquisition parameters, so as to obtain target object image data and transmit it to the edge computing node;
[0067] In an embodiment of the present invention, by installing an image acquisition device with high resolution and low latency in the target area, such as a high-definition camera or image sensor, it is ensured that the device can accurately capture the image of the target object. The position of the image acquisition device should be reasonably arranged according to the specific environment of the target area to ensure that the viewing angle range of the target object can be covered. In this step, it is necessary to set reasonable image acquisition parameters, including but not limited to exposure time, frame rate, resolution, sensitivity of the image sensor, etc., to ensure the clarity and high quality of the image data. In addition, the real-time collected image data is transmitted to an edge computing node installed nearby through a network connection. The edge computing node is equipped with powerful image processing capabilities and can process and transmit the collected image data in a timely manner. Through stable wireless or wired communication methods, the real-time and high efficiency of image data transmission are ensured to avoid image data delay or loss.
[0068] S2: Target object feature measurement module, used to generate target object comparison standard image data by performing image contrast enhancement on the target object image data on the edge computing node; perform target object feature measurement on the target object comparison standard image data to obtain the corresponding target object image measurement features before style transfer;
[0069] In an embodiment of the present invention, in an edge computing node, the target object image data obtained by the image acquisition device is first transmitted to the image processing module. The image contrast enhancement technology increases the difference between the target object and the background by performing grayscale enhancement, edge sharpening and contrast adjustment on the image data, so that the target object is more prominent in the image. For the enhanced image data, computer vision algorithms such as feature point extraction, contour analysis and region segmentation are used to measure the features of the target object. These feature measurements include the size, shape, color distribution, texture features, etc. of the target object, forming the image measurement features of the target object, and finally obtaining the corresponding target object image measurement features before style transfer.
[0070] S3: a similarity measurement module before and after migration, which is used to obtain the target object reference image data corresponding to the target area, and perform image style migration on the target object compared with the standard image data based on the target object reference image data to obtain the target object image data after migration; based on the measured features of the target object image before style migration, perform similarity measurement on the target object image data after migration to obtain the feature similarity before and after style migration corresponding to the target object image;
[0071] In an embodiment of the present invention, after acquiring target object image data and completing contrast enhancement, the system retrieves reference image data of the target object from an image library or database. The reference images typically include multiple representations of the object under different perspectives and environmental conditions. These reference images serve as target samples for style transfer, so that the style of the contrast-enhanced image data of the target object can be transferred. The style transfer algorithm uses deep learning methods, such as convolutional neural networks (CNNs). By training the target object by comparing standard image data and reference image data, the style features of the target image are made to tend towards the visual style of the reference image while maintaining the basic structure and features of the target object. The image data after style transfer is adjusted to conform to the set target style to generate a transferred image of the target object. Then, the measured features of the target object image before style transfer are used to compare the transferred image and calculate the similarity between the two. The similarity between the images before and after transfer is measured through methods such as feature point matching and texture comparison, and ultimately the feature similarity before and after style transfer corresponding to the target object image is obtained.
[0072] S4: A module for measuring the difference between the target object and the standard image data and the image data after the migration based on the similarity of the style features before and after the migration corresponding to the target object image, so as to obtain the difference between the style before and after the migration corresponding to the target object image.
[0073] In an embodiment of the present invention, by calculating the similarity of image features before and after style transfer, the style transfer difference of the target object image is further measured. First, the feature measurement results of the target object image after transfer obtained previously are compared with the measurement results before style transfer, and standard difference calculation methods, such as mean square error (MSE) and structural similarity index (SSIM), are used to evaluate the feature differences before and after the style transfer of the target object. The difference calculation can reflect the degree of influence of the shape, color, texture and other features of the target object during the style transfer process. According to the difference measurement results, a difference index of the image before and after style transfer is generated as a basis for subsequent judgment of the quality of the style transfer effect. The difference index can provide feedback for optimizing the style transfer algorithm, further improve the image style transfer effect, and finally measure the difference before and after style transfer corresponding to the target object image.
[0074] Furthermore, the target image real-time acquisition module includes the following functions:
[0075] By arranging corresponding edge computing nodes next to the image acquisition devices corresponding to the target area;
[0076] Obtaining a corresponding target measurement object and target measurement requirements through a target object in a target area, and appropriately setting acquisition parameters of an image acquisition device based on the target measurement object and target measurement requirements to generate corresponding image acquisition parameters, including resolution, frame rate, and exposure time;
[0077] Based on the image acquisition parameters, the image acquisition device is started to perform real-time image acquisition of the target object corresponding to the target area to obtain image data of the target object;
[0078] The target object image data is transmitted to the edge computing node via wireless transmission.
[0079] As an embodiment of the present invention, refer to Figure 2 As shown, Figure 1 Schematic diagram of the functional flow of the target image real-time acquisition module in this embodiment. The target image real-time acquisition module includes the following functions:
[0080] S11: Arrange corresponding edge computing nodes next to the image acquisition device corresponding to the target area;
[0081] In an embodiment of the present invention, when arranging edge computing nodes next to the image acquisition device corresponding to the target area, it is first necessary to select appropriate edge computing devices. These devices usually have strong processing capabilities and low latency to ensure that image data can be processed in real time. Each edge computing node should be arranged according to the actual needs of the target area and can cover the key monitoring areas within the entire target area. The location of the image acquisition device should be taken into consideration during the arrangement to ensure stable signal transmission. For more complex areas, multiple edge computing nodes can be set up to improve data processing efficiency and reliability through distributed computing. These edge computing nodes must also be equipped with wireless transmission modules to ensure unimpeded data transmission between them and the image acquisition device.
[0082] S12: obtaining a corresponding target measurement object and target measurement requirements through the target object in the target area, and appropriately setting acquisition parameters of the image acquisition device based on the target measurement object and the target measurement requirements to set and generate corresponding image acquisition parameters, including resolution, frame rate, and exposure time;
[0083] In an embodiment of the present invention, the acquisition of a target object within a target area can be automatically identified by the image acquisition device's sensor. Once the target object is located and confirmed, the system sets the relevant measurement targets based on the target object's specific characteristics and measurement requirements. For example, if the target object is a part of a specific model, the measurement targets include its size, shape, surface quality, and other indicators. The target measurement requirements are set based on actual application needs, such as high precision and real-time requirements. Based on this, the image acquisition device's acquisition parameters, such as resolution, frame rate, and exposure time, are precisely set. The resolution parameter is set based on the target object's size and detail requirements, the frame rate parameter is adjusted based on the motion speed and real-time requirements during acquisition, and the exposure time setting must take into account the lighting conditions of the target area and the required image brightness and clarity. Ultimately, the corresponding image acquisition parameters are set and generated.
[0084] S13: starting and using an image acquisition device to acquire an image of a target object corresponding to the target area in real time based on the image acquisition parameters to obtain image data of the target object;
[0085] In an embodiment of the present invention, after the acquisition parameters of the image acquisition device are set, the system starts the image acquisition device to perform real-time image acquisition of the target object. During the acquisition process, the image acquisition device uses its built-in sensor to shoot the target object in the target area in real time and generates image data. During the acquisition process, the device automatically performs image processing to ensure that the image quality meets the predetermined measurement requirements. For example, the device will automatically adjust the exposure settings, focus and correct the color to ensure that the acquired image is clear and distortion-free, and can accurately reflect the actual state of the target object. If the image quality does not meet the standards during the acquisition process, the device will automatically adjust the parameters and re-acquire until satisfactory image data is obtained, and finally the target object image data is obtained.
[0086] S14: Transmit the target object image data to the edge computing node via wireless transmission.
[0087] In an embodiment of the present invention, after image data acquisition is completed, the image data will be transmitted to the edge computing node through wireless transmission technology (such as Wi-Fi, 5G or dedicated wireless network). The stability and speed of wireless transmission directly affect the quality and efficiency of image data transmission. Therefore, the wireless network needs to be carefully debugged and optimized during this process to ensure that data loss and delay during transmission are minimized. After receiving the image data, the edge computing node will perform preliminary processing on the image data, such as noise removal, image enhancement and other operations, and provide processing results for subsequent detailed image processing and measurement analysis. During the transmission and processing of image data, the data in the transmission process must also be encrypted to ensure data security and privacy protection.
[0088] Furthermore, the target object feature measurement module includes the following functions:
[0089] By gray-scaling the target object image data on the edge computing node, gray-scale image data of the target object is obtained;
[0090] Calculating pixel fuzziness of the grayscale image data of the target object to obtain pixel fuzziness of the target object image;
[0091] Performing fuzzy noise filtering on the target object image data based on the pixel fuzziness of the target object image to obtain fuzzy denoised image data of the target object;
[0092] Performing histogram equalization enhancement on the blurred denoised image data of the target object to generate target object contrast standard image data;
[0093] The target object is compared with the standard image data to measure the target object features and obtain the corresponding target object image measurement features before style transfer, including the image measurement features corresponding to the target image color, texture and structural dimensions.
[0094] As an embodiment of the present invention, refer to Figure 3 As shown, Figure 1 Schematic diagram of the functional flow of the target object feature measurement module in this embodiment. The target object feature measurement module includes the following functions:
[0095] S21: Obtaining grayscale image data of the target object by grayscale processing on the edge computing node;
[0096] In an embodiment of the present invention, the original image data of the target object is first obtained on the edge computing node, and the image is processed using a grayscale algorithm to convert the color image into a grayscale image. The specific implementation method is to use the weighted average method to process each pixel of the RGB image. For each pixel, its grayscale value is calculated. The formula is: grayscale value = 0.2989*R+0.5870*G+0.1140*B, where R, G, and B are the red, green, and blue components of the pixel, respectively. Through this process, all color information is converted into grayscale information, and finally the grayscale image data of the target object is obtained.
[0097] S22: Calculating pixel fuzziness of the grayscale image data of the target object to obtain pixel fuzziness of the target object image;
[0098] In an embodiment of the present invention, after completing the image grayscale processing, the pixel blur is calculated. This step is to quantify the blur degree of the image by calculating the grayscale difference between the surrounding pixels of each pixel in the image and the pixel itself. Specifically, a convolution operation is adopted and a blur kernel is used to filter the grayscale image to obtain the blur value of each pixel in the target image. The blur calculation method is: for each pixel, the difference between the grayscale values of the 8 pixels around it and the grayscale value of the pixel is used to evaluate the blur degree. The larger the blur value, the lower the clarity of the image in the area, and finally the pixel blur of the target object image is obtained.
[0099] S23: performing fuzzy noise filtering on the target object image data based on the pixel fuzziness of the target object image to obtain fuzzy denoised image data of the target object;
[0100] In an embodiment of the present invention, blur noise filtering processing of the image is performed based on the image pixel blur information obtained by previous calculation. The specific operation is to select an appropriate filtering algorithm for denoising according to the size of the blur. For high blur areas, a denoising technology based on Gaussian filtering is used to gradually reduce the noise in the image. Through the Gaussian kernel function, the value of each pixel in the image is adjusted according to the weighted average of its surrounding pixels to remove the noise in the image and restore the clarity of the image. After filtering processing, the blurred denoised image data of the target object is finally obtained, and the noise and blur in the image are effectively reduced.
[0101] S24: performing histogram equalization enhancement on the blurred denoised image data of the target object to generate target object comparison standard image data;
[0102] In an embodiment of the present invention, after obtaining the blurred denoised image data, the image is subjected to histogram equalization processing. The purpose of this step is to enhance the contrast of the image and make the details in the image more obvious. The specific method is to calculate the grayscale histogram of the image and map the grayscale values of the image to a new range to make the grayscale distribution of the image more uniform. Histogram equalization redistributes the pixel grayscale values in the original image to enhance the visibility of low-contrast areas, making the image of the target object clearer and richer in details. Through this process, the target object contrast standard image data is finally generated.
[0103] S25: measuring target object features by comparing the target object with the standard image data to obtain the target object image measurement features corresponding to the style transfer, including the image measurement features corresponding to the target image color, texture, and structural dimensions.
[0104] In an embodiment of the present invention, the target object features are measured based on the obtained target object comparison standard image data. This step involves extracting characteristic information such as color, texture, and structure of the target object from the image. The color features are obtained by calculating the color histogram of the image or the distribution in other color spaces (such as HSV). The texture features are extracted by calculating the gray-level co-occurrence matrix (GLCM) of the image, including indicators such as image contrast, uniformity, and entropy. The structural dimension features are extracted by edge detection (such as the Canny edge detection algorithm) to extract the contour and structural information of the object in the image. By measuring these features, the target object image measurement features corresponding to the style transfer are finally obtained, including the image measurement features corresponding to the color, texture, and structural dimensions of the target image.
[0105] Furthermore, measuring the characteristics of the target object by comparing the target object with the standard image data includes:
[0106] Performing multi-channel separation on the target object image corresponding to the target object comparison standard image data to obtain a multi-channel image of the target object;
[0107] In an embodiment of the present invention, the target object image corresponding to the target object is separated by comparing the target object with the standard image data, which is usually a color image in RGB format. The image is composed of the superposition of data of the three color channels of red (R), green (G), and blue (B). When performing multi-channel separation, the RGB value of each pixel in the image is split according to the pixel-level operation. For each pixel in the image, the R component of its RGB value is extracted to form a new two-dimensional matrix. This matrix constitutes the target object image corresponding to the R channel. Similarly, the G component and B component of each pixel are extracted separately, and each forms a new two-dimensional matrix, thereby obtaining the target object images corresponding to the G channel and the B channel. For example, if the image is a 100×100 pixel RGB image, then after separation, three 100×100 matrices will be obtained, corresponding to the target object images of the R, G, and B channels respectively.
[0108] Preferably, based on the multi-channel image of the target object and in combination with the principles of physical optics, the color features of the corresponding target object image are quantified to obtain image measurement features corresponding to the color dimension of the target image, including the Lab color space mean, Lab color space standard deviation, and color area distribution ratio corresponding to the target object image;
[0109] In an embodiment of the present invention, the target object image of the previously separated R, G, and B channels is converted to the Lab color space based on the principle of color space conversion in physical optics. The specific conversion formula is to first convert the RGB value into the CIE XYZ value, and then convert the CIE XYZ value into the Lab value. For each pixel point, the conversion is completed through a series of mathematical operations. After obtaining the target object image in the Lab color space, the three components L, a, and b are statistically calculated respectively. For the L component, add the L values of all pixels and divide it by the total number of pixels to obtain the L mean. Calculate the sum of the squares of the differences between the L value of each pixel and the L mean, divide it by the total number of pixels and take the square root to obtain the L standard deviation. Similarly, calculate the mean and standard deviation of the a and b components. Next, divide the image in the Lab color space into color regions, and use a clustering algorithm (such as K-means clustering) to group pixels with similar colors into the same region. Calculate the proportion of pixels occupied by each color region in the entire image, that is, obtain the color region distribution ratio. Finally, the Lab color space mean, standard deviation, and color region distribution ratio together constitute the image measurement features corresponding to the color dimension of the target image, and finally obtain the image measurement features corresponding to the color dimension of the target image.
[0110] Preferably, multi-scale texture feature measurement is performed on a target object image corresponding to the target object comparison standard image data, so as to decompose the target object image into frequency sub-bands at different scales using wavelet transform, and calculate texture contrast, texture correlation, texture energy and texture entropy features corresponding to the target object image using a gray level co-occurrence matrix at each scale frequency sub-band to obtain image measurement features corresponding to the texture dimension of the target image;
[0111] In an embodiment of the present invention, when measuring the multi-scale texture features of a target object image corresponding to the target object comparison standard image data, a wavelet transform is used to process the image. The wavelet transform decomposes the image into frequency sub-bands at different scales, generally including a low-frequency sub-band and multiple high-frequency sub-bands. For example, after a first-level wavelet transform, the image will be decomposed into an approximate sub-band (low frequency) and three detail sub-bands (horizontal, vertical, and diagonal high frequencies). For the frequency sub-bands at each scale, a gray-level co-occurrence matrix is constructed. The gray-level co-occurrence matrix describes the frequency of occurrence of gray-level pairs with a certain spatial position relationship in the image, with a certain distance and angle (such as a distance of 1, an angle of 0°, 45°, The grayscale co-occurrence matrix is calculated based on the grayscale co-occurrence matrix. The texture contrast is calculated based on the grayscale co-occurrence matrix, which reflects the degree of difference in grayscale values in the image and is obtained by calculating the weighted sum of the square differences between the elements in the matrix and the mean; the texture correlation measures the degree of linear dependence of the local grayscale of the image and is obtained by calculating the ratio of the covariance of the matrix elements to the standard deviation; the texture energy represents the uniformity of the grayscale distribution of the image and is the sum of the squares of the matrix elements; the texture entropy reflects the complexity of the grayscale distribution of the image and is obtained by taking the logarithm of the matrix elements and weighted summing them. These texture contrast, texture correlation, texture energy and texture entropy features together constitute the image measurement features corresponding to the texture dimension of the target image.
[0112] Preferably, a topological geometric structural feature measurement is performed on a target object image corresponding to the target object and the standard image data, so as to extract the contour and shape size of the target object from the target object image using morphological operations, calculate the number of connected regions and the number of holes corresponding to the target object using the Euler number in topology, and calculate the center of gravity, principal axis direction, and structural degree parameters of the target object, including circularity and rectangularity, using geometric moments, so as to obtain image measurement features corresponding to the structural dimensions of the target image;
[0113] In an embodiment of the present invention, when measuring the topological geometric structural features of the target object image corresponding to the target object and the standard image data, morphological operations are first used for processing, and the morphological operations include dilation, erosion, opening operation and closing operation. The dilation operation can fill small holes inside the target object, so that the boundary of the target object expands outward; the erosion operation can remove the edge of the target object, so that the boundary of the target object shrinks inward. Combining the opening operation (erosion first and then dilation) and the closing operation (dilation first and then erosion) can remove small noise points in the image and smooth the boundary of the target object, thereby extracting the contour corresponding to the target object. Based on the contour information, the shape and size of the target object, such as area, perimeter, etc., can be calculated. Next, the Euler number in topology is used for calculation. The Euler number is equal to the number of connected areas minus the number of holes. By marking the connected areas in the image and detecting the holes, the number of connected areas and the number of holes can be obtained, and then calculated using geometric moments. Geometric moments are a method of statistically describing the grayscale distribution of the target object in the image. The zero-order moment can be used to calculate the area of the target object. The first-order moment combined with the zero-order moment can calculate the center of gravity coordinates of the target object. The second-order central moment can calculate the main axis direction of the target object. The circularity is calculated by the relationship between the circumference and the area. The formula is 4π×area / circumference. 2 The closer its value is to 1, the closer the target object is to a circle. The rectangularity is calculated by the ratio of the area of the target object to the area of the minimum circumscribed rectangle, reflecting the similarity between the target object and the rectangle. These features such as the center of gravity, main axis direction, circularity, rectangularity, the number of connected areas, and the number of holes constitute the image measurement features corresponding to the structural dimension of the target image.
[0114] Preferably, the image measurement features corresponding to the color, texture and structural dimensions of the target image are weightedly fused for verification before migration to obtain the corresponding target object image measurement features before style migration.
[0115] In an embodiment of the present invention, after obtaining the image measurement features corresponding to the color, texture, and structure dimensions of the target image, pre-transfer verification weighted fusion is performed. First, the image measurement features of each dimension are verified. For the color dimension features, the Lab color space mean, standard deviation, and color area distribution ratio are checked to see if they are within a reasonable value range to avoid outliers that affect subsequent fusion. For the texture dimension features, the texture contrast, texture correlation, texture energy, and texture entropy are verified to see if they conform to the actual texture of the image. For the structure dimension features, the center of gravity, principal axis direction, circularity, rectangularity, number of connected regions, and number of holes are checked to see if they conform to the actual structure of the target object. Then, weights are assigned to the features of each dimension. The weight assignment is determined based on the importance of the features of different dimensions in style transfer. For example, if color is more important in style transfer, a higher weight is assigned to the color dimension features; if texture has a greater impact on style, a higher weight is assigned to the texture dimension features. The feature value of each dimension is multiplied by the corresponding weight, and the weighted feature values of all dimensions are then merged to ultimately obtain the corresponding target object image measurement features before style transfer.
[0116] Furthermore, the target object multi-channel image specifically includes target object images corresponding to the R channel, the G channel, and the B channel.
[0117] Furthermore, the color feature quantification of the corresponding target object image based on the multi-channel image of the target object and in combination with the principles of physical optics includes:
[0118] Based on the multi-channel image of the target object and combined with the principles of physical optics, the corresponding target object image is converted to Lab color space to generate the corresponding target object image in Lab color space, where L represents brightness, and a and b represent the chromaticity corresponding to the color area;
[0119] In an embodiment of the present invention, a multi-channel image of a target object is obtained, such as a common RGB three-channel image, which contains pixel information of the target object in the three color channels of red, green, and blue. Based on the principles of color mixing and conversion in physical optics, the red, green, and blue values of each pixel in the RGB color space are calculated using a specific mathematical conversion formula. Specifically, for each pixel, according to the conversion formula: L = 116*f(X / Xn)-16, a = 500*(f(Y / Yn)-f(X / Xn)), b = 200*(f(Z / Zn)-f(Y / Yn)). (Where X, Y, and Z are CIE_XYZ values converted from RGB, Xn, Yn, and Zn are CIE_XYZ values of standard white, and f(t) is t^(1 / 3) when t>0.008856 and 7.787*t+16 / 116 when t<=0.008856). The color value of each pixel is converted to L, a, and b values in the Lab color space to obtain the representation of the entire target object image in the Lab color space. L represents the brightness of the pixel, and a and b represent the chromaticity corresponding to the color area. Finally, the corresponding target object image in the Lab color space is generated.
[0120] Preferably, a color space statistical calculation is performed on the target object image corresponding to the Lab color space to obtain the Lab color space mean and the Lab color space standard deviation corresponding to the target object image;
[0121] In an embodiment of the present invention, by for the target object image that has been converted to the Lab color space, the L value, a value and b value of all pixels in the image are statistically calculated respectively. For the L value, the L value of all pixels in the image is added up and then divided by the total number of pixels to obtain the average value of the L value, that is, the mean of L. In the same way, the a value of all pixels is summed up and divided by the total number of pixels to obtain the mean of a, and the b value is summed up and divided by the total number of pixels to obtain the mean of b. Then the standard deviation is calculated. For the L value, the square of the difference between the L value of each pixel and the L mean is calculated, all these square values are added up, then divided by the total number of pixels, and finally the result is squared to obtain the standard deviation of the L value. In the same way, the standard deviation of the a value and the b value is calculated respectively. By such calculation, the L mean, a mean, b mean and L standard deviation, a standard deviation and b standard deviation of the Lab color space corresponding to the target object image are obtained, and finally the Lab color space mean and Lab color space standard deviation corresponding to the target object image are obtained.
[0122] Preferably, the color region distribution of the target object image corresponding to the Lab color space is determined based on the Lab color space mean and the Lab color space standard deviation, so as to obtain the color distribution range corresponding to different color regions in the target object image on the ab plane;
[0123] In an embodiment of the present invention, by knowing the L mean, a mean, b mean, and L standard deviation, a standard deviation, and b standard deviation of the target object image in the Lab color space, since it is necessary to determine the distribution range of the color area on the ab plane, focus on the a value and the b value, with the a mean as the center, in the a-axis direction, according to the value of the a standard deviation, a range is determined, for example, with the a mean as the center, the range of the a standard deviation is expanded by a certain multiple (such as 2 times) on the left and right, to obtain the distribution range of the a value. Similarly, with the b mean as the center, in the b-axis direction, according to the value of the b standard deviation, a range is determined, for example, with the b mean as the center, the range of the b standard deviation is expanded by a certain multiple (such as 2 times) on the top and bottom, to obtain the distribution range of the b value. In this way, on the ab plane, the area surrounded by the distribution range of the a value and the distribution range of the b value is the color distribution range corresponding to the different color areas in the target object image on the ab plane. In this way, the distribution range of the color in the target object image on the ab plane is quantitatively determined, and finally the color distribution range corresponding to the different color areas in the target object image on the ab plane is obtained.
[0124] Preferably, the color centroid coordinate points corresponding to different color regions on the ab plane are obtained from the target object image corresponding to the Lab color space, and the color distribution ratio analysis is performed on the target object image corresponding to the Lab color space based on the color distribution ranges and color centroid coordinate points corresponding to the different color regions on the ab plane to obtain the color region distribution ratio corresponding to the target object image;
[0125] In an embodiment of the present invention, for an image of a target object in a Lab color space, all pixels in the image are traversed, and the pixels are divided into different color areas according to the a value and b value of the pixels. For each color area, the color center of gravity coordinate point is calculated. The specific calculation method is that for all pixels in a certain color area, the a value of each pixel is multiplied by the weight of the pixel (the weight can be set to 1, that is, the influence of other factors is not considered), and then the sum is calculated, and then the sum is divided by the total number of pixels in the color area to obtain the center of gravity coordinate of the color area on the a axis; in the same way, the b value of each pixel is multiplied by the weight of the pixel, and the sum is divided by the total number of pixels in the color area to obtain the center of gravity coordinate of the color area on the b axis, thereby obtaining the color center of gravity coordinate point of the color area on the ab plane. Next, based on the color distribution range corresponding to the different color areas determined previously on the ab plane, calculate the area ratio of each color area in the entire image, that is, the ratio of the area covered by the distribution range of the color area on the ab plane to the total area of the image color distribution on the entire ab plane. Through such calculation, the color area distribution ratio corresponding to the target object image is finally obtained.
[0126] Preferably, the Lab color space mean, Lab color space standard deviation, and color area distribution ratio corresponding to the target object image are feature merged to obtain image measurement features corresponding to the color dimension of the target image.
[0127] In an embodiment of the present invention, the L mean, a mean, b mean, L standard deviation, a standard deviation, b standard deviation, and color area distribution ratio of the Lab color space corresponding to the known target object image are combined in a certain order. For example, the L mean, a mean, and b mean are first arranged in sequence, followed by the L standard deviation, a standard deviation, and b standard deviation, and finally the distribution ratio of each color area. These data are combined into a feature vector. This feature vector contains all important information of the target object image in the color dimension. Through such a feature merging operation, the image measurement feature corresponding to the color dimension of the target image is obtained, and finally the image measurement feature corresponding to the color dimension of the target image is obtained.
[0128] Furthermore, the similarity measurement module before and after migration includes the following functions:
[0129] Acquire reference image data of the target object corresponding to the target area;
[0130] In an embodiment of the present invention, a target area is scanned by a high-precision sensor (for example, a camera, a lidar or other imaging device) to obtain reference image data containing the target object. The definition of the target area can be determined by a preset coordinate range or an intelligent recognition algorithm. After the image of the target area is obtained, the image segmentation algorithm is used to remove the non-target object part in the image, thereby extracting the image data containing the target object. This process can be processed by an edge computing node to ensure the real-time and efficient processing of image data. The edge computing node provides fast data processing capabilities, reduces data transmission delays, optimizes data storage and processing processes, ensures the accurate acquisition of target object image data, and ultimately obtains the corresponding target object reference image data within the target area.
[0131] Preferably, consistent target feature measurements are performed on the corresponding target object reference image in the target object reference image data to obtain corresponding image measurement features of the target reference image in color, texture, and structural dimensions;
[0132] In an embodiment of the present invention, an image feature extraction algorithm is first applied to a reference image of a target object obtained from a target area, and each image is processed consistently. Color features can be extracted by color space conversion (for example, converting the image from RGB color space to HSV or Lab space), analyzing the color information of each pixel, and extracting characteristic parameters such as the average value and standard deviation of the target object in the color space. Texture features are extracted by methods such as gray-level co-occurrence matrix (GLCM), analyzing texture changes and patterns in the image, and obtaining characteristic parameters such as its directionality and roughness. Structural features can be extracted by edge detection algorithms (such as Canny edge detection, Sobel operator, etc.) to extract the contour and shape of the target object, and further analyze the geometric structure and shape characteristics of the target object. All these feature values are uniformly summarized and formed into image measurement features of the target object. These features will be used as comparison standards in subsequent style transfer, and ultimately the image measurement features corresponding to the target reference image in color, texture, and structure dimensions are obtained.
[0133] Preferably, the image style of the target object is transferred by comparing the image measurement features corresponding to the target reference image in the color, texture and structure dimensions with the corresponding target object image in the standard image data using the edge computing node, and the computing resources and performance optimization adjustment corresponding to the edge computing node are used to obtain the transferred image data of the target object;
[0134] In an embodiment of the present invention, the core task of image style migration is undertaken by the edge computing node. First, by comparing the measured features of the target object reference image and the comparison standard image in color, texture and structure dimensions, a set of mapping rules are constructed. These mapping rules are used to achieve the migration of the target reference image to the comparison standard image style. The style migration algorithm (for example, a neural style migration algorithm based on a convolutional neural network) adjusts the color, texture and structural features of the target object image to the features of the comparison standard image. Through the edge computing node, computing resources (such as GPU acceleration) can be dynamically adjusted and optimized according to demand to ensure the efficiency and high quality of the migration process and avoid delays or image quality degradation caused by insufficient computing resources. The migrated image data will be transmitted to the next step for further processing to finally obtain the migrated image data of the target object.
[0135] Preferably, target object features are remeasured on the target object image corresponding to the target object image data after the target object is transferred, to obtain measured features of the target object image corresponding to the style transfer;
[0136] In an embodiment of the present invention, feature extraction is performed again on the target object image data after style transfer, similar to the feature measurement in step S32. First, the same image feature extraction method as in step S32 is used to analyze the color, texture and structural features of the target object image after transfer. For color features, the average color value, contrast and other parameters are still extracted through color space conversion and statistical analysis methods; for texture features, the texture roughness, directionality, etc. of the image are obtained through texture analysis methods (such as grayscale co-occurrence matrix); for structural features, the outline and shape of the target object are analyzed through edge detection algorithms, and finally the feature parameters of the target object image after style transfer are obtained.
[0137] Preferably, a similarity measurement before and after style transfer is performed on the measured features of the target object image corresponding to the target object image before style transfer, so as to obtain the feature similarity before and after style transfer corresponding to the target object image.
[0138] In an embodiment of the present invention, the effect of style transfer is evaluated by calculating the similarity between the target object image features before and after the transfer. In specific implementation, a distance measurement method (such as Euclidean distance, cosine similarity, etc.) can be used to compare the differences in color, texture, and structural features of the images before and after the transfer. By calculating these difference values, a similarity score of the target object image before and after the style transfer is obtained. If the transfer effect is good, the similarity score should be close to 1; if the transfer effect is poor, the similarity score will be lower or higher than 1. The similarity score can be used as a basis for further optimizing the style transfer algorithm, or as an evaluation criterion for image quality. The difference between the target object image after style transfer and the standard image is quantified to ensure the accuracy and efficiency of the style transfer process, and finally the feature similarity before and after the style transfer corresponding to the target object image is obtained.
[0139] Furthermore, performing similarity measurement before and after style transfer on the measured features of the target object image corresponding to the style transfer based on the measured features of the target object image corresponding to the style transfer includes:
[0140] The color distribution information entropy of the image measurement features corresponding to the color dimension before style migration is calculated based on the image measurement features corresponding to the color dimension after style migration, and the color distribution information entropy difference before and after style migration is obtained;
[0141] In an embodiment of the present invention, color feature extraction is performed on the target object image before and after style transfer. Specifically, the color dimension features of the image before style transfer are first extracted, and on this basis, the probability density function of its color distribution is calculated. The color histogram of the image is used to describe the color distribution, so that the occurrence probability of different colors can be effectively obtained. For the image after style transfer, the same color dimension is also used for feature extraction to obtain the probability density function of color distribution. When calculating the color distribution information entropy of the image before and after style transfer, the Shannon entropy formula is used: ΔH c =-Σp(x)log2p(x), where p(x) represents the probability of occurrence of color value x. The color distribution entropy before and after style transfer is calculated to obtain the color distribution information entropy difference value, which is used to measure the change in color distribution during the style transfer process. The key to this step is to accurately extract image color features and efficiently calculate the entropy value to ensure that the entropy value reflects the actual situation of color distribution changes. Finally, the color distribution information entropy difference before and after style transfer is obtained.
[0142] Preferably, a texture frequency analysis is performed on the image measurement features corresponding to the texture dimension before style transfer in combination with a gray-level co-occurrence matrix to obtain the texture pattern occurrence frequencies before and after style transfer.
[0143] In an embodiment of the present invention, the texture features of the image before style transfer are extracted. The texture features of the image are usually described by a gray level co-occurrence matrix (GLCM). The specific method is to first convert the image into a grayscale image, and then calculate the gray level co-occurrence matrix at different directions (such as 0 degrees, 45 degrees, 90 degrees, 135 degrees) and distance scales. By analyzing these matrices, the texture features of the image, such as contrast, homogeneity, energy, etc., are extracted. For the image after style transfer, the same operation is repeated to calculate its texture features. By comparing the gray level co-occurrence matrices before and after style transfer, the occurrence frequency of the texture pattern is calculated. This frequency analysis is based on the statistical characteristics of the gray value and adjacent positions in the matrix to evaluate the changes in the texture pattern during the style transfer process. For the calculation of texture frequency, a texture pattern matching algorithm is used to compare the difference in the frequency of occurrence of the texture pattern of the image before and after style transfer. In this way, the impact of style transfer on the image texture can be effectively evaluated, and the corresponding texture pattern occurrence frequency before and after style transfer can be obtained.
[0144] Preferably, a contour structure similarity calculation is performed on the image measurement features corresponding to the structural dimension before style transfer based on the image measurement features corresponding to the structural dimension after style transfer, so as to obtain the object contour structure similarity index corresponding to before and after style transfer;
[0145] In an embodiment of the present invention, contour detection is performed on the images before and after style transfer. Common contour detection methods include the Canny edge detection algorithm, which can extract obvious edge information in the image and thereby obtain the contour structure of the image. After edge detection is performed on the image before style transfer, its contour features are extracted, and information such as the shape, size, and position of the contour is recorded. Similarly, for the image after style transfer, the same edge detection algorithm is used to extract its contour structure. Next, calculations are performed based on the similarity of the contour structure. Commonly used algorithms are shape matching algorithms, such as Hu moments or other shape similarity measurement methods. These algorithms can compare whether the contour structures of the two images are consistent and calculate the similarity index between them, thereby obtaining the similarity of the contour structure of the object before and after style transfer. By calculating the contour structure similarity index, the impact of style transfer on the shape of the object can be quantified, thereby understanding the degree of change in the contour structure, and ultimately obtaining the corresponding object contour structure similarity index before and after style transfer.
[0146] Preferably, based on the color distribution information entropy difference, texture pattern occurrence frequency and object contour structure similarity index before and after style transfer, the similarity calculation formula before and after style transfer is used to perform similarity measurement on the target object image measurement features before and after style transfer to obtain the feature similarity before and after style transfer corresponding to the target object image.
[0147] In an embodiment of the present invention, a suitable similarity calculation formula before and after style transfer is formed by combining the color distribution information entropy difference before and after style transfer, the color information entropy similarity weight, the texture pattern occurrence frequency, the occurrence frequency similarity weight, the spatial domain range corresponding to the target object image, the spatial domain position parameter, the target object contour structure size, the object contour structure similarity index and the contour structure similarity weight to perform measurement calculation before and after style transfer, so as to quantify a comprehensive similarity value, which represents the similarity of the target object image features before and after style transfer, and finally obtains the feature similarity before and after style transfer corresponding to the target object image. In addition, the similarity calculation formula before and after style transfer can also use any similarity measurement method in this field to replace the similarity measurement process before and after style transfer, and is not limited to the similarity calculation formula before and after style transfer.
[0148] Furthermore, the similarity calculation formula before and after style transfer is specifically as follows:
[0149]
[0150] Where S is the feature similarity before and after style transfer, ΔH c is the color distribution information entropy difference before and after style transfer, α is the color information entropy similarity weight, n is the total number of texture patterns in the target object image, ΔPi is the frequency of texture pattern occurrence corresponding to the i-th texture pattern in the target object image, β i is the similarity weight of the frequency of occurrence corresponding to the i-th texture pattern in the target object image, Ω is the spatial domain range corresponding to the target object image, x is the spatial domain position parameter, I s (x) is the size of the target object contour structure corresponding to the style transfer at position x, I t (x) is the size of the target object contour structure before style transfer at position x, δ is the object contour structure similarity index, and λ is the contour structure similarity weight.
[0151] The present invention obtains a formula for calculating the similarity before and after style transfer by using a specific mathematical model and verification, which is used to measure the similarity before and after style transfer of the target object image measurement features before and after style transfer. The formula fully considers the feature similarity S before and after style transfer, and the color distribution information entropy difference ΔH before and after style transfer. c , color information entropy similarity weight α, the total number of texture patterns corresponding to the target object image n, the texture pattern occurrence frequency ΔP corresponding to the i-th texture pattern in the target object image i , the frequency similarity weight β corresponding to the i-th texture pattern in the target object image i , the spatial domain range Ω corresponding to the target object image, the spatial domain position parameter x, the corresponding target object contour structure size I after style transfer at position x s (x), the size of the target object contour structure I at position x before style transfer t (x), object contour structure similarity index δ, contour structure similarity weight λ, according to the correlation between the feature similarity S before and after style transfer and the above parameters, a functional relationship is formed. This formula measures the similarity between the target object image and the pre- and post-style transfer features. It also comprehensively considers changes in multiple dimensions, such as the color distribution entropy difference. This measure measures the change in color distribution before and after style transfer, effectively capturing changes in image color features and reflecting changes in image color style. By adjusting the weights, it flexibly controls the impact of color information on the overall similarity, helping to accurately reflect the shift in color style. Texture pattern frequency difference, by analyzing texture features based on the gray-level co-occurrence matrix, quantifies the change in texture patterns before and after style transfer. This indicates whether the texture style has significantly changed. The importance of each texture pattern is adjusted using corresponding weights, thus reflecting the importance of texture in the similarity calculation. Contour structure similarity, on the other hand, measures structural changes in the image by calculating the spatial difference in the target object's contour. This helps detect the impact of style transfer on image shape and structure, balancing the contribution of contour structure to the overall similarity, ensuring that the details of the transferred contour remain consistent with those of the original image. By introducing weights for color entropy similarity, texture pattern frequency similarity, and contour structure similarity, the formula flexibly adjusts the importance of each dimension of features in style transfer according to different application scenarios. For example, in some applications, color changes may be more important than structural changes, while in other applications, the outline and structure of the object are more critical. This formula takes into account three important image feature dimensions (color, texture, and structure) and can comprehensively measure the changes before and after style transfer. This makes this method more effective than traditional methods that only focus on a single feature (such as color or texture) and can evaluate the effect of style transfer at a more detailed level. By integrating the differences in the outline structure of the target object image within the spatial domain, this formula can accurately measure the style transfer effect of the target object at different locations. This spatial domain consideration further enhances the accuracy of the similarity calculation, making it suitable for images with rich details, thereby improving the accuracy and applicability of the similarity calculation formula before and after style transfer.
[0152] Furthermore, the module for measuring the difference between before and after migration includes the following functions:
[0153] The target object image is compared with the pre- and post-style transfer feature similarity based on the preset pre- and post-style transfer similarity threshold (0.9, 1.1). If the pre- and post-style transfer feature similarity of the target object image is within the interval corresponding to the pre- and post-style transfer similarity threshold, it is considered that the target object image has no significant change before and after the style transfer; if the pre- and post-style transfer feature similarity of the target object image is outside the interval corresponding to the pre- and post-style transfer similarity threshold, it is considered that there are feature differences before and after the style transfer of the target object image.
[0154] In an embodiment of the present invention, a pre-set similarity threshold (0.9, 1.1) before and after style transfer is used to compare the feature similarity of the target object image before and after style transfer, thereby determining whether style transfer has caused feature changes in the target object image. First, a convolutional neural network (CNN) is used to extract the deep feature representation of the target object image before and after style transfer. The similarity between the features before and after style transfer is calculated using a preset similarity measurement method (for example, cosine similarity or Euclidean distance). For each pair of images, after calculating the similarity, the value is compared with the preset threshold (0.9, 1.1). If the similarity value is within this range (i.e., between 0.9 and 1.1), it is considered that the features of the target object image before and after style transfer have not changed significantly. If the similarity value exceeds this range, it indicates that the style transfer has caused significant differences in the features of the target object image, and subsequent steps will further process these changes.
[0155] Preferably, deep feature decomposition is performed between the target object and the standard image data corresponding to the feature difference and the image data of the target object after style transfer, so as to use independent component analysis to separate the corresponding target object image into main color, auxiliary color and color deviation components in terms of color, use contourlet transform to decompose the texture features into texture sub-features of different scales and directions in terms of texture, and use shape decomposition to decompose the target object structure into basic geometric shapes in terms of structure, and reconstruct the features of the target object images before and after style transfer based on the decomposed image features to obtain the feature expressions of the target object images before and after style transfer;
[0156] In an embodiment of the present invention, the target object image previously determined to have feature differences is subjected to an in-depth analysis of these feature differences. In terms of color, the independent component analysis (ICA) algorithm is used to decompose the color information of the target object image. By extracting independent components from the image, the ICA algorithm can effectively separate the primary color, secondary color, and color deviation components, thereby providing data support for subsequent color feature analysis. For texture features, the Contourlet Transform is used to perform multi-scale and multi-directional decomposition of the image texture. The Contourlet Transform can decompose the texture features in the image into sub-features of different scales and directions to more accurately capture the local texture information of the image. In terms of structure, a shape decomposition method is used to analyze the geometric structure of the target object and decompose it into basic geometric shapes (such as circles and squares). The structural features are then quantified. These decomposed features are used in subsequent steps for image reconstruction and difference calculation, thereby analyzing the specific impact of style transfer on the target object image and ultimately obtaining the corresponding feature representation of the target object image before and after style transfer.
[0157] Preferably, the style transfer difference measurement is performed on the target object images corresponding to the style transfer before and after the style transfer based on the feature expression of the target object images corresponding to the style transfer before and after the style transfer, so as to calculate the amount of information interaction between the color components before and after the style transfer in terms of color, calculate the complementarity between the texture features of different scales and directions before and after the style transfer in terms of texture, and calculate the shape matching degree between the topological structures before and after the style transfer in terms of structure, and perform a weighted average calculation of the differences based on the amount of information interaction, complementarity and shape matching degree to obtain the difference degree before and after the style transfer corresponding to the target object image.
[0158] In an embodiment of the present invention, the difference in style transfer is measured based on the feature expression of the target object image before and after style transfer. First, in terms of color, the change in color features is evaluated by calculating the mutual information between the color components of the images before and after style transfer. The mutual information measures the correlation between the color components in the two images. A higher mutual information means that the color change before and after style transfer is smaller, and vice versa, it means that the style transfer has caused a larger color change. Second, in terms of texture, a complementary measurement method is used to analyze the complementary relationship between texture features of different scales and directions before and after style transfer. Specifically, by calculating the change in texture features at different scales and directions, The complementarity metric is then used to evaluate the degree to which the transferred texture information complements the original image. Finally, in terms of structure, the shape change of the image before and after style transfer is evaluated by calculating the shape matching degree of the topological structure of the image before and after style transfer. The shape matching degree can be obtained by comparing the geometric shape feature differences of the image before and after style transfer. The mutual information of color, the complementarity of texture and the shape matching degree are weighted averaged to obtain a comprehensive evaluation result of the difference between the target object image before and after style transfer. The higher the difference, the greater the impact of style transfer on the target object image; otherwise, it means that the impact is smaller. Finally, the difference between the target object image before and after style transfer is obtained.
[0159] The present invention is therefore intended to be illustrative and non-restrictive in all respects, with the scope of the invention being defined by the appended claims rather than the foregoing description, and all changes that come within the meaning and range of equivalents of the application documents are intended to be embraced therein.
[0160] The foregoing description is intended only to provide specific embodiments of the present invention, which will enable those skilled in the art to understand and implement the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not intended to be limited to the embodiments shown herein, but is to be construed in the widest possible manner consistent with the principles and novel features disclosed herein.
Claims
1. An image processing measurement system based on edge computing, characterized in that: Includes the following modules: The target image real-time acquisition module is used to arrange edge computing nodes next to the image acquisition device corresponding to the target area, and use the image acquisition device to perform real-time image acquisition of the target object corresponding to the target area by setting corresponding image acquisition parameters to obtain the target object image data and transmit it to the edge computing node; A target object feature measurement module is used to generate target object comparison standard image data by performing image contrast enhancement on the target object image data on the edge computing node; perform target object feature measurement on the target object comparison standard image data to obtain the corresponding target object image measurement features before style transfer; The similarity measurement module before and after migration is used to obtain the reference image data of the target object corresponding to the target area, and perform image style migration on the target object compared with the standard image data based on the reference image data of the target object to obtain the image data of the target object after migration; Based on the measured features of the target object image before style transfer, the similarity measurement of the target object image data after style transfer is performed to obtain the feature similarity before and after style transfer corresponding to the target object image; The module for measuring the difference between the style before and after migration is used to measure the style difference between the target object and the standard image data and the image data after migration of the target object based on the feature similarity before and after the style migration corresponding to the target object image, so as to obtain the difference between the style before and after migration corresponding to the target object image.
2. The image processing measurement system based on edge computing according to claim 1, characterized in that: The target image real-time acquisition module includes the following functions: By arranging corresponding edge computing nodes next to the image acquisition devices corresponding to the target area; Obtaining a corresponding target measurement object and target measurement requirements through a target object in a target area, and appropriately setting acquisition parameters of an image acquisition device based on the target measurement object and target measurement requirements to generate corresponding image acquisition parameters, including resolution, frame rate, and exposure time; Based on the image acquisition parameters, the image acquisition device is started to perform real-time image acquisition of the target object corresponding to the target area to obtain image data of the target object; The target object image data is transmitted to the edge computing node via wireless transmission.
3. The image processing measurement system based on edge computing according to claim 1, characterized in that: The target object feature measurement module includes the following functions: By gray-scaling the target object image data on the edge computing node, gray-scale image data of the target object is obtained; Calculating pixel fuzziness of the grayscale image data of the target object to obtain pixel fuzziness of the target object image; Performing fuzzy noise filtering on the target object image data based on the pixel fuzziness of the target object image to obtain fuzzy denoised image data of the target object; Performing histogram equalization enhancement on the blurred denoised image data of the target object to generate target object contrast standard image data; The target object is compared with the standard image data to measure the target object features and obtain the corresponding target object image measurement features before style transfer, including the image measurement features corresponding to the target image color, texture and structural dimensions.
4. The image processing measurement system based on edge computing according to claim 3, characterized in that: The measuring of target object features by comparing the target object with the standard image data includes: Performing multi-channel separation on the target object image corresponding to the target object comparison standard image data to obtain a multi-channel image of the target object; Based on the multi-channel image of the target object and combined with the principles of physical optics, the color features of the corresponding target object image are quantified to obtain the image measurement features corresponding to the color dimension of the target image, including the Lab color space mean, Lab color space standard deviation and color area distribution ratio corresponding to the target object image; Performing multi-scale texture feature measurement on the target object image corresponding to the target object comparison standard image data, decomposing the target object image into frequency sub-bands at different scales using wavelet transform, and calculating the texture contrast, texture correlation, texture energy and texture entropy features corresponding to the target object image using the gray level co-occurrence matrix at each frequency sub-band to obtain image measurement features corresponding to the texture dimension of the target image; Performing topological geometric structural feature measurement on the target object image corresponding to the target object comparison standard image data, so as to extract the corresponding outline and shape size of the target object from the target object image using morphological operations, calculate the number of connected regions and the number of holes corresponding to the target object using the Euler number in topology, and calculate the center of gravity, principal axis direction and structural degree parameters of the target object, including circularity and rectangularity, using geometric moments to obtain image measurement features corresponding to the structural dimensions of the target image; The image measurement features corresponding to the color, texture and structural dimensions of the target image are weightedly fused before verification to obtain the target object image measurement features corresponding to the style transfer.
5. The image processing measurement system based on edge computing according to claim 4, characterized in that: The target object multi-channel image specifically includes target object images corresponding to the R channel, the G channel, and the B channel.
6. The image processing measurement system based on edge computing according to claim 4, characterized in that: The quantifying of color features of the corresponding target object image based on the multi-channel image of the target object and combining the physical optics principle includes: Based on the multi-channel image of the target object and combined with the principles of physical optics, the corresponding target object image is converted to Lab color space to generate the corresponding target object image in Lab color space, where L represents brightness, and a and b represent the chromaticity corresponding to the color area; Perform color space statistical calculation on the target object image corresponding to the Lab color space to obtain the Lab color space mean and Lab color space standard deviation corresponding to the target object image; The color region distribution of the target object image corresponding to the Lab color space is determined based on the Lab color space mean and the Lab color space standard deviation, so as to obtain the color distribution range corresponding to different color regions in the target object image on the ab plane; The color distribution ratio of the target object image corresponding to the Lab color space is obtained by obtaining the color center coordinate points of different color areas on the ab plane. Based on the color distribution range and color center coordinate points of different color areas on the ab plane, the color distribution ratio of the target object image corresponding to the Lab color space is analyzed to obtain the color area distribution ratio corresponding to the target object image. The Lab color space mean, Lab color space standard deviation, and color area distribution ratio corresponding to the target object image are feature merged to obtain the image measurement features corresponding to the color dimension of the target image.
7. The image processing measurement system based on edge computing according to claim 4, characterized in that: The similarity measurement module before and after migration includes the following functions: Acquire reference image data of the target object corresponding to the target area; Performing consistent target feature measurements on the target object reference image corresponding to the target object reference image data to obtain corresponding image measurement features of the target reference image in color, texture, and structure dimensions; Using edge computing nodes, the image measurement features corresponding to the target reference image in color, texture, and structure dimensions are used to perform image style transfer on the target object image corresponding to the standard image data. The image data of the target object after transfer is obtained based on the computing resources and performance optimization of the edge computing nodes. Re-measure the target object features of the target object image corresponding to the target object image data after the target object is transferred, and obtain the measured features of the target object image corresponding to the style transfer; Based on the measured features of the target object image corresponding to the style transfer before style transfer, the measured features of the target object image corresponding to the style transfer after style transfer are measured to obtain the feature similarity before and after style transfer corresponding to the target object image.
8. The image processing measurement system based on edge computing according to claim 7, characterized in that: The performing similarity measurement before and after style transfer on the measured features of the target object image corresponding to the style transfer based on the measured features of the target object image corresponding to the style transfer comprises: The color distribution information entropy of the image measurement features corresponding to the color dimension before style migration is calculated based on the image measurement features corresponding to the color dimension after style migration, and the color distribution information entropy difference before and after style migration is obtained; Based on the image measurement features corresponding to the texture dimension before style transfer and combined with the gray-level co-occurrence matrix, the texture frequency analysis is performed on the image measurement features corresponding to the texture dimension after style transfer to obtain the texture pattern frequency before and after style transfer. Based on the image measurement features corresponding to the structural dimension before style transfer, the image measurement features corresponding to the structural dimension after style transfer are calculated to obtain the object contour structure similarity index before and after style transfer; Based on the color distribution information entropy difference, texture pattern occurrence frequency and object contour structure similarity index before and after style transfer, the similarity calculation formula before and after style transfer is used to measure the measured features of the target object image before and after style transfer to obtain the feature similarity before and after style transfer corresponding to the target object image.
9. The image processing measurement system based on edge computing according to claim 8, characterized in that: The formula for calculating the similarity before and after style transfer is specifically: Where S is the feature similarity before and after style transfer, ΔH c is the color distribution information entropy difference before and after style transfer, α is the color information entropy similarity weight, n is the total number of texture patterns in the target object image, ΔP i is the frequency of texture pattern occurrence corresponding to the i-th texture pattern in the target object image, β i is the similarity weight of the frequency of occurrence corresponding to the i-th texture pattern in the target object image, Ω is the spatial domain range corresponding to the target object image, x is the spatial domain position parameter, I s (x) is the size of the target object contour structure corresponding to the style transfer at position x, I t (x) is the size of the target object contour structure before style transfer at position x, δ is the object contour structure similarity index, and λ is the contour structure similarity weight.
10. The image processing measurement system based on edge computing according to claim 1, characterized in that: The module for measuring the difference between before and after migration includes the following functions: The target object image is compared with the pre- and post-style transfer feature similarity based on the preset pre- and post-style transfer similarity threshold (0.9, 1.1). If the pre- and post-style transfer feature similarity of the target object image is within the range corresponding to the pre- and post-style transfer similarity threshold, it is considered that the target object image has no significant change before and after the style transfer. If the feature similarity before and after the style transfer of the target object image is outside the interval corresponding to the similarity threshold before and after the style transfer, it is considered that there is a feature difference between the target object image before and after the style transfer; Perform deep feature decomposition on the target object with feature differences compared to the standard image data and the image data after style transfer. In terms of color, independent component analysis is used to separate the main color, auxiliary color, and color deviation components of the corresponding target object image. In terms of texture, contourlet transform is used to decompose the texture features into texture sub-features of different scales and directions. In terms of structure, shape decomposition is used to decompose the target object structure into basic geometric shapes. Based on the decomposed image features, the features of the target object images before and after style transfer are reconstructed to obtain the feature expressions of the target object images before and after style transfer. Based on the feature expression of the target object image before and after style transfer, the style transfer difference of the target object image before and after style transfer is measured to calculate the information interaction between the color components before and after style transfer in terms of color, calculate the complementarity between texture features of different scales and directions before and after style transfer in terms of texture, and calculate the shape matching between the topological structures before and after style transfer in terms of structure. A weighted average calculation of the differences is performed based on the information interaction, complementarity and shape matching to obtain the difference before and after style transfer corresponding to the target object image.
Citation Information
Cited By
Diffusion style migration method and system based on subsurface distribution reanchoring dynamic injection
CN121481829A
Device and method for quickly positioning fire source point of long and narrow tunnel
CN121861123A