A mountain landscape balance quantitative evaluation method based on simulation effect

By segmenting and simplifying color blocks in the simulated mountain landscape, extracting the mountain contour lines, and calculating the equilibrium coefficient, the subjective problem of mountain landscape evaluation is solved, and objective design optimization guidance is provided.

CN121329936BActive Publication Date: 2026-08-25TIANJIN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511497003.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-20
Publication Date
2026-08-25
Estimated Expiration
2045-10-20

AI Technical Summary

Technical Problem

Existing methods for evaluating mountain landscapes suffer from strong subjectivity, inaccurate qualitative evaluation results, and inability of quantitative evaluations to reflect the intuitive characteristics of mountain landscapes, making them unsuitable for design optimization.

Method used

By parametrically segmenting, filling, and simplifying the simulated mountain landscape image, the contour lines of mountains at each level are extracted, the balance coefficient of the vector mountain contour lines at each level is calculated, and an objective evaluation result is obtained.

Benefits of technology

It enables objective evaluation in mountain landscape design, guides design optimization, and supports automatic optimization and intelligent generation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121329936B_ABST
    Figure CN121329936B_ABST
Patent Text Reader

Abstract

The application discloses a mountain landscape balanced quantitative evaluation method based on simulation effect, comprising the following steps: simulating the mountain landscape effect to be evaluated to derive a simulation effect diagram; performing image segmentation on the simulation effect diagram according to pixel values to obtain a complex color block diagram; simplifying the complex color block diagram by using a clustering algorithm to obtain a simple color block diagram; extracting contour lines of mountain ranges at various levels based on the simple color block diagram; smoothing and vectorizing the contour lines of the mountain ranges at various levels to obtain vector contour lines of the mountain ranges at various levels; calculating balanced coefficients of the vector contour lines of the mountain ranges at various levels in different visual field ranges; and obtaining an evaluation result by comprehensively considering the balanced coefficients of the contour lines of the mountain ranges at various levels. The evaluation result is more objective, and reliable technical guidance is provided for objective evaluation in real and virtual mountain landscape design; the evaluation object is the simulated mountain landscape effect corresponding to the design result of the mountain landscape, and the evaluation result can be connected with upstream and downstream design links to directly guide design optimization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of spatial information technology, and in particular to a quantitative evaluation method for the equilibrium measurement of mountain landscape based on simulation results. Background Technology

[0002] Influenced by traditional landscape culture, contemporary real-world environmental design, such as urban design, rural design, and tourism design, as well as virtual environment design, such as game scene design, virtual tour design, and advertising design, often incorporates mountain landscapes as a fundamental design element. In the design process, to achieve aesthetically pleasing mountain landscape effects, it is necessary to evaluate the beauty of the mountain shape and, based on this, optimize angles or space. Among the many beauty evaluation indicators, balance is one of the most important. Therefore, evaluating the balance of mountain landscapes is crucial for both real-world and virtual environment design involving mountain landscapes and has a wide range of applications.

[0003] Currently, mountain landscape evaluation can be divided into two technical approaches: one is evaluation based on real-world effects, using photographed images of the mountain as the direct evaluation object; the other is evaluation based on simulation effects, using simulated mountain renderings as the direct evaluation object. Due to the rapid development of 3D rendering technology, current mountain simulation renderings can basically present the structural characteristics of mountain landscapes. Compared to real-world mountain images, this method is more efficient and less costly. Therefore, simulation-based evaluation has become the main technical approach for mountain landscape evaluation. For a long time, simulation-based evaluations have mostly adopted qualitative evaluation methods: first, scoring is based on subjective feelings, and then the evaluation is based on the combined scores from multiple people. In recent years, new quantitative evaluation methods have emerged, using 3D models to generate mountain profile maps, and then performing spatial calculations and feature classification on the mountain profile maps.

[0004] Existing evaluation techniques and methods have significant shortcomings: on the one hand, traditional qualitative evaluation methods rely on intuitive feelings, resulting in highly subjective evaluation results; on the other hand, since mountain profile maps cannot directly reflect visual effects, evaluation methods based on mountain profile maps, while avoiding subjectivity, cannot reflect the intuitive characteristics of the mountain landscape and cannot be directly used in design optimization work. Summary of the Invention

[0005] This invention provides a quantitative evaluation method for the equilibrium of mountain landscapes based on simulation results. The method involves parametric image segmentation, color block filling, and color block simplification on simulated mountain landscape images to extract mountain contour lines at various levels. The equilibrium coefficients of these vector mountain contour lines are then calculated, and a comprehensive evaluation result is derived. This method can be applied to mountain landscape design, providing a relatively objective evaluation result that can be integrated with upstream and downstream design processes, directly guiding design optimization. See the description below for details:

[0006] A quantitative evaluation method for mountain landscape equilibrium based on simulation results, the method comprising the following steps:

[0007] Simulate the effect of the mountain landscape to be evaluated and export the simulation effect image; perform image segmentation on the simulation effect image based on pixel values ​​to obtain a complex color block image;

[0008] A clustering algorithm is used to simplify a complex color block image, resulting in a simple color block image; mountain contour lines at each level are then extracted based on the simple color block image.

[0009] Smooth and vectorize the mountain contour lines at each level to obtain vectorized mountain contour lines at each level;

[0010] Calculate the balance coefficient of the mountain contour lines at each level under different field of view; and obtain the evaluation result by combining the balance coefficients of the mountain contour lines at each level.

[0011] The step of segmenting the simulated image based on pixel values ​​to obtain a complex color block image is as follows:

[0012] The Felzenszwalb algorithm is used to segment the simulated image. Pixels are regarded as vertices in the image, and the color difference between adjacent pixels is used as the edge weight. The sorted edges are traversed from smallest to largest using a greedy strategy. When the difference between regions is less than the minimum difference between the two regions plus a penalty term inversely proportional to the size of the region, the two regions are merged to obtain a partition mapping table of all pixels.

[0013] Based on the partition mapping table, calculate the average RGB color of all pixels in each partition, and use these colors to fill the corresponding partitions to obtain a complex color block map.

[0014] The simplified color block diagram obtained by using a clustering algorithm is as follows:

[0015] In Python, the `imread` function is called to read a complex color block image and expand the RGB values ​​of all color blocks into a two-dimensional feature matrix.

[0016] Input a two-dimensional feature matrix, use the KMeans algorithm to perform unsupervised clustering on all RGB values, calculate the inertia value of the clustering result corresponding to each cluster number, calculate the decrease ratio of the inertia value corresponding to two adjacent cluster numbers, select the smaller value of the pair of adjacent cluster numbers with the largest decrease ratio as the optimal cluster number, and export the clustering result corresponding to the optimal cluster number as a clustering mapping table.

[0017] The complex color block diagram is recolored based on the clustering mapping table. The color of each color block is replaced with the color represented by the RGB value of the cluster center corresponding to its RGB value, resulting in a simplified color block diagram.

[0018] The extraction of mountain contour lines at each level based on a simple color block image is as follows:

[0019] In Python, the imread function is called to read a simple color block image. Based on the R, G, and B values, the brightness of each color block is calculated using a brightness weighting method to obtain the brightness value of each color block.

[0020] Color blocks with the same color brightness value are merged into the same brightness layer to obtain a brightness partition map;

[0021] Remove the brightness layer with the highest color brightness value from the initial range of the brightness partition map, extract the contour of the remaining range to obtain a closed contour line with a width of 1 pixel, delete the three contour lines located at the edge of the original image, save it as an image format file with the same image range as the original size, and obtain the mountain contour line of the image format corresponding to the brightness layer.

[0022] Replace the initial range with the remaining range, and repeat the previous operation multiple times until the remaining range contains only one brightness layer, thus obtaining the mountain contour lines in the image format corresponding to different brightness layers.

[0023] The smoothing and vectorization of the mountain contour lines at each level results in the following vectorized mountain contour lines at each level:

[0024] In Python, the cv2.inRange function is called to take a mountain contour line of any level as input, extract the pixels of the mountain contour line, sort them according to the column number of the pixels, and form a discrete point sequence sorted along the direction of the mountain contour line.

[0025] The parametric spline interpolation method is used to smoothly reconstruct the contour lines of mountains. In Python, the scipy.interpolate.splprep function is first called, the discrete point sequence is input, the smoothing coefficient is set, and the two-dimensional trajectory of the discrete point sequence is fitted in the form of parameters. Then, the splev function is called to uniformly sample on the two-dimensional trajectory to generate a smooth point sequence with a specified number of points.

[0026] An orthogonal coordinate system is established with the image center point as the origin, the vertical midline of the image as the vertical axis, and 1 pixel as the unit, to extract the coordinates of the smooth point sequence.

[0027] In Python, the ezdxf library is used to create a DXF document. The coordinates of a smooth point sequence are written sequentially in the model space in the form of a lightweight polyline to obtain a vector mountain contour line at any level.

[0028] Repeat the operation for the mountain contour lines at each level of the image format to obtain the vector mountain contour lines at each level.

[0029] The equilibrium coefficient for calculating the vector mountain contour lines at each level across different fields of view is as follows:

[0030] For any level of vector mountain contour line, using the same and appropriate number of samples, horizontal equidistant resampling is performed on both sides of the vertical axis. The vertical coordinates of the sampling points on the right side are extracted sequentially from the vertical axis to the right to construct the right-side sequence. Extract the ordinates of the sampling points on the left side sequentially from the vertical axis to the left, and construct the left-side sequence. ;

[0031] From the right column and the sequence on the left In the above, extract the first 5×m elements to construct two sub-sequences. and Calculate the rank of each element in its corresponding sub-sequence, and then calculate the correlation coefficient of the vector mountain contour line within a field of view of m degrees.

[0032] A linear transformation is performed on the correlation coefficients of different field of view ranges, mapping them to the interval [0, 1], to obtain the equilibrium coefficients of the mountain contour lines at any level vector across different field of view ranges:

[0033] The process is repeated for each level of vector mountain contour lines to obtain the equilibrium coefficients of each level of vector mountain contour lines in different fields of view.

[0034] The evaluation result obtained by integrating the balance coefficients of the mountain contour lines at various levels is as follows:

[0035] Calculate the comprehensive balance coefficient of the vector mountain contour line at any level by using the balance coefficient of the vector mountain contour line at different viewing ranges.

[0036] A threshold for the balance of mountain landscape is set. If the comprehensive balance coefficient of any level of vector mountain contour line is greater than the threshold, the mountain landscape is evaluated as "balanced". Otherwise, the mountain landscape is evaluated as "unbalanced", and the evaluation results are applied to the mountain landscape design.

[0037] The beneficial effects of the technical solution provided by this invention are:

[0038] 1. This invention utilizes a series of methods such as image segmentation technology, spatial clustering algorithm, and graphic feature calculation to conduct quantitative evaluation. The evaluation results are relatively objective, which can avoid the subjectivity of designers and provide reliable technical guidance for objective evaluation in real and virtual mountain landscape design.

[0039] 2. The evaluation object of this invention is the simulated mountain landscape effect, which corresponds to the results of mountain landscape design. The evaluation results can be connected with upstream and downstream design links and can be directly used to guide design optimization. It can support the automatic optimization and intelligent generation of mountain landscape design schemes. Attached Figure Description

[0040] Figure 1 This is a schematic diagram of a quantitative evaluation method for mountain landscape equilibrium based on simulation results;

[0041] Figure 2 This is an example of a simulation effect diagram for this embodiment;

[0042] Figure 3 This is an example of a complex color block diagram in this embodiment;

[0043] Figure 4 This is a simple color block diagram example of this embodiment;

[0044] Figure 5 Examples of mountain contour lines at various levels in this embodiment. Detailed Implementation

[0045] To make the objectives, technical solutions, and advantages of the present invention clearer, the embodiments of the present invention will be further described in detail below with reference to the accompanying drawings and specific examples. It should be understood that the specific embodiments described herein are merely intended to explain the present invention and not to limit it. For those skilled in the art, the present invention can be practiced without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples of the invention.

[0046] For a long time, mountain landscape evaluation based on simulation results has mainly relied on qualitative evaluation based on intuition, resulting in highly subjective evaluation results. Existing quantitative evaluation methods evaluate mountain profiles, but the evaluation results cannot reflect the intuitive characteristics of the mountain landscape and cannot be directly used in design optimization work.

[0047] Based on the above research background, this invention performs parametric image segmentation, color block filling, and color block simplification on the simulated effect image of mountain landscape, extracts the contour lines of mountains at each level, calculates the balance coefficient of the vector mountain contour lines at each level, and comprehensively obtains the evaluation results. The evaluation results are relatively objective and can be connected with upstream and downstream design stages to directly guide design optimization.

[0048] To facilitate understanding of this invention, the following terms are explained in the embodiments of this invention:

[0049] Horizontal field of view angle is the maximum angular range that the human eye or device can observe in the horizontal direction (from left to right). In this embodiment of the invention, it specifically refers to the angular range that is simulated and observed in three-dimensional software.

[0050] Digital elevation models (DEMs) are physical ground models that represent ground elevations using an ordered array of numerical values. They are a branch of digital terrain models.

[0051] Shape interpolation is a method for creating 3D features by extracting and interpolating Z values ​​from a raster surface to convert planar features into 3D features.

[0052] RGB values ​​are a set of numerical values ​​consisting of three components: red, green, and blue, used to describe a specific color. The values ​​of the three components range from 0 to 255. For example, the RGB value (255, 255, 255) represents white.

[0053] A two-dimensional feature matrix is ​​a two-dimensional array used to systematically represent all the feature data of a set of samples. Each row represents a sample, observation, or data point, and each column represents a feature, attribute, or variable.

[0054] Clustering is an unsupervised learning method that divides samples in a dataset into several groups (called "clusters"), making samples within the same cluster very similar to each other, while samples in different clusters are very dissimilar.

[0055] Rank refers to the position or ranking of an element in an ordered sequence.

[0056] Example 1

[0057] To address the technical problems existing in the background art, embodiments of the present invention provide a quantitative evaluation method for mountain landscape equilibrium based on simulation results, the method comprising the following steps:

[0058] Figure 1 This is a flowchart illustrating the quantitative evaluation method for mountain landscape equilibrium based on simulation results provided in this embodiment of the invention. Figure 1 As shown, the quantitative evaluation method for mountain landscape equilibrium based on simulation results provided in this embodiment of the invention includes the following steps:

[0059] S1: Simulate the effect of the mountain landscape to be evaluated and export the simulation effect image;

[0060] S2: Perform image segmentation on the simulated image based on pixel values ​​to obtain a complex color block image;

[0061] S3: Use clustering algorithms to simplify complex color block diagrams and obtain simple color block diagrams;

[0062] S4: Extract the outline of mountains at various levels based on a simple color block image;

[0063] S5: Smooth and vectorize the mountain contour lines to obtain vector mountain contour lines at various levels;

[0064] S6: Calculate the balance coefficient of the vector mountain contour lines at each level in different fields of view;

[0065] S7: The evaluation result is obtained by combining the balance coefficients of the mountain contour lines at all levels.

[0066] In summary, the embodiments of the present invention utilize image segmentation technology, spatial clustering algorithms, graphic feature calculation, and other methods to conduct quantitative evaluation through the above steps S1 to S7. The evaluation results are relatively objective, which can avoid the subjectivity of designers and provide reliable technical guidance for objective evaluation in real and virtual mountain landscape design.

[0067] Example 2

[0068] The following is combined Figures 2-4 The document also details the specific calculation formulas and the implementation methods of steps S1 to S7.

[0069] In one possible implementation, step S1 includes:

[0070] S11: Determine the effect of the mountain landscape to be evaluated, including the observation location, observation direction, and horizontal field of view of the mountain landscape;

[0071] It is recommended that the horizontal field of view be less than 30°, but this embodiment of the invention does not limit this.

[0072] S12: Create a new ArcMap document, select a suitable projection coordinate system, create a new point layer "Simulated Observation Viewpoint", and draw the simulated observation viewpoint according to the preset observation position; create a new line layer "Simulated Observation Line", and draw the simulated observation line according to the preset observation direction. The simulated observation line has the simulated observation viewpoint as its endpoint and its direction is towards the preset observation direction.

[0073] S13: Obtain a large-scale high-resolution digital elevation model. Using the shape interpolation tool in ArcGIS software, input the digital elevation model as the surface and the simulated observation line as the feature. Convert the simulated observation line into a three-dimensional graphic and name it "3D Simulated Observation Line".

[0074] The publicly disclosed high-resolution digital elevation models include 30-meter resolution SRTM GDEM data and 12.5-meter resolution ALOS DEM data, etc., and the embodiments of the present invention do not limit them.

[0075] S14: Create a new ArcScene document, set the vertical exaggeration option to None, set the background color option to white, load the aforementioned digital elevation model and open the layer properties dialog box, switch to the Base Height tab, check "Float on custom surface", select the digital elevation model itself as the surface, and set the raster resolution to be consistent with the digital elevation model; then switch to the Symbolology tab, select "Custom" for the stretch type, and use a single-hue gradient color band to display according to the elevation value, so that the larger the elevation value, the higher the brightness, thus obtaining a 3D mountain model;

[0076] S15: Load the 3D simulated observation line of sight in the aforementioned ArcScene document, use the animation tool to create a path-based flight animation, select the 3D simulated observation line of sight as the path source, adopt flight mode for the path target, set the vertical offset to 1.7m (simulating human eye height), select follow path for the azimuth angle, set the elevation angle and roll angle to 0°, and input the preset horizontal field of view angle to establish a real-world simulated observation scene;

[0077] S16: Play the animation and export the image at the initial position. Select a resolution of 300 DPI or higher to obtain the simulation effect image, such as... Figure 2 As shown.

[0078] In this context, the ArcMap document, ArcScene document, ArcGIS software, SRTM GDEM data, and ALOS DEM data mentioned above are all technical tools or dataset names known to those skilled in the art, and will not be elaborated upon in the embodiments of this invention.

[0079] In one possible implementation, step S2 includes:

[0080] S21: Input the aforementioned simulation results, and use Felzenszwalb [1] The algorithm performs image segmentation, treating pixels as vertices in the graph and the color difference between adjacent pixels as edge weights. It uses a greedy strategy to traverse the sorted edges from smallest to largest. When the difference between regions is less than the minimum difference within two regions plus a penalty term inversely proportional to the region size, the two regions are merged to obtain a partition mapping table of all pixels.

[0081] This operation can be implemented in a Python environment: first, call the `imread` function in `skimage.io` to read the aforementioned simulated image, then call the `felzenszwalb` function in `skimage.segmentation` to perform image segmentation on the simulated image. It is recommended to set the region merging threshold to 200, the image Gaussian smoothing coefficient to 0.5, and the minimum region pixel size to 80. In practice, other parameter values ​​can also be selected; this embodiment of the invention does not impose any limitations on this.

[0082] S22: Based on the partition mapping table of all pixels, calculate the average RGB color of all pixels in each partition, and use these colors to fill the corresponding partitions to obtain a complex color block map, such as... Figure 3 As shown; this step can be achieved using the label2rgb function in skimage.color in the Python environment.

[0083] In one possible implementation, step S3 includes:

[0084] S31: In Python, call the imread function to read the aforementioned complex color block image, expand the RGB values ​​of all color blocks into a two-dimensional feature matrix, and each row consists of a three-dimensional vector composed of an RGB value;

[0085] S32: Input the aforementioned two-dimensional feature matrix, and use the KMeans algorithm to perform unsupervised clustering on all RGB values. Set the minimum and maximum number of clusters, and perform clustering operations according to different numbers of clusters within the interval. Calculate the inertia value (the sum of squared distances from all RGB values ​​to the corresponding cluster center RGB value) of the clustering result for each number of clusters. Then calculate the decrease ratio of the inertia value corresponding to two adjacent numbers of clusters, and select the smaller value of the pair of adjacent numbers with the largest decrease ratio as the optimal number of clusters. Export the clustering result corresponding to the optimal number of clusters as a clustering mapping table. This step can be implemented using the KMeans function in sklearn.cluster in the Python environment.

[0086] The minimum number of clusters is suggested to be 2, and the maximum number of clusters is 5. However, this embodiment of the invention does not impose any limitations on this.

[0087] S34: Recolor the complex color block diagram according to the clustering mapping table, replacing the color of each color block with the color represented by the RGB value of the cluster center, resulting in a simplified color block diagram, such as... Figure 4 As shown.

[0088] The Felzenszwalb algorithm, Python environment, imread function, greedy strategy, and KMeans function mentioned above are all well-known in the art, and will not be described in detail in this embodiment of the invention.

[0089] In one possible implementation, step S4 includes:

[0090] S41: In Python, call the imread function to read the aforementioned simple color block image. Based on the R, G, and B values, perform a brightness weighted calculation on the color of each color block to obtain the color brightness value of each color block. For the specific calculation method, please refer to formula (1):

[0091] Formula (1)

[0092] in, R, G, and B are the color brightness values ​​for each color block; R, G, and B are the R, G, and B values ​​for the color of each color block, respectively. , , These are the corresponding weighting coefficients. and + + .

[0093] According to the international television standard ITU-R BT.601, , , The values ​​can be set to 0.299, 0.587, and 0.114 respectively, but this embodiment of the invention does not limit the specific values.

[0094] S42: Merge color blocks with the same color brightness value into the same brightness layer to obtain a brightness partition map;

[0095] S43: Remove the brightness layer with the largest color brightness value from the initial range of the brightness partition map, extract the contour of the remaining range to obtain a closed contour line with a width of 1 pixel, delete the three contour lines located at the edge of the original image, save it as an image format file with the same image range as the original size, and obtain the mountain contour line of the image format corresponding to the brightness layer.

[0096] S44: Replace the initial range with the remaining range, iterating through step S43 multiple times until the remaining range contains only one brightness level, thus obtaining the mountain contour lines corresponding to different brightness levels, i.e., the mountain contour lines at each level of the image format, such as... Figure 5 As shown.

[0097] In one possible implementation, step S5 includes:

[0098] S51: In Python, call the cv2.inRange function, input a mountain contour line in any image format, extract the pixels of the mountain contour line, sort them according to the column number of the pixels, and form a discrete point sequence sorted along the direction of the mountain contour line.

[0099] S52: The parametric spline interpolation method is used to smoothly reconstruct the contour lines of the mountains. In Python, the scipy.interpolate.splprep function is first called, the discrete point sequence is input, an appropriate smoothing coefficient is set, and the two-dimensional trajectory of the discrete point sequence is fitted in the form of parameters. Then, the splev function is called to uniformly sample on the two-dimensional trajectory to generate a smooth point sequence with a specified number of points.

[0100] It is suggested that the smoothing coefficient be set to 50 and the number of specified points in the smoothing point sequence be 1000, but this embodiment of the present invention does not limit this.

[0101] S53: Establish an orthogonal coordinate system with the image center point as the origin, the vertical midline of the image as the vertical axis, and 1 pixel as the unit, and extract the coordinates of the smooth point sequence.

[0102] S54 uses the ezdxf library in Python to create a DXF document, and writes the coordinates of the above smooth point sequence in the form of a lightweight polyline (LWPOLYLINE) in the model space to obtain the vector mountain contour line at any level.

[0103] S55: Repeat steps S51-S54 for the mountain contour lines at each level of the image format to obtain the vector mountain contour lines at each level.

[0104] The functions cv2.inRange, scipy.interpolate.splprep, splev, ezdxf library, and DXF documentation mentioned above are all well-known in the art, and will not be elaborated upon in this embodiment of the invention.

[0105] In one possible implementation, step S6 includes:

[0106] S61: For any level of vector mountain contour line, using the same and appropriate number of samples, perform horizontal equidistant resampling on both sides of the vertical axis (i.e., the vertical center line), and extract the ordinates of the sampling points on the right side sequentially from the vertical axis to the right to construct the right-side sequence. Extract the ordinates of the sampling points on the left side sequentially from the vertical axis to the left, and construct the left-side sequence. They can be expressed as formula (2) and formula (3) respectively:

[0107] Formula (2)

[0108] Formula (3)

[0109] in, The sequence on the right, Let be the ordinate of the i-th sampling point on the right. The larger the x-coordinate value of the sampling point, the larger its order i is in the sequence. The left-hand column, y is the ordinate of the i-th sampling point on the left. The smaller the x-coordinate of the sampling point, the larger its order i is in the sequence; k is the number of samples on the left or right.

[0110] The number of samples is determined based on the horizontal field of view angle in step S1. Ten sampling points are set for every 1° range. For example, if the horizontal field of view angle in step S1 is 10°, that is, the corresponding field of view angles on the left and right sides are 5°, then 50 sampling points are set for each side, i.e., k=50.

[0111] S62: From the right-hand column and the sequence on the left In the above, extract the first 5×m elements to construct two sub-sequences. and Calculate the rank (order of magnitude) of each element in the corresponding sub-sequence, and then calculate the correlation coefficient of the vector mountain contour line within the m-degree field of view. For the specific calculation method, please refer to formula (4):

[0112] Formula (4)

[0113] in, The correlation coefficient represents the field of view range of m degrees. subsequence The i-th element in for In subsequence rank in for The average is equal in quantity to ; subsequence The i-th element in for In subsequence rank in for The average is equal in quantity to .

[0114] S63: Perform a linear transformation on the correlation coefficients of different field of view ranges to map them to the interval [0, 1], and obtain the equilibrium coefficient of the vector mountain contour line at any level in different field of view ranges. For the specific calculation method, please refer to formula (5):

[0115] Formula (5)

[0116] in, The equalization coefficient for the m-degree field of view; The correlation coefficient is the m-degree field of view range.

[0117] S64: Repeat steps S61-S63 for each level of vector mountain contour lines to obtain the balance coefficients of each level of vector mountain contour lines in different fields of view.

[0118] In one possible implementation, step S7 includes:

[0119] S71: Calculate the comprehensive balance coefficient of the vector mountain contour line at any level using the balance coefficient of the vector mountain contour line at different viewing ranges. For the specific calculation method, please refer to formula (6):

[0120] Formula (6)

[0121] in, is the comprehensive balance coefficient of the t-th level vector mountain contour line; n is the horizontal field of view angle in step S1; is the equilibrium coefficient of the mountain contour line at level t within the field of view of degree i; The weight for calculating the field of view range of i degrees is determined by the degree of i. The larger i is, the greater the weight of i The smaller.

[0122] Among them, it is recommended ,Right now , , Similarly, the embodiments of the present invention do not limit this.

[0123] S72: Set a threshold for the balance of the mountain landscape. If the comprehensive balance coefficient of any level of vector mountain contour line is greater than the threshold, the mountain landscape is evaluated as "balanced"; otherwise, the mountain landscape is evaluated as "unbalanced" and the evaluation results are applied to the mountain landscape design.

[0124] In summary, this invention performs parametric image segmentation, color block filling, and color block simplification on simulated mountain landscape images, extracts mountain contour lines at each level, calculates the equilibrium coefficients of vector mountain contour lines at each level, and comprehensively derives evaluation results. The evaluation results are relatively objective, providing reliable technical guidance for objective evaluation in real and virtual mountain landscape design. Furthermore, the evaluation results can be connected with upstream and downstream design stages, directly guiding design optimization and supporting the automatic optimization and intelligent generation of mountain landscape design schemes.

[0125] References

[0126] [1]Felzenszwalb PF, Huttenlocher DP Efficient Graph-Based ImageSegmentation[J]. International Journal of Computer Vision, 2004(59): 167–181.

[0127] Those skilled in the art will understand that the accompanying drawings are merely schematic diagrams of a preferred embodiment, and the sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0128] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A quantitative evaluation method for mountain landscape equilibrium based on simulation results, characterized in that, The method includes the following steps: Simulate the effect of the mountain landscape to be evaluated and export the simulation effect image; perform image segmentation on the simulation effect image based on pixel values ​​to obtain a complex color block image; A clustering algorithm is used to simplify a complex color block image, resulting in a simple color block image; mountain contour lines at each level are then extracted based on the simple color block image. Smooth and vectorize the mountain contour lines at each level to obtain vectorized mountain contour lines at each level; Calculate the balance coefficient of the mountain contour lines at each level under different field of view; and obtain the evaluation result by combining the balance coefficients of the mountain contour lines at each level. The extraction of mountain contour lines at each level based on a simple color block image is as follows: In Python, the imread function is called to read a simple color block image. Based on the R, G, and B values, the brightness of each color block is calculated using a brightness weighting method to obtain the brightness value of each color block. Color blocks with the same color brightness value are merged into the same brightness layer to obtain a brightness partition map; Remove the brightness layer with the highest color brightness value from the initial range of the brightness partition map, extract the contour of the remaining range to obtain a closed contour line with a width of 1 pixel, delete the three contour lines located at the edge of the original image, save it as an image format file with the same image range as the original size, and obtain the mountain contour line of the image format corresponding to the brightness layer. Replace the initial range with the remaining range, and repeat the previous operation multiple times until the remaining range contains only one brightness layer, thus obtaining the mountain contour lines in the image format corresponding to different brightness layers.

2. The method for quantitative evaluation of mountain landscape equilibrium based on simulation effects according to claim 1, characterized in that, The image segmentation of the simulated effect image based on pixel values ​​yields the complex color block image as follows: The Felzenszwalb algorithm is used to segment the simulated image. Pixels are regarded as vertices in the image, and the color difference between adjacent pixels is used as the edge weight. The sorted edges are traversed from smallest to largest using a greedy strategy. When the difference between regions is less than the minimum difference between the two regions plus a penalty term inversely proportional to the size of the region, the two regions are merged to obtain a partition mapping table of all pixels. Based on the partition mapping table, calculate the average RGB color of all pixels in each partition, and use these colors to fill the corresponding partitions to obtain a complex color block map.

3. The method for quantitative evaluation of mountain landscape equilibrium based on simulation effects according to claim 1, characterized in that, The simplified color block diagram obtained by using a clustering algorithm is as follows: In Python, the `imread` function is called to read a complex color block image and expand the RGB values ​​of all color blocks into a two-dimensional feature matrix. Input a two-dimensional feature matrix, use the KMeans algorithm to perform unsupervised clustering on all RGB values, calculate the inertia value of the clustering result corresponding to each cluster number, calculate the decrease ratio of the inertia value corresponding to two adjacent cluster numbers, select the smaller value of the pair of adjacent cluster numbers with the largest decrease ratio as the optimal cluster number, and export the clustering result corresponding to the optimal cluster number as a clustering mapping table. The complex color block diagram is recolored based on the clustering mapping table. The color of each color block is replaced with the color represented by the RGB value of the cluster center corresponding to its RGB value, resulting in a simplified color block diagram.

4. The method for quantitative evaluation of mountain landscape equilibrium based on simulation effects according to claim 1, characterized in that, The smoothing and vectorization of the mountain contour lines at each level yields the following vectorized mountain contour lines at each level: In Python, the cv2.inRange function is called to take a mountain contour line of any level as input, extract the pixels of the mountain contour line, sort them according to the column number of the pixels, and form a discrete point sequence sorted along the direction of the mountain contour line. The parametric spline interpolation method is used to smoothly reconstruct the contour lines of mountains. In Python, the scipy.interpolate.splprep function is first called, the discrete point sequence is input, the smoothing coefficient is set, and the two-dimensional trajectory of the discrete point sequence is fitted in the form of parameters. Then, the splev function is called to uniformly sample on the two-dimensional trajectory to generate a smooth point sequence with a specified number of points. An orthogonal coordinate system is established with the image center point as the origin, the vertical midline of the image as the vertical axis, and 1 pixel as the unit, to extract the coordinates of the smooth point sequence. In Python, the ezdxf library is used to create a DXF document. The coordinates of a smooth point sequence are written sequentially in the model space in the form of a lightweight polyline to obtain a vector mountain contour line at any level. Repeat the operation for the mountain contour lines at each level of the image format to obtain the vector mountain contour lines at each level.

5. A quantitative evaluation method for mountain landscape equilibrium based on simulation effects as described in claim 4, characterized in that, The equilibrium coefficient for calculating the vector mountain contour lines at each level across different fields of view is as follows: For any level of vector mountain contour line, using the same and appropriate number of samples, horizontal equidistant resampling is performed on both sides of the vertical axis. The vertical coordinates of the sampling points on the right side are extracted sequentially from the vertical axis to the right to construct the right-side sequence. Extract the ordinates of the sampling points on the left side sequentially from the vertical axis to the left, and construct the left-side sequence. ; From the right column and the sequence on the left In the above, extract the first 5×m elements to construct two sub-sequences. and Calculate the rank of each element in its corresponding sub-sequence, and then calculate the correlation coefficient of the vector mountain contour line within a field of view of m degrees. A linear transformation is performed on the correlation coefficients of different field of view ranges, mapping them to the interval [0, 1], to obtain the equilibrium coefficients of the mountain contour lines at any level vector across different field of view ranges: The process is repeated for each level of vector mountain contour lines to obtain the equilibrium coefficients of each level of vector mountain contour lines in different fields of view.

6. The method for quantitative evaluation of mountain landscape equilibrium based on simulation effects according to claim 1, characterized in that, The evaluation result derived from the balance coefficient of the mountain contour lines at various levels is as follows: Calculate the comprehensive balance coefficient of the vector mountain contour line at any level by using the balance coefficient of the vector mountain contour line at different viewing ranges. A threshold for mountain landscape balance is set. If the comprehensive balance coefficient of any level of vector mountain contour line is greater than the threshold, the mountain landscape is evaluated as "balanced". Otherwise, the mountain landscape is evaluated as "unbalanced", and the evaluation results are applied to the mountain landscape design.

Citation Information

Patent Citations

  • Method for fast segmenting interactive stereo image based on multilayer graph structure

    CN105046689A

  • Mountain range delimiting method and system

    CN114116950A