Vision and Frequency-Based Transmission Function Design Method, Device, Equipment and Medium

Through the combination of visual and frequency characteristics, the frequency and visual characteristics of volume data are extracted, and the distribution of transmission functions is generated using key equal values, the problems of low efficiency and insufficient generalization ability of transmission functions in volume data visualization are solved, and more efficient and good quality transmission function design is achieved.

CN120047596BActive Publication Date: 2025-06-20CALCULATION AERODYNAMICS INST CHINA AERODYNAMICS RES & DEV CENT
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510518330.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-24
Publication Date
2025-06-20
Estimated Expiration
2045-04-24

AI Technical Summary

Technical Problem

The prior art has low efficiency in the design of transmission functions in volume data visualization, and lacks the ability to generalize different volume data.

Method used

The transmission function design method based on vision and frequency is adopted. By dividing the volume data into scalar value sub-intervals and projecting it into a two-dimensional space based on the number of voxels, frequency characteristics and visual characteristics are extracted, and the one-dimensional transmission function is distributed in combination with key equal values.

Benefits of technology

It improves the efficiency and quality of transmission function design, enhances feature recognition and noise resistance, and improves the generalization ability of different volume data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120047596B_ABST
    Figure CN120047596B_ABST
Patent Text Reader

Abstract

The present application discloses a method, apparatus, device and medium for designing a transfer function based on vision and frequency, which relates to the field of visualization technology, and includes: projecting each scalar value sub-interval of the volume data in the form of scatter points onto a first preset two-dimensional space to obtain a frequency feature image; traversing the midpoints of each scalar value sub-interval in the frequency feature image to extract the contour image of the isosurface image of the corresponding isovalue point; calculating the similarity index between any two adjacent contour images and projecting it onto a second preset two-dimensional space in the form of scatter points to obtain a visual feature image; performing point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet the preset isovalue conditions to obtain a target transfer function. In this way, the present application separately processes the frequency feature, visual feature and key isovalue of the scalar value sub-interval of the volume data, which can enhance the feature recognition and improve the design efficiency and quality of the transfer function.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of visualization technology, and particularly to a method, device, equipment and medium for designing a transfer function based on vision and frequency. Background Art

[0002] In order to improve the efficiency of transfer function design in volume data visualization, the commonly used methods currently include: 1. Providing interactive guidance for users through a visibility histogram to better design the transfer function; in this method, the computational time cost of the visibility histogram is relatively large, and only visibility guidance is provided. 2. Using a Gaussian mixture model to explore volume data, this method relies on the clustering results of the Gaussian mixture model in a two-dimensional feature space (such as scalar value and gradient magnitude) to perform initial feature separation on volume data, which makes the method have general effects in the case where the two-dimensional feature space distribution results of some data sets are chaotic. 3. Performing feature segmentation by calculating the similarity index of isosurfaces in space for clustering and using feature visibility to achieve interactive guidance; in this method, the time required for calculating the similarity index of isosurfaces and the clustering algorithm is relatively large, and the noise problem caused by some key isosurfaces is not considered. 4. Helping users explore the design space of the transfer function by using deep learning and differentiable rendering; this method requires a ground truth, that is, a well-tuned transfer function to train the neural network, and the images generated by the neural network may have errors, and the effects on data sets with many fine features are generally average.

[0003] Therefore, how to design a volume rendering transfer function and improve the generalization ability for different volume data is a problem to be solved in this field. Summary of the Invention

[0004] In view of this, the purpose of the present invention is to provide a method, device, equipment and storage medium for designing a transfer function based on vision and frequency, which respectively process the frequency characteristics, visual characteristics and key isosurfaces of volume data, avoid the chaotic situation that occurs when directly projecting volume data, and can enhance feature recognition by generating the distribution points of the transfer function through an algorithm. The specific solutions are as follows:

[0005] In a first aspect, the present application provides a method for designing a transfer function based on vision and frequency, including:

[0006] Dividing the volume data into several scalar value sub-intervals, and projecting each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the number of voxels to obtain a frequency characteristic image corresponding to the volume data;

[0007] Traversing the midpoints of each of the scalar value sub-intervals in the frequency characteristic image to extract a contour image of the isosurface image of the isosurface points corresponding to the midpoints;

[0008] Calculate the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and project the calculated similarity indices in the form of scatter points onto a second preset two-dimensional space to obtain the visual feature image corresponding to the volume data;

[0009] Based on the frequency feature image, the visual feature image, and key isovalues that meet the preset isovalue conditions, perform point distribution processing on a one-dimensional transfer function to obtain the target transfer function corresponding to the volume data; the key isovalues are isopoints in the two-dimensional space constructed based on the frequency feature image and the visual feature image.

[0010] Optionally, the projecting each of the scalar value sub-intervals in the form of scatter points onto a first preset two-dimensional space based on the number of voxels includes:

[0011] Count the number of voxels in each of the scalar value sub-intervals to obtain a frequency feature;

[0012] Project each of the scalar value sub-intervals in the form of scatter points onto the first preset two-dimensional space based on the frequency feature; the first preset two-dimensional space is a two-dimensional space constructed according to the midpoint of the scalar value sub-interval and the corresponding frequency feature.

[0013] Optionally, the projecting each of the scalar value sub-intervals in the form of scatter points onto a first preset two-dimensional space to obtain the frequency feature image corresponding to the volume data includes:

[0014] Project each of the scalar value sub-intervals in the form of scatter points onto the first preset two-dimensional space based on the number of voxels, and determine the gradient change situation of adjacent scatter points in the first preset two-dimensional space through a preset frequency feature region segmentation algorithm based on gradient change;

[0015] Determine extreme points and corresponding boundary points from the first preset two-dimensional space based on the gradient change situation, and use the extreme points and the corresponding boundary points to divide the scatter points in the first preset two-dimensional space to obtain the frequency feature image corresponding to the volume data.

[0016] Optionally, the traversing the midpoints of each of the scalar value sub-intervals in the frequency feature image to extract the contour image of the isosurface image corresponding to the isopoint corresponding to the midpoint includes:

[0017] Traverse the midpoints of each scalar value sub-interval in the frequency feature image through a preset isosurface extraction algorithm to extract the isosurface of the corresponding isopoint according to the midpoint to obtain an isosurface image;

[0018] Convert the isosurface image into a grayscale image, and perform contour extraction on the grayscale image to obtain the contour image corresponding to the isosurface image.

[0019] Optionally, calculating the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and projecting a plurality of calculated similarity indices in the form of scatter points onto a second preset two-dimensional space to obtain a visual feature image corresponding to the volume data, includes:

[0020] Calculating the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and performing mean smoothing processing on the corresponding calculation results to obtain a plurality of similarity indices;

[0021] Projecting the plurality of similarity indices in the form of scatter points onto a second preset two-dimensional space, and dividing the sparsity degree of the scatter point distribution in the second preset two-dimensional space through a preset visual feature region segmentation algorithm to obtain a visual feature image corresponding to the volume data; the second preset two-dimensional space is a two-dimensional space constructed based on the midpoint of the scalar value sub-interval and the corresponding similarity index.

[0022] Optionally, performing point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet preset isovalue conditions to obtain a target transfer function corresponding to the volume data, includes:

[0023] Normalizing the similarity index and the frequency feature, and projecting the normalization result onto a target two-dimensional space constructed based on the visual feature and the frequency feature;

[0024] Determining a plurality of isovalue points in the target two-dimensional space as key isovalues based on the preset isovalue conditions, and performing point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key isovalues to obtain a target transfer function corresponding to the volume data.

[0025] Optionally, performing point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet preset isovalue conditions to obtain a target transfer function corresponding to the volume data, includes:

[0026] Performing point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet preset isovalue conditions to obtain an initial transfer function corresponding to the volume data;

[0027] Modifying the frequency feature image and / or the visual feature image and / or the key isovalues and / or the initial transfer function based on an interaction instruction, and finally obtaining a target transfer function, so as to perform visualization processing on the volume data by using the target transfer function to obtain a corresponding visualization image.

[0028] In a second aspect, the present application provides a transmission function design device based on vision and frequency, including:

[0029] A frequency feature projection module, configured to divide the volume data into a plurality of scalar value sub-intervals, and project each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the number of voxels, so as to obtain a frequency feature image corresponding to the volume data;

[0030] A contour image extraction module, configured to traverse the midpoints of each of the scalar value sub-intervals in the frequency feature image, so as to extract a contour image of an isosurface image of an isovalue point corresponding to the midpoint;

[0031] A point distribution module, configured to perform point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet a preset isovalue condition, so as to obtain a target transfer function corresponding to the volume data; the key isovalues are isovalue points in a two-dimensional space constructed based on the frequency feature image and the visual feature image.

[0032] In a third aspect, the present application provides an electronic device, including:

[0033] A memory, configured to store a computer program;

[0034] A processor, configured to execute the computer program to implement the above-mentioned transmission function design method based on vision and frequency.

[0035] In a fourth aspect, the present application provides a computer-readable storage medium, configured to store a computer program, and when the computer program is executed by a processor, the above-mentioned transmission function design method based on vision and frequency is implemented.

[0036] It can be seen that in this application, the volume data is first divided into several scalar value sub-intervals, and each of the scalar value sub-intervals is projected onto a first preset two-dimensional space in the form of scatter points based on the number of voxels to obtain the frequency feature image corresponding to the volume data; then, the midpoints of each of the scalar value sub-intervals in the frequency feature image are traversed to extract the contour image of the isosurface image of the isovalue points corresponding to the midpoints; then, the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals is calculated, and the calculated several similarity indices are projected onto a second preset two-dimensional space in the form of scatter points to obtain the visual feature image corresponding to the volume data; then, based on the frequency feature image, the visual feature image, and the key isovalues that meet the preset isovalue conditions, the one-dimensional transfer function is distributed to obtain the target transfer function corresponding to the volume data; the key isovalues are the isovalue points in the two-dimensional space constructed based on the frequency feature image and the visual feature image. In this way, in this application, the frequency feature and the visual feature corresponding to the volume data are processed separately, and then the frequency feature and the visual feature are projected onto a two-dimensional space to obtain the key isovalues, and then the frequency feature, the visual feature, and the key isovalues are used to generate the distribution of the one-dimensional transfer function through an algorithm to obtain the corresponding target transfer function; in this way, the frequency feature, the visual feature, and the key isovalues of the volume data are processed separately, avoiding the chaotic situation that occurs when directly projecting the volume data onto a two-dimensional space, and being able to enhance the feature recognition and anti-noise capabilities, and improve the design efficiency and quality of the transfer function. Description of the Drawings

[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present invention, and for those of ordinary skill in the art, other drawings can be obtained according to the provided drawings without creative efforts.

[0038] Figure 1 Flowchart of a method for designing a transfer function based on vision and frequency disclosed in this application;

[0039] Figure 2 Flowchart of a specific method for designing a transfer function based on vision and frequency disclosed in this application;

[0040] Figure 3 A specific frequency feature image after region segmentation disclosed in this application;

[0041] Figure 4 A specific visual feature image after region segmentation disclosed in this application;

[0042] Figure 5A specific two-dimensional space schematic diagram constructed based on visual features and frequency features disclosed in this application;

[0043] Figure 6 A specific flowchart for extracting frequency features and feature region segmentation disclosed in this application;

[0044] Figure 7 A specific flowchart for extracting visual features and feature region segmentation disclosed in this application;

[0045] Figure 8 A specific flowchart for extracting key equivalent values and generating one-dimensional transfer function layout points disclosed in this application;

[0046] Figure 9 A schematic diagram of the structure of a transfer function design device based on vision and frequency disclosed in this application;

[0047] Figure 10 A structural diagram of an electronic device disclosed in this application. Specific implementation manners

[0048] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0049] See Figure 1 As shown, an embodiment of the present invention discloses a method for designing a transfer function based on vision and frequency, including:

[0050] Step S11: Divide the volume data into several scalar value sub-intervals, and project each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the number of voxels, so as to obtain a frequency feature image corresponding to the volume data.

[0051] It can be understood that the volume data is a data set composed of voxels in a three-dimensional space, usually generated by scanning or simulating a three-dimensional object, such as computer tomography or magnetic resonance imaging data in medical imaging, and fluid or thermodynamic simulation data in scientific computing and engineering simulation. During the visualization process of this application for these volume data, the scalar values of the volume data are divided into several equidistant scalar value sub-intervals; it can be understood that each scalar value sub-interval corresponds to several voxels, and the number of voxels is regarded as the frequency feature of the scalar value sub-interval; then these scalar value sub-intervals are projected onto a first preset two-dimensional space in the form of scatter points, so that a frequency feature image corresponding to the volume data can be obtained.

[0052] In a specific embodiment, the projecting each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the number of voxels may include: counting the number of voxels in each of the scalar value sub-intervals to obtain a frequency feature; projecting each of the scalar value sub-intervals onto the first preset two-dimensional space in the form of scatter points based on the frequency feature; the first preset two-dimensional space being a two-dimensional space constructed according to the midpoint of the scalar value sub-interval and the corresponding frequency feature. Specifically, first, count the number of voxels in each scalar value sub-interval to obtain the frequency feature corresponding to each scalar value sub-interval respectively; then project a single scalar value sub-interval onto the first preset two-dimensional space in the form of scatter points based on the interval midpoint of the single scalar value sub-interval and the corresponding frequency feature. In a specific embodiment, the abscissa and ordinate of the first preset two-dimensional space here are respectively the midpoint of the scalar value sub-interval and the logarithm of the frequency feature corresponding to the interval, and finally a frequency feature image is projected.

[0053] In another specific embodiment, the projecting each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points to obtain the frequency feature image corresponding to the volume data may include: projecting each of the scalar value sub-intervals onto the first preset two-dimensional space in the form of scatter points based on the number of voxels, and determining the gradient change situation of adjacent scatter points in the first preset two-dimensional space by a preset frequency feature region segmentation algorithm based on gradient change; determining extreme points and corresponding boundary points from the first preset two-dimensional space based on the gradient change situation, and using the extreme points and the corresponding boundary points to perform region division on the scatter points in the first preset two-dimensional space to obtain the frequency feature image corresponding to the volume data. Specifically, project the scalar value sub-intervals onto the first preset two-dimensional space in the form of scatter points according to the number of voxels in each scalar value sub-interval, and further, the gradient change situation of each scatter point in the first preset two-dimensional space can be determined. Determine the gradient change situation of each adjacent scatter point by a preset frequency feature region segmentation algorithm based on gradient change to determine whether a certain scatter point is an extreme point, and then use the extreme point and the corresponding boundary point to perform region division on the scatter points in the first preset two-dimensional space, and a frequency feature image after region division can be obtained. The frequency feature image after region division is as follows Figure 2 shown.

[0054] Step S12: Traverse the midpoints of each of the scalar value sub-intervals in the frequency feature image to extract the contour image of the isosurface image of the isosurface points corresponding to the midpoints.

[0055] In the embodiments of the present application, after obtaining the frequency feature image, the midpoints of each scalar value sub-interval in the frequency feature image can be traversed, the isosurfaces corresponding to the isopoints can be extracted, and the corresponding isosurface images can be rendered, and then the contour image of the isosurface image can be extracted. In a specific embodiment, the traversing the midpoints of each scalar value sub-interval in the frequency feature image to extract the contour image of the isosurface image corresponding to the midpoint may include: traversing the midpoints of each scalar value sub-interval in the frequency feature image through a preset isosurface extraction algorithm to extract the isosurface corresponding to the midpoint according to the midpoint to obtain an isosurface image; converting the isosurface image into a grayscale image, and performing contour extraction on the grayscale image to obtain the contour image corresponding to the isosurface image. Specifically, the midpoints of each scalar value sub-interval in the frequency feature image can be traversed through a preset isosurface extraction algorithm, such as performing isosurface extraction through Marching Cubes (for structured grids) or Marching Tetrahedra (for unstructured grids), and then rendering to obtain the corresponding isosurface image; further, in the process of contour extraction, first convert the isosurface image into a grayscale image, and then the edge extraction algorithm can be used for contour extraction to obtain the contour image corresponding to the isosurface image.

[0056] Step S13: Calculate the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and project the calculated similarity indices in the form of scatter points onto a second preset two-dimensional space to obtain the visual feature image corresponding to the volume data.

[0057] Furthermore, in order to obtain the visual features of the volume data, after obtaining a plurality of contour images, the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals can be calculated, and the similarity index is the SSIM value (Structural Similarity); then project the similarity index in the form of scatter points onto a second preset two-dimensional space, and the visual feature image corresponding to the volume data can be obtained.

[0058] In a specific embodiment, calculating the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and projecting the calculated similarity indices in the form of scatter points onto a second preset two-dimensional space to obtain the visual feature image corresponding to the volume data may include: calculating the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and performing mean smoothing processing on the corresponding calculation results to obtain a plurality of similarity indices; projecting the plurality of similarity indices in the form of scatter points onto the second preset two-dimensional space, and dividing the sparsity degree of the scatter point distribution in the second preset two-dimensional space through a preset visual feature region segmentation algorithm to obtain the visual feature image corresponding to the volume data; the second preset two-dimensional space is a two-dimensional space constructed based on the midpoint of the scalar value sub-interval and the corresponding similarity index. Specifically, calculating the similarity index between two contour images corresponding to any adjacent scalar value sub-intervals, and it is necessary to perform mean smoothing processing on the corresponding calculation results to reduce noise, and finally a plurality of similarity indices can be obtained; then using the midpoint of the interval as the abscissa and the finally obtained similarity index as the ordinate, and projecting in the form of scatter points onto the second preset two-dimensional space. Further, according to the distribution of the scatter points in this two-dimensional space, the region can be divided through a preset visual feature region segmentation algorithm. Specifically, it can be divided into a sparse set and a dense set, and the visual feature region is segmented with the corresponding demarcation point, and finally the visual feature image after region division can be obtained. The visual feature image after region division is as follows Figure 3 as shown

[0059] Step S14: Based on the frequency feature image, the visual feature image, and the key isosurfaces that meet the preset isosurface conditions, perform point distribution processing on the one-dimensional transfer function to obtain the target transfer function corresponding to the volume data; the key isosurfaces are the isosurface points in the two-dimensional space constructed based on the frequency feature image and the visual feature image.

[0060] In the embodiment of the present application, after obtaining the frequency feature image and the visual feature image corresponding to the volume data through the above steps, a new two-dimensional space can be constructed based on the frequency feature and the visual feature therein, and the key isosurfaces can be screened out from this two-dimensional space through the preset isosurface conditions; then, based on the frequency feature image, the visual feature image, and the key isosurfaces that meet the preset isosurface conditions, perform point distribution processing on the one-dimensional transfer function, so that the target transfer function corresponding to the volume data can be obtained.

[0061] In a specific embodiment, the process of performing point distribution processing on the one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equal-value pairs that meet the preset equal-value conditions to obtain the target transfer function corresponding to the volume data may include: normalizing the similarity index and the frequency feature, and projecting the normalization result onto a target two-dimensional space constructed based on visual features and frequency features; determining several equal-value points in the target two-dimensional space as key equal-values based on the preset equal-value conditions, and performing point distribution processing on the one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equal-values to obtain the target transfer function corresponding to the volume data. Specifically, first, normalize the frequency feature corresponding to the frequency feature image (the number of voxels in each scalar value sub-interval) and the visual feature corresponding to the visual feature image (similarity index) to obtain the normalization result, that is, the two normalized features; then project the normalization result onto a two-dimensional space, specifically, constructing a two-dimensional space with the similarity index as the abscissa and the frequency as the ordinate; in this two-dimensional space, equal-values can be screened through preset equal-value conditions, such as screening the equal-values corresponding to the scattered points within a certain range in the upper left corner, and screening to obtain the key equal-values that meet the preset equal-value conditions; the two-dimensional space constructed based on visual features and frequency features is as Figure 4 shown. Subsequently, point distribution processing can be performed on the control points of the one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equal-values, so as to finally obtain the target transfer function corresponding to the volume data through point distribution.

[0062] In another specific embodiment, the process of using the frequency feature image, the visual feature image, and the key equal-values to perform point distribution processing on the one-dimensional transfer function to obtain the target transfer function corresponding to the volume data may include: performing point distribution processing on the one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equal-values to obtain the initial transfer function corresponding to the volume data; modifying the frequency feature image and / or the visual feature image and / or the key equal-values and / or the initial transfer function based on an interaction instruction, and finally obtaining the target transfer function, so as to use the target transfer function to perform visualization processing on the volume data to obtain the corresponding visualization image. Specifically, during the process of obtaining the initial transfer function corresponding to the volume data through an algorithm, relevant personnel can intervene in the data during the process by means of a human-computer interaction interface, issue an interaction instruction, and modify the frequency feature image and / or the visual feature image and / or the target two-dimensional space and / or the generated point distribution during the process to generate the target transfer function that meets the expectations of relevant personnel. Further, the target transfer function obtained through the final interaction can be used to perform visualization processing on the corresponding volume data, and then the visualization image corresponding to the volume data can be obtained.

[0063] It can be seen that in this application, instead of directly counting the feature information of each voxel in the volume data, the feature information is counted in units of equal-value intervals (equal-value points), reducing the amount of data and thus accelerating the speed of feature extraction. After separately calculating the frequency information of the volume data and the visual information of the extracted isosurface, instead of directly projecting the two types of features into a subspace for clustering and then dividing the feature regions, the two types of feature information are separately divided into feature regions, and then the frequency information and the visual information are projected into a two-dimensional space to obtain the key isovalue. Finally, the distribution points of the one-dimensional transfer function are generated through an algorithm using the divided frequency feature intervals, visual feature intervals, and key isovalue, obtaining the target transfer function. This effectively accelerates the speed of dividing the feature regions and enhances the feature recognition and anti-noise capabilities.

[0064] As Figure 5 shown, the embodiment of this application discloses a method for designing a transfer function based on vision and frequency, which specifically includes:

[0065] In this embodiment, 1. Extract the frequency features of the volume data and segment the feature regions. Specifically, the scalar values of the volume data are divided into multiple equally spaced scalar value sub-intervals, and the number of voxels with scalar values in each sub-interval of the volume data is counted. Then, the statistical results (frequency features) are projected onto the scalar value-frequency two-dimensional space in the form of scatter points. Then, the frequency feature region segmentation algorithm (Algorithm 1 introduced below) is used to segment the frequency features projected onto the two-dimensional space to obtain the frequency feature regions, and a frequency feature segmentation image (i.e., the frequency feature image segmented by regions in the above embodiment) is generated. 2. Extract the visual features of the volume data and segment the feature regions. Specifically, the midpoint of each scalar value sub-interval is traversed in sequence, and the isosurface corresponding to the isovalue point is extracted and rendered to obtain an isosurface image. Then, the isosurface image is converted into a grayscale image, and then the contour is extracted to obtain an isosurface contour image. Next, the structural similarity index (visual feature) between the two consecutive isosurface contour images is calculated. After that, the calculated ssim value (structural similarity index) is first smoothed by the mean, and then projected onto the scalar value-ssim value two-dimensional space in the form of scatter points. The visual feature region segmentation algorithm (Algorithm 2 introduced below) is used to segment the regions to obtain the visual feature regions and generate a visual feature segmentation image (i.e., the visual feature image segmented by regions in the above embodiment). 3. Extract the key isovalues and generate the one-dimensional transfer function points. Specifically, after normalizing the frequency features and visual features, they are projected onto the two-dimensional space with the visual features as the abscissa and the frequency features as the ordinate, and the key isovalues are obtained by specifying the threshold. Then, the visual feature regions, frequency feature regions, and the key isovalue array are used to generate the one-dimensional transfer function control points by the one-dimensional transfer function point generation algorithm (Algorithm 3 introduced below). 4. Generate the visualization image under the interactive guidance of relevant personnel. Specifically, an interactive frequency segmentation image, visual segmentation image, and visual-frequency projection image are generated. The user can directly control the segmentation results and the selection of key isovalues by interacting with the images. And the one-dimensional transfer function control points generated by the user interaction can be used to generate a one-dimensional transfer function that meets the user's expectations, so as to finally generate the visualization image corresponding to the volume data.

[0066] Specifically, as Figure 6The following shows the process of extracting frequency features and segmenting feature regions. First, the frequency feature extraction process will be carried out; in this process, the scalar values are first divided into multiple equal-value intervals according to the interval length d, and then the number of voxels in each equal-value interval is statistically analyzed to obtain the frequency features. Then, with the midpoint of the equal-value interval as the abscissa and the logarithm of the interval frequency as the ordinate, the frequency features are projected onto a two-dimensional space in the form of scatter points, and a frequency feature image will be generated. Users can repeatedly optimize the parameter d through the image to achieve a better frequency feature extraction effect until the generated frequency feature image meets the user's expectations. Then, the frequency feature region segmentation is carried out; after the frequency features are extracted, the frequency feature region segmentation algorithm based on gradient change (Algorithm 1) will be used for frequency feature region segmentation. The frequency feature region segmentation algorithm based on gradient change first determines whether a certain scatter point is an extreme point according to the gradient change of adjacent scatter points. If the slopes of n consecutive scatter points after a certain point become smoother than the slope of the previous scatter point, then this point is considered an extreme point; then it is further determined whether the slope of the straight line between this point and the previous extreme point and the slope of the straight line between this point and the nth scatter point after it are first positive and then negative to determine whether it is a maximum point. After all extreme points are extracted, the frequency features are segmented according to the maximum points and the boundaries, where the parameter n controls the sensitivity of the algorithm to extreme points. The larger the parameter n, the less sensitive to extreme points, but the stronger the anti-noise ability. The smaller n is, the more sensitive to extreme points, but the weaker the anti-noise ability. After the frequency feature region segmentation, a frequency feature region segmentation image will be generated. This image further marks the frequency segmentation information on the basis of the frequency feature image. Users can repeatedly optimize the parameter n through the image to achieve a better frequency feature segmentation effect until the generated frequency feature region segmentation image meets the user's expectations.

[0067] Among them, Algorithm 1 is the frequency feature region segmentation algorithm based on gradient change: this algorithm transforms the problem of frequency feature region division into the problem of finding the maximum points of the scatter point projection of the frequency features in a two-dimensional space with the midpoint of the equal-value interval as the abscissa and the frequency as the ordinate. The extreme points are found by using the continuous change of the gradient between scatter points, and then it is determined whether it is a maximum point by judging the slope change trend between the scatter points before and after the extreme point. This algorithm has high versatility and fast speed. The time complexity of the algorithm is O(n), where n is the number of equal-value intervals. The specific steps are as follows:

[0068] Step1. Initialize the parameter n, the frequency feature array F, the extreme point array A = [0], the maximum value array B = [0], the subscript record of the initially smooth point = -1, and the number of continuously smooth scatter points count = 0.

[0069] Step2. Traverse the array F from i = 1, and compare the absolute values of the slopes k1 between the frequency F[A[lastIndex]] of the last element in array A and F[i], and k2 between F[i - 1] and F[A[lastIndex]] (that is, determine whether the slope becomes smooth).

[0070] Step3. If the slope becomes smooth, increment count by 1. If the slope becomes non - smooth, set count to 0 and continue. If it just starts to become smooth (record = -1?), record the point where it starts to be smooth as the pending extreme point record = i.

[0071] Step4. If n consecutive scatter points all become smooth, that is, count == n, then calculate and compare the slope change between the slope k3 between points F[A[lastIndex]] and F[record] and the distance k4 between points F[record] and F[record + n] to determine whether it is a maximum value. If it is a maximum value, add it to the maximum value array B, and add it to the extreme value array A regardless of whether it is a maximum value. Set the traversal subscript i to record + 1, set count to 0, and set record to -1.

[0072] Step5. Repeat Step2, Step3, and Step4 until the frequency feature array is traversed. Add the boundaries of array F, that is, F[0] and F[lastIndex], to array B as the final frequency division point array.

[0073] Specifically, such as Figure 7The following is the process of extracting visual features and segmenting feature regions. After completing the frequency feature region segmentation, the visual feature extraction process will be carried out first. In this process, the isosurface extraction algorithms Marching Cubes or Marching Tetrahedra can be used to extract the isosurfaces successively according to the midpoints of the frequency feature isovalue intervals, and then render images of the isosurfaces are extracted from the perspective of the direction v of the two largest dimensions of the volume data facing the center point of the volume data. For the images of the isosurfaces extracted for each midpoint value, they are converted into grayscale images and the canny algorithm (a widely used edge extraction algorithm) is used for contour extraction to obtain contour images, and the ssim values between the current contour image and the next contour image are calculated successively to obtain visual features. During this period, the rendered images of the isosurfaces generated successively according to the midpoints of the frequency feature isovalue intervals will be made into an animation, and the user can adjust the perspective v according to this animation to obtain better visual information extraction results. In the case where the differences in the three dimensions of the volume data are large, the user generally does not need to adjust the parameter v. However, in the case where the differences in the dimensions of the volume data are small or even non-existent (such as 256x256x254), the user may need to adjust the parameter v by observing the animation to obtain better visual information extraction. The perspective v can interrupt the animation and be adjusted at any time without waiting for the animation rendering to end. Then visual feature segmentation is carried out. After the visual features are extracted, the visual feature region segmentation algorithm based on sparse clustering (Algorithm 2) will be used to segment the visual feature regions. This algorithm first performs mean smoothing on the extracted visual features to reduce noise, and then projects the visual features onto a two-dimensional space in the form of scatter points with the midpoint of the isovalue interval as the abscissa and the smoothed ssim value as the ordinate. According to the different degrees of sparsity of the scatter points distributed in the two-dimensional space, the sparse clustering method is used to classify the scatter points into sparse sets and dense sets, and the parameter p is used to achieve the division of the sparse sets and dense sets, indicating that the density before p% is the dense set, and vice versa is the sparse set. After the sparse classification is completed, the demarcation points of the sparse set and the sparse-dense set are extracted to segment the visual feature regions, and a visual feature region segmentation image is generated. The user can repeatedly optimize the parameter p through the image to achieve a better visual feature segmentation effect until the generated visual feature segmentation image meets the user's expectations.

[0074] Among them, Algorithm 2 is a visual feature region segmentation algorithm based on sparse clustering. This algorithm transforms the problem of visual feature region division into the problem of finding the inflection points of the scatter point projection of visual features in a two-dimensional space with the midpoint of the isovalue interval as the abscissa and the structural similarity index of the isosurface contour image as the ordinate. The scatter points are divided into dense sets and sparse sets according to the degree of sparsity of the scatter points in the two-dimensional space, and then the inflection points are found through the boundary between the two sets. The time complexity of this algorithm is O(n^2), but since n here is the number of isovalue intervals rather than voxels, the time efficiency of this algorithm is still very fast. The specific steps are as follows:

[0075] Step1. Initialize parameter p, initialize the partition point array A as empty, and V as the visual feature array, which is obtained from the visual information extraction process.

[0076] Step2. Perform mean smoothing on the visual feature array V, and set the mean interval to 6. Then normalize it in the two-dimensional space to obtain the two-dimensional array X, where the first dimension is the scalar value of the equal value points, and the second dimension is the ssim value.

[0077] Step3. Copy n elements from the head and tail of the array X to reduce the influence of the boundary on density classification. Generally, n is set to 4.

[0078] Step4. Perform density-based clustering on the array X, and generally set the neighboring elements to 9 to obtain the sparse set S and the dense set D, and use the parameter p to control the ratio of the sparse set and the dense set.

[0079] Step5. Traverse the dense set D. If the equal values of two adjacent elements are not adjacent (i.e., D[i + 1,0] - D[i,0] > 2d), then add this point and the next point to the partition point array A.

[0080] Step6. If the head and tail elements of X are not in A, then add the head and tail elements of X to A. A is the final visual area partition point array.

[0081] Specifically, such as Figure 8The figure shows the process of extracting key isosurfaces and generating one-dimensional transfer function sampling points. After obtaining the frequency features and visual features, these two types of features will be used to obtain key isosurfaces. The specific method is to normalize these two types of features, and then use the ssim value as the abscissa and the frequency as the ordinate to project them into the two-dimensional space in the form of scatter points. In this visual-frequency projection space, the closer the scatter point is to the upper left corner, the more important the corresponding isosurface is. Users can click to select scatter points or set the ssim threshold and frequency threshold to update the corresponding isosurfaces into the one-dimensional transfer function sampling points in real time, which can be removed or added to obtain a better volume rendering effect. Then, one-dimensional transfer function sampling point generation is performed; after frequency feature region segmentation, visual feature region segmentation, and key isosurface extraction, the segmentation information of the obtained visual and frequency features and the key isosurface information will be used to generate one-dimensional transfer function sampling points using the one-dimensional transfer function sampling point generation algorithm (Algorithm 3). This algorithm divides the sampling points in the one-dimensional transfer function into fixed points and variable points. The fixed points are used to fix the boundaries of the features, and the variable points are used to control the transparency of the features. The advantage of this is that it can isolate the influence of the transparency change of a certain feature on other features. The variable points are composed of the midpoints of the visual feature region segmentation regions, the midpoints of the frequency feature region segmentation regions, and the key isosurface points; the fixed points are composed of the visual feature division points, the frequency feature division points, and two adjacent points of the key isosurface. The adjacent points depend on the parameter d in the frequency feature extraction, that is, the key isosurface point plus or minus the parameter d. The transparency of the fixed points is defaulted to 0, and the transparency of the variable points is defaulted to 0.5.

[0082] Among them, Algorithm 3 is the one-dimensional transfer function sampling point generation algorithm. This algorithm divides the sampling points in the one-dimensional transfer function into fixed points and variable points, and uses the frequency feature region, visual feature region, and key isosurface of the data to generate fixed points and variable points. This algorithm has a fast execution time and a time complexity of O(nlogn). The specific steps are as follows:

[0083] Step1. Initialize arrays V, F, K, A, and B. Among them, V is the visual feature division point array, F is the frequency feature division point array, K is the key point array, and A and B are empty intermediate arrays.

[0084] Step2. Merge the visual feature division point array V and the frequency feature division point array F into the frequency-visual division point array FV.

[0085] Step3. Traverse the key point array K, and take K[i]+d and K[i]-d into the intermediate array A.

[0086] Step4. Merge, de-duplicate, and sort the intermediate array K and the frequency-visual division point array A as the fixed point array.

[0087] Step5. Traverse the frequency visual division points FV, and add the midpoint of FV[i] and FV[i+1] to the intermediate array B.

[0088] Step6. Merge, de-duplicate, and sort the intermediate array B and the key point array K to form the variable point array.

[0089] Specifically, after generating the distribution points of the one-dimensional transfer function, the transfer function interaction guidance aims to meet the needs of users who may need to further explore the characteristics of the volume data or modify the distribution points of the transfer function. In this step, this embodiment will provide users with visual information interaction guidance, frequency information interaction guidance, and key isosurface interaction guidance. These interaction guidances are presented to users in the form of interactive images. The interaction guidance is initialized as a visual feature region segmentation map, a frequency feature region segmentation map, and a visual-frequency scatter plot. Without changing the core parameters d and v, users can update the distribution points of the generated one-dimensional transfer function in real time by interacting with the segmentation of the two segmentation maps and selecting the visual-frequency scatter plot. Moreover, after generating the control points (fixed points and variable points) of the one-dimensional transfer function, users can only control the transparency and color of the variable points through the transfer function editor and then repeatedly optimize by observing the changes in the volume visualization image with the naked eye. Each variable point represents a feature, and the adjustment of the transparency of each variable point will not affect other features. This transfer function interaction process greatly improves the efficiency of transfer function design.

[0090] It can be seen that the segmentation of the characteristics of the volume data in this application depends on the three attribute characteristics of the visual characteristics, frequency characteristics, and key isosurfaces of the volume data. These three attribute characteristics are all in scalar values, not voxels, and the segmentation of the volume data is to perform segmentation processing on the three attribute characteristics separately and then combine them. This method greatly avoids the possible confusion that may occur when projecting the characteristics of volume data in voxels onto a two-dimensional space, and improves the generalization ability of visualization technology for different volume data. Moreover, in the process of generating the control points of the one-dimensional transfer function in this application, various volume data characteristic information such as volume data visual characteristic images, frequency characteristic images, key isosurface distribution images, and isosurfaces will be generated at the same time. Users can update the transfer function distribution points by interacting with this information. Since the segmentation algorithms are all in scalar values instead of voxels, this makes the interaction experience very smooth. In addition, these information can also provide interaction guidance to users, helping users analyze and understand the internal details and characteristics of the volume data, and assisting users to further quickly optimize and freely explore the transfer function through the transfer function editor (such as color configuration and transparency adjustment, etc.).

[0091] As Figure 9 shown, this embodiment of the application discloses a transfer function design device based on vision and frequency, including:

[0092] A frequency feature projection module 11, configured to divide volume data into a plurality of scalar value sub-intervals, and project each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the number of voxels, so as to obtain a frequency feature image corresponding to the volume data;

[0093] A contour image extraction module 12, configured to traverse the midpoints of each of the scalar value sub-intervals in the frequency feature image, so as to extract a contour image of an isosurface image of an isovalue point corresponding to the midpoint;

[0094] A visual feature projection module 13, configured to calculate a similarity index between two contour images corresponding to any two adjacent scalar value sub-intervals, and project a plurality of calculated similarity indexes onto a second preset two-dimensional space in the form of scatter points, so as to obtain a visual feature image corresponding to the volume data;

[0095] A point distribution module 14, configured to perform point distribution processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and key isovalues that meet a preset isovalue condition, so as to obtain a target transfer function corresponding to the volume data; the key isovalues are isovalue points in a two-dimensional space constructed based on the frequency feature image and the visual feature image.

[0096] It can be seen that in this application, the frequency features and visual features corresponding to the volume data are processed separately, and then the frequency features and visual features are projected onto a two-dimensional space to obtain key isovalues. After that, the frequency features, visual features, and key isovalues are used to generate the point distribution of the one-dimensional transfer function through an algorithm to obtain the corresponding target transfer function; in this way, the frequency features, visual features, and key isovalues of the volume data are processed separately, avoiding the chaotic situation that occurs when directly projecting the volume data, and enhancing the feature recognition ability and anti-noise ability.

[0097] In a specific embodiment, the frequency feature projection module 11 may include:

[0098] A voxel statistics unit, configured to count the number of voxels in each of the scalar value sub-intervals to obtain frequency features;

[0099] A first projection unit, configured to project each of the scalar value sub-intervals onto a first preset two-dimensional space in the form of scatter points based on the frequency features; the first preset two-dimensional space is a two-dimensional space constructed according to the midpoint of the scalar value sub-interval and the corresponding frequency feature.

[0100] In another specific embodiment, the frequency feature projection module 11 may include:

[0101] A gradient change determination unit, configured to project each of the scalar value sub - intervals onto the first preset two - dimensional space in the form of scatter points based on the number of voxels, and determine the gradient change situation of adjacent scatter points in the first preset two - dimensional space through a preset frequency feature region segmentation algorithm based on gradient change;

[0102] A first region division unit, configured to determine extreme points and corresponding boundary points from the first preset two - dimensional space based on the gradient change situation, and use the extreme points and the corresponding boundary points to divide the scatter points in the first preset two - dimensional space, so as to obtain a frequency feature image corresponding to the volume data.

[0103] In a specific embodiment, the contour image extraction module 12 may include:

[0104] An isosurface image extraction unit, configured to traverse the mid - points of each scalar value sub - interval in the frequency feature image through a preset isosurface extraction algorithm, and extract the isosurface of the corresponding isosurface points according to the mid - points to obtain an isosurface image;

[0105] A contour image extraction unit, configured to convert the isosurface image into a grayscale image and perform contour extraction on the grayscale image to obtain a contour image corresponding to the isosurface image.

[0106] In a specific embodiment, the visual feature projection module 13 may include:

[0107] A similarity calculation unit, configured to calculate the similarity index between two contour images corresponding to any adjacent scalar value sub - intervals, and perform mean smoothing processing on the corresponding calculation results to obtain a number of similarity indices;

[0108] A second projection unit, configured to project the number of similarity indices onto a second preset two - dimensional space in the form of scatter points, and divide the sparsity degree of the scatter point distribution in the second preset two - dimensional space through a preset visual feature region segmentation algorithm, so as to obtain a visual feature image corresponding to the volume data; the second preset two - dimensional space is a two - dimensional space constructed according to the mid - points of the scalar value sub - intervals and the corresponding similarity indices.

[0109] In another specific embodiment, the point - distribution module 14 may include:

[0110] A third projection unit, configured to normalize the similarity index and the frequency feature, and project the normalization result onto a target two - dimensional space constructed based on the visual feature and the frequency feature;

[0111] A dotting unit is configured to determine a number of equivalent points in the target two-dimensional space as key equivalents based on preset equivalent conditions, and perform dotting processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equivalents to obtain a target transfer function corresponding to the volume data.

[0112] In yet another specific embodiment, the dotting module 14 may include:

[0113] A function generation module is configured to perform dotting processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equivalents to obtain an initial transfer function corresponding to the volume data;

[0114] An interactive modification module is configured to modify the frequency feature image and / or the visual feature image and / or the key equivalents and / or the initial transfer function based on an interactive instruction, and finally obtain a target transfer function, so as to perform visualization processing on the volume data by using the target transfer function to obtain a corresponding visualization image.

[0115] Furthermore, an embodiment of the present application also discloses an electronic device. Figure 10 It is a structural diagram of an electronic device 20 shown according to an exemplary embodiment, and the content in the figure cannot be considered as any limitation on the scope of use of the present application.

[0116] Figure 10 It is a schematic structural diagram of an electronic device 20 provided by an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. Among them, the memory 22 is used to store a computer program, and the computer program is loaded and executed by the processor 21 to implement the relevant steps in the method for designing a transfer function based on vision and frequency disclosed in any of the foregoing embodiments. In addition, the electronic device 20 in this embodiment may specifically be an electronic computer.

[0117] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows is any communication protocol applicable to the technical solution of the present application, and no specific limitation is imposed on it here; the input / output interface 25 is used to obtain external input data or output data to the outside, and its specific interface type can be selected according to specific application needs, and no specific limitation is made here.

[0118] In addition, as a carrier for storing resources, the memory 22 can be a read-only memory, a random access memory, a magnetic disk, an optical disk, etc. The resources stored thereon can include an operating system 221, a computer program 222, etc., and the storage method can be transient storage or permanent storage.

[0119] Among them, the operating system 221 is used to manage and control each hardware device and the computer program 222 on the electronic device 20, and it can be Windows Server, Netware, Unix, Linux, etc. In addition to the computer program that can be used to complete the visual and frequency-based transfer function design method executed by the electronic device 20 disclosed in any of the foregoing embodiments, the computer program 222 can further include computer programs that can be used to complete other specific tasks.

[0120] Furthermore, the present application also discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, it implements the foregoing disclosed visual and frequency-based transfer function design method. For the specific steps of this method, reference can be made to the corresponding content disclosed in the foregoing embodiments, and details will not be repeated here.

[0121] In this specification, the various embodiments are described in a progressive manner. Each embodiment focuses on the differences from other embodiments, and the same or similar parts among the various embodiments can be referred to each other. For the devices disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the description of the method part.

[0122] Those skilled in the art can further realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. To clearly illustrate the interchangeability of hardware and software, the components and steps of the examples have been generally described according to their functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0123] The steps of the method or algorithm described in combination with the embodiments disclosed herein can be directly implemented by hardware, a software module executed by a processor, or a combination of the two. The software module can be placed in a random access memory (RAM), memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, register, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0124] Finally, it should also be noted that in this text, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the term "comprising", "including" or any other variant thereof is intended to cover non-exclusive inclusion, such that a process, method, article or device comprising a series of elements not only includes those elements but also includes other elements not expressly listed, or elements inherent to such process, method, article or device. Without further limitation, an element defined by the phrase "comprising a..." does not exclude the presence of additional identical elements in the process, method, article or device comprising said element.

[0125] The technical solutions provided in this application have been introduced in detail above. Specific examples are used in this text to elaborate on the principles and implementation manners of this application. The description of the above embodiments is only used to help understand the method and its core idea of this application. At the same time, for those of ordinary skill in the art, according to the idea of this application, there will be changes in the specific implementation manners and application scopes. In summary, the content of this specification should not be construed as a limitation to this application.

Claims

1. A transfer function design method based on vision and frequency, characterized in that: include: Dividing the volume data into a plurality of scalar value sub-intervals, and projecting each of the scalar value sub-intervals into a first preset two-dimensional space in the form of scattered points based on the number of voxels, so as to obtain a frequency characteristic image corresponding to the volume data; Traversing the midpoints of each of the scalar value subintervals in the frequency characteristic image to extract a contour image of an isosurface image of an isovalue point corresponding to the midpoint; Calculating similarity indexes between two contour images corresponding to any adjacent scalar value subintervals, and projecting the calculated similarity indexes into a second preset two-dimensional space in the form of scattered points to obtain a visual feature image corresponding to the volume data; A one-dimensional transfer function is arranged based on the frequency characteristic image, the visual characteristic image, and key equivalent values ​​that meet preset equivalent conditions to obtain a target transfer function corresponding to the volume data; the key equivalent values ​​are equivalent points in a two-dimensional space constructed based on the frequency characteristic image and the visual characteristic image.

2. The method for designing a transfer function based on vision and frequency according to claim 1, characterized in that: The projecting each of the scalar value subintervals in the form of scattered points to a first preset two-dimensional space based on the number of voxels includes: Counting the number of voxels in each of the scalar value subintervals to obtain a frequency feature; Based on the frequency characteristics, each of the scalar value subintervals is projected into a first preset two-dimensional space in the form of scattered points; the first preset two-dimensional space is a two-dimensional space constructed according to the midpoint of the scalar value subinterval and the corresponding frequency characteristics.

3. The method for designing a transfer function based on vision and frequency according to claim 2, characterized in that: The projecting each of the scalar value subintervals in the form of scattered points to a first preset two-dimensional space based on the number of voxels to obtain a frequency characteristic image corresponding to the volume data includes: Projecting each of the scalar value subintervals into the first preset two-dimensional space in the form of scattered points based on the number of voxels, and determining the gradient change of adjacent scattered points in the first preset two-dimensional space by using a preset frequency feature region segmentation algorithm based on gradient change; Based on the gradient change, extreme points and corresponding boundary points are determined from the first preset two-dimensional space, and scattered points in the first preset two-dimensional space are divided into regions using the extreme points and the corresponding boundary points to obtain a frequency characteristic image corresponding to the volume data.

4. The method for designing a transfer function based on vision and frequency according to claim 1, characterized in that: The step of traversing the midpoints of the scalar value subintervals in the frequency characteristic image to extract a contour image of an isosurface image of an isovalue point corresponding to the midpoint includes: Traversing the midpoints of each scalar value subinterval in the frequency characteristic image by using a preset isosurface extraction algorithm to extract isosurfaces of corresponding isovalue points according to the midpoints to obtain an isosurface image; The isosurface image is converted into a grayscale image, and contour extraction is performed on the grayscale image to obtain a contour image corresponding to the isosurface image.

5. The method for designing a transfer function based on vision and frequency according to any one of claims 1 to 4, characterized in that: The similarity index between two contour images corresponding to any adjacent scalar value subintervals is calculated, and a plurality of similarity indexes obtained by calculation are projected into a second preset two-dimensional space in the form of scattered points to obtain a visual feature image corresponding to the volume data, including: The similarity index between two contour images corresponding to any adjacent scalar value subintervals is calculated, and the corresponding calculation results are averaged and smoothed to obtain several similarity indexes; The several similarity indices are projected into a second preset two-dimensional space in the form of scattered points, and the sparsity of the scattered point distribution in the second preset two-dimensional space is divided by a preset visual feature region segmentation algorithm to obtain a visual feature image corresponding to the volume data; the second preset two-dimensional space is a two-dimensional space constructed according to the midpoint of the scalar value subinterval and the corresponding similarity index.

6. The method for designing a transfer function based on vision and frequency according to claim 5, characterized in that: The one-dimensional transfer function is subjected to point arrangement processing based on the frequency feature image, the visual feature image, and the key equivalent value that meets the preset equivalent condition to obtain the target transfer function corresponding to the volume data, including: Normalizing the similarity index and the frequency feature, and projecting the normalized result into a target two-dimensional space constructed based on the visual feature and the frequency feature; Based on preset equivalent conditions, several equivalent points in the target two-dimensional space are determined as key equivalent values, and based on the frequency feature image, the visual feature image, and the key equivalent values, a one-dimensional transfer function is processed to obtain a target transfer function corresponding to the volume data.

7. The method for designing a transfer function based on vision and frequency according to claim 6, characterized in that: The performing point arrangement processing on the one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equivalent value to obtain the target transfer function corresponding to the volume data includes: Performing point processing on a one-dimensional transfer function based on the frequency feature image, the visual feature image, and the key equivalent value to obtain an initial transfer function corresponding to the volume data; The frequency characteristic image and / or the visual characteristic image and / or the key equivalent value and / or the initial transfer function are modified based on the interactive instructions, and finally a target transfer function is obtained, so that the volume data can be visualized using the target transfer function to obtain a corresponding visualization image.

8. A transfer function design device based on vision and frequency, characterized in that: include: A frequency characteristic projection module, used for dividing the volume data into a plurality of scalar value sub-intervals, and projecting each of the scalar value sub-intervals into a first preset two-dimensional space in the form of scattered points based on the number of voxels, so as to obtain a frequency characteristic image corresponding to the volume data; A contour image extraction module, used for traversing the midpoints of each of the scalar value subintervals in the frequency characteristic image to extract a contour image of an isosurface image of an isovalue point corresponding to the midpoint; A visual feature projection module, used to calculate a similarity index between two contour images corresponding to any adjacent scalar value subintervals, and project the calculated similarity indexes into a second preset two-dimensional space in the form of scattered points to obtain a visual feature image corresponding to the volume data; A point arrangement module is used to arrange points for a one-dimensional transfer function based on the frequency characteristic image, the visual characteristic image, and key equivalent values ​​that meet preset equivalent conditions to obtain a target transfer function corresponding to the volume data; the key equivalent values ​​are equivalent points in a two-dimensional space constructed based on the frequency characteristic image and the visual characteristic image.

9. An electronic device, characterized in that: include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the vision and frequency-based transfer function design method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: Used to store a computer program, which, when executed by a processor, implements the vision- and frequency-based transfer function design method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Visualization method capable of displaying volume data characteristics rapidly

    CN103778658A

  • Prioritized image visualization from scalable compressed data

    US20060031372A1