Red and blue three-dimensional film-based railway three-dimensional geographic scene data service making method
Through the method based on red and blue three-dimensional films, the problem of railway survey, design and operation and maintenance personnel is solved, and the problem of easy access to three-dimensional geographic scene data is achieved, low-cost, high-performance equipment is used to improve data visualization and operation and maintenance efficiency.
Patent Information
- Application Number
- CN202411725800.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-28
- Publication Date
- 2025-04-08
- Estimated Expiration
- 2044-11-28
AI Technical Summary
The existing technology is difficult to provide railway survey, design and operation and maintenance personnel with simple and low-cost three-dimensional geographic scenario data services, especially when the data volume is large and the computing resource requirements are high.
The railway three-dimensional geographic scene data service production method based on red and blue three-dimensional films is adopted. By collecting and organizing aerial survey data, calculating parallax and geographic transformation parameters, correlating railway line position data, generating red and blue three-dimensional films, and providing stereo scene map services through the visual map engine.
It realizes that the railway three-dimensional scenes can be viewed without the need for special stereo displays and high-performance computing equipment, effectively retaining the detailed information of railway operation and maintenance focuses on land objects, and quickly providing three-dimensional scene data in different regions through networked services.
Smart Images

Figure CN119784962A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of railway surveying and mapping geographic information, and in particular relates to a method for producing railway three-dimensional geographic scene data services based on red-blue stereoscopic films. Background Art
[0002] During the railway survey, design, and operation and maintenance phases, 3D geographic scene technologies such as railway spatial 3D models, oblique photography real-world 3D models, and orthophoto stereo films are increasingly being used to more intuitively observe on-site conditions and facilitate route selection, troubleshooting, and inspections. Railway spatial 3D models primarily refer to stereo models created by overlaying digital surface models (DSMs) and digital orthophotos (DOMs) covering a specific area along the railway. This method facilitates observation of large-scale terrain undulations and feature coverage along the railway, but lacks detailed features. Oblique photography real-world 3D modeling technology provides a more detailed 3D representation of geographic scenes, but the model data volume is large and requires high computing resources. Furthermore, it is not effective for modeling key features of railway operation and maintenance, such as utility poles and guardrails, as well as large areas without textures. Orthophoto stereo films generate measurable large-scale 3D models based on stereo orthophoto pairs, preserving surface details. However, the computational processing is complex, the data volume is large, and it is not suitable for networked service applications.
[0003] Artificial stereo vision is widely used in photogrammetry to observe and measure objects. According to the principle of stereo vision, a camera captures a stereo pair of images of the same scene at two different locations. With the help of specific equipment, the left and right eyes of a person observe one image in the pair respectively. If the line connecting the image points of the two eyes is approximately parallel to the baseline of the two eyes and the distance between the images is adapted to the intersection angle of the eyes, stereo vision can be constructed to achieve a three-dimensional intuitive perception of the scene. For a long time, only stereo mapping professionals could observe stereo scenes through professional software and hardware. This limited the application of stereo scenes to a small number of people. For railway survey and design professionals and front-line railway operation and maintenance personnel, they were restricted by three factors, including software and hardware conditions, and could not conveniently and efficiently conduct real-world visualization of the macro-topography of a railway design line or the micro-topography of a railway construction site. First, existing stereoscopic observation software needs to be equipped with dedicated stereoscopic displays and stereoscopic glasses; second, the calculation, display and rapid roaming switching of stereoscopic film data require better computer configuration; third, railway lines are long and the amount of aerial photography image data in the covered area is huge, requiring a large storage space, which is not convenient for multiple users to quickly call through B / S mode.
[0004] In summary, in practical applications, it is necessary to provide a three-dimensional scene composed of aerial photography in a simple, fast and low-cost way for use by railway design and operation and maintenance personnel. Summary of the Invention
[0005] In order to solve the problems in the background technology, the present invention provides a method for producing railway three-dimensional geographic scene data services based on red and blue stereo films, which is easy to use, low in cost, retains complete effective information and does not require local storage of large amounts of data.
[0006] To this end, the present invention adopts the following technical solutions:
[0007] A method for producing a railway three-dimensional geographic scene data service based on red-blue stereoscopic film comprises the following steps:
[0008] S1, prepare basic data:
[0009] Collect railway line position data within the project area and aerial survey data of all survey areas, including aerial photography, interior orientation elements corresponding to the aerial photography, exterior orientation elements in the object coordinate system corresponding to the aerial photography, survey area division information, and digital elevation model (DEM) within the survey area;
[0010] S2, organizing data, includes the following steps:
[0011] S2-1, calculate the main azimuth α and average ground height Z of each survey area avg The main azimuth angle α is the angle between the flight direction of the first survey line in the corresponding survey area and the true north direction, and the average ground height Z avg Obtained by averaging the elevation values in the digital elevation model DEM;
[0012] S2-2, build stereo pair S <P l ,P r >, P l Indicates the left aerial image in the stereo pair, P r represents the right aerial image in the stereo image pair, where the left aerial image and the right aerial image have overlapping parts;
[0013] S3, making stereoscopic films:
[0014] S3-1, calculate parallax:
[0015] For each stereo pair S <P l ,P r >, first construct a virtual object point in the object coordinate system, the elevation value of the virtual object point is the average ground height Z of the survey area avg , and then project them into the image coordinate system of the left and right aerial images respectively to obtain the parallax of the left and right aerial images;
[0016] S3-2, combining the left and right aerial images in the stereoscopic image pair into a stereoscopic film using the parallax obtained in S3-1;
[0017] S3-3, calculating geographic transformation parameters, includes the following steps:
[0018] S3-3-1, calculating the coordinates of all corner points of the stereoscopic image in the object coordinate system:
[0019] S3-3-2, coordinate system transformation of the stereo film is as follows:
[0020]
[0021] Among them, (x col ,y row ) is the coordinate of a point on the stereoscopic film in the image coordinate system, wherein the image coordinate system is a coordinate system with the upper left corner of the stereoscopic film as the origin and pixels as the unit; (X p ,Y p ) are the coordinates of the points on the stereoscopic film in the object coordinate system; G0 to G5 are affine transformation parameters used to perform coordinate system transformation on the coordinates of the points on the stereoscopic film;
[0022] Substitute the coordinates of the corner points of the aerial image obtained in S3-3-1 in the object coordinate system and their coordinates in the image coordinate system of the corresponding stereoscopic film into the above formula, solve the affine transformation parameters, and use the obtained affine transformation parameters to transform the points on the corresponding stereoscopic film into the object coordinate system;
[0023] S4, associating railway line position data, specifically includes the following steps:
[0024] S4-1, associating the railway mileage points with the coordinate data of the stereoscopic image for querying by the stereoscopic image or the railway mileage points;
[0025] S4-2, Railway Line Projection Drawing:
[0026] Project and connect the railway mileage points contained in each stereoscopic film so that the railway line position can be observed in the stereoscopic film;
[0027] S4-3, perform color change of the three-dimensional film:
[0028] Set the band of the stereoscopic film obtained in S3-2 to (R l ,G r ,B r ), where R l The red band of the aerial photography image on the left, G r 、B r The green and blue bands are respectively the ones of the aerial photography image on the right, and a red and blue stereoscopic image with projection lines of railway mileage points is obtained;
[0029] S5, 3D scene map service released:
[0030] First, use the red and blue stereoscopic film with railway mileage point projection lines obtained by S4 to create map tiles; then use the visual map engine to display the stereoscopic scene.
[0031] The survey area division information in S1 includes the survey area range, the survey lines included in the survey area, the information of the aerial photography images included in each survey line, and the actual aerial photography order; the grid resolution of the digital elevation model DEM is ≤30m, and the elevation system of the digital elevation model DEM is consistent with the elevation system in the exterior orientation elements of the aerial photography images; the railway line position data includes the railway name, mileage range, broken link division, and railway mileage points; among them, the railway mileage points include the mileage value corresponding to the point and the coordinates in the object coordinate system; the selection of mileage points is determined according to actual working conditions.
[0032] S2-1 calculates the average ground height Z by the following formula avg :
[0033]
[0034] Among them, Z g It represents the elevation value of the grid point of the digital elevation model DEM in S1, g represents the number of the grid point, g∈[1,G].
[0035] In S2-2, a stereo pair S is constructed. <P l ,P r >The method is:
[0036] The aerial image in S1 is i is the number of the survey line, and n is the number of the aerial photograph on the survey line i;
[0037] When i is an odd number, the set of constructed stereo pairs is:
[0038] When i is an even number, since the flight direction is opposite to the odd-numbered survey line, the constructed stereo image pair set is:
[0039]
[0040] Wherein, m is a positive integer greater than 0; a is the number of aerial photographs between two stereo pairs, and the following formula is used:
[0041]
[0042] Among them, o is the heading overlap rate of the aerial photography image, Indicates rounding down;
[0043] The aerial photographs in each survey area are matched one by one to obtain a stereo pair set, which includes several stereo pairs S <Pl ,P r >.
[0044] The specific method of calculating the parallax in step S3-1 is:
[0045] First, establish a virtual object point P v :
[0046] The plane coordinates of the virtual object point are the midpoint of the line connecting the photographic centers of the left and right aerial images in the stereo image pair;
[0047] In the stereo pair S <P l ,P r >, the exterior orientation elements of the aerial image on the left are The exterior orientation elements of the aerial image on the right are The internal orientation element is IOP(x0,y0,f), where (X l ,Y l ,Z l ) and (X r ,Y r ,Z r ) is the coordinate of the photographic center of the corresponding aerial image in the object coordinate system, and It describes the aerial attitude angle of the aerial photography image plane at the moment of photography; x0, y0 are the positions of the image principal point relative to the image center, and f is the vertical distance from the lens center to the image plane;
[0048] Use the following formula to calculate the virtual object point P v The coordinates (X v ,Y v ,Z v ):
[0049]
[0050] Then, calculate the virtual object point P according to the following formula: v Projection coordinates in the image coordinate system of the left or right aerial photography image:
[0051]
[0052] Wherein, D is l or r; Solve it by the following formula:
[0053]
[0054] Finally, use the virtual object point P v The projection coordinates of the left and right aerial images in the image coordinate system are calculated by the following formula to obtain the disparity P of the corresponding stereo image pair S: x and p y :
[0055]
[0056] S3-3-1 is specifically: using the following formula to solve the coordinates of the corner points of the stereoscopic film in the object coordinate system:
[0057]
[0058] Where j is the number of iterations, Represents the coordinates of the corner point t of the stereo film in the image coordinate system of the corresponding left aerial image; Indicates the coordinates of the corner point t of the jth iteration in the object coordinate system; t is the number of the corner point, 1≤t≤4,
[0059] First, the average ground height Z of the survey area is used avg As the initial elevation of corner point t Substituting into the above formula, the coordinates are calculated as Then the coordinates Interpolate the digital elevation model DEM in S1 to obtain the corresponding elevation value The final result will be Substituting into the above formula, we get the coordinates Continuously iterate the calculation until and and The iterative error is less than 0.1 meters, and the accurate coordinates of the corner point t in the object coordinate system are obtained.
[0060] Step S4-2 is specifically as follows:
[0061] First, for each stereo image pair, all the railway mileage points covered by it are found, and the coordinates (X w ,Y w ,Z w ) are converted into the coordinates of the image coordinate system of the left and right aerial photography images (x l,w ,y l,w ) and (x r,w ,y r,w ):
[0062]
[0063] Then, connect the railway mileage points with their corresponding positions on the left and right aerial images, delete the connection lines that only exist on one side of the aerial image, and obtain the railway mileage point projection connection lines; among them, the connection line corresponding to the left aerial image is drawn in red, and the connection line corresponding to the right aerial image is drawn in cyan, which is a mixture of blue and green.
[0064] The display of the stereoscopic scene is specifically as follows: according to the measurement area division information in S1, layer settings are performed, each layer corresponds to the stereoscopic scene of a measurement area, and the default rotation angle of each layer is configured to be (90°-α). When the user views the layer, the layer is automatically rotated clockwise by (90°-α), keeping the baseline direction of the stereoscopic film in the corresponding stereoscopic scene consistent with the left and right direction of the binocular baseline to achieve a stereoscopic visual effect.
[0065] Compared with the prior art, the present invention has the following beneficial effects:
[0066] 1. The method of the present invention does not require a dedicated 3D display computer or 3D viewing glasses. Only low-cost red and blue 3D filter glasses are required to view 3D railway scenes on paper printouts or ordinary monitors.
[0067] 2. For small objects that are difficult to model in real-life 3D, such as utility poles and protective fences, which are of key concern to railway operations and maintenance, the method of the present invention can effectively preserve their detailed information.
[0068] 3. The method of the present invention does not require local storage of large amounts of data. It can quickly obtain three-dimensional scene data of different areas through geographic information data network services and in combination with railway line mileage association information. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] Figure 1 is a flow chart of the present invention;
[0070] Figure 2 Schematic diagram of the positional relationship between the survey area and the aerial photography images therein in the present invention;
[0071] Figure 3 Schematic diagram of the positional relationship between the stereoscopic film and the left and right aerial photographs in one embodiment of the present invention. DETAILED DESCRIPTION
[0072] The technical solution of the present invention is further described in detail below with reference to the accompanying drawings and embodiments.
[0073] like Figure 1 As shown, the present invention provides a method for producing a railway three-dimensional geographic scene data service based on a red-blue stereoscopic film, comprising the following steps:
[0074] S1, prepare basic data:
[0075] Collect aerial survey data from all survey areas within the project area after aerial triangulation. This data includes aerial photography, interior elements corresponding to the aerial photography, exterior elements corresponding to the aerial photography in the object coordinate system, survey area demarcation information, digital elevation models (DEMs) within the survey area, and data on existing or planned railway lines within the project area. Aerial photography is captured in red, green, and blue bands, with an 8-bit pixel depth.
[0076] The survey area division information includes the survey area range, the survey lines included in the survey area, the information of the aerial photography images included in each survey line, and the actual aerial photography order.
[0077] The grid resolution of the digital elevation model (DEM) should be ≤30m, and the elevation system of the digital elevation model (DEM) should be consistent with the elevation system used in the exterior orientation elements of the aerial photography.
[0078] Railway alignment data is stored in text format and includes railway name, mileage range, broken link division, and railway mileage points. A railway mileage point includes the mileage value corresponding to the point and the coordinates in the object coordinate system. The selection of mileage points is determined based on actual working conditions. In one embodiment of the present invention, for high-speed railway alignments, one mileage point is taken for every 100 meters of straight sections and one mileage point is taken for every 20 meters of curved sections. For conventional railway alignments, one mileage point is taken for every 20 meters of straight sections and one mileage point is taken for every 5 meters of curved sections.
[0079] S2, organizing data, includes the following steps:
[0080] S2-1, Calculation of survey area information:
[0081] like Figure 2 As shown in Figure 1, the stereo data is organized and processed using the survey area in S1 as a unit. For each survey area, its main azimuth angle α and average ground height Z are calculated. avg When taking aerial photography, multiple survey lines in the survey area are approximately parallel, and the flight directions of adjacent survey lines are opposite. The angle between the flight direction of the first survey line in the survey area and the true north direction is taken as the main azimuth angle α of the survey area. avg It approximately represents the average ground height of the entire survey area, and there is formula (1):
[0082]
[0083] Among them, Z g Represents the elevation value of the grid point of the digital elevation model DEM, g represents the number of the grid point, g∈[1,G].
[0084] S2-2, build stereo image pair:
[0085] Aerial photography will be obtained in the order of flight i is the number of the survey line, and n is the number of the aerial photograph on the survey line i;
[0086] When i is an odd number, the set of stereo pairs is:
[0087] Where m is a positive integer greater than 0; a is the number of aerial photographs between two stereo pairs, and formula (2) is:
[0088]
[0089] Wherein, o is the heading overlap ratio of the aerial photography images, which represents the proportion of the overlapping parts of adjacent aerial photography images, 0<o<1, Indicates rounding down.
[0090] When i is an even number, since the flight direction is opposite to the odd-numbered survey line, the set of constructed stereo pairs is:
[0091] The aerial photographs in each survey area are matched one by one to obtain a stereo pair set, which includes several stereo pairs S <P l ,P r >, P l Indicates the left aerial image in the stereo pair, P r Represents the right-hand aerial image in a stereo pair. The left and right aerial images have overlapping areas, typically ≥50%, and also feature separately captured ground objects. The stereo pair they form is the basis for artificial stereo vision.
[0092] S3, making a stereoscopic film, includes the following steps:
[0093] S3-1, calculate parallax:
[0094] For each stereo image pair, a virtual object point is first constructed in the object coordinate system. The elevation value of the virtual object point is the average ground height Z of the survey area. avg , and then project them into the image coordinate system of the left and right aerial images respectively, and calculate the parallax of the left and right aerial images for the synthesis of the stereo film, specifically:
[0095] First, establish a virtual object point P v :
[0096] The plane coordinates of the virtual object point are the midpoint of the line connecting the photographic centers of the left and right aerial images in the stereo image pair, so as to ensure that the virtual object point can be projected onto the left and right aerial images.
[0097] In the stereo pair S <P l ,P r>, the exterior orientation elements of the aerial image on the left are The exterior orientation elements of the aerial image on the right are Use formula (3) to calculate the virtual object point P v The coordinates (X v ,Y v ,Z v ):
[0098]
[0099] (X l ,Y l ,Z l ) and (X r ,Y r ,Z r ) is the coordinate of the photographic center of the corresponding aerial image in the object coordinate system, and To describe the aerial attitude angle of the aerial photography image at the moment of photography, the aerial attitude angle includes: The internal orientation element is IOP(x0,y0,f), where x0 and y0 are the positions of the principal point relative to the image center, and f is the vertical distance from the lens center to the image plane.
[0100] Then, according to the collinear equation formula, that is, formula (4), calculate the virtual object point P v Projection coordinates in the image coordinate system of the left or right aerial photography image:
[0101]
[0102] Where D is l or r, Solve through formula (5):
[0103]
[0104] Finally, use the virtual object point p v The projection coordinates of the left and right aerial images in the image coordinate system are calculated by formula (6) to obtain the disparity p of the corresponding stereo image pair S: x and p y :
[0105]
[0106] The parallax calculation method used in the present invention can make the sight lines of both eyes intersect at the average ground height when constructing stereoscopic visual observation, and has a good stereoscopic observation effect for most ground objects in the measurement area.
[0107] S3-2, Synthetic Stereo Film:
[0108] First, according to the disparity p obtained in S3-1 x and p y Determine the relative position relationship of the overlapping area of the left and right aerial images, crop the original films of the left and right aerial images, retain only the overlapping area, and then merge the left and right aerial images into a three-dimensional film. In one embodiment of the present invention, the left aerial image is placed on the upper left of the right aerial image for cropping, such as Figure 3 shown.
[0109] S3-3, calculate geographic transformation parameters:
[0110] Based on the image plane coordinates of the corner points of the stereo film, its three-dimensional space coordinates are calculated, and then the geographic transformation parameters are calculated and written into the coordinate information file of the stereo film image. When publishing geographic information services, it can be directly mapped to the geographic space. At the same time, the ground coverage polygon range of each stereo film is recorded, including:
[0111] S3-3-1, according to formula (7), use iterative calculation method to calculate the coordinates of the corner points of the stereo image in the object coordinate system:
[0112]
[0113] Where j is the number of iterations, Represents the coordinates of the corner point t of the stereo film in the image coordinate system of the corresponding left aerial image; Represents the coordinates of corner point t in the object coordinate system at the jth iteration. t is the number of the corner point, 1≤t≤4.
[0114] First, use the average ground height Z of the survey area avg As the initial elevation of corner point t Substituting into formula (7), the spatial coordinates are calculated as Then the coordinates Interpolate the digital elevation model DEM in S1 to obtain the elevation value corresponding to the point The final result will be Substituting into formula (7), we can get the new spatial coordinates Repeat this process until and and and The iterative error is less than 0.1 meters, and it is considered that the coordinates of the corner point t in the object coordinate system have been obtained more accurately. The spatial coordinates of the four corner points are recorded in the database in clockwise order to represent the ground coverage of the stereo film.
[0115] S3-3-2, use the affine transformation formula (8) to calculate the geographic transformation parameters:
[0116]
[0117] Among them, (x col ,y row ) is the coordinate of the point on the stereo film in the image coordinate system, which is a coordinate system with the upper left corner of the stereo film as the origin and pixels as the unit; G0~G5 are affine transformation parameters used to transform the coordinate system of the point coordinates on the stereo film; (X p ,Y p ) are the coordinates of the points on the stereo film in the object coordinate system. Substitute the object coordinates of the four corner points of the aerial photograph obtained in S3-3-1 and their coordinates in the image coordinate system of the corresponding stereo film into formula (8) and solve for the affine transformation parameters G0 to G5 using the least squares method. Use the obtained affine transformation parameters to transform the points on the corresponding stereo film into the object coordinate system.
[0118] Specifically, the obtained affine transformation parameters are written into a coordinate information file in the order of (G1, G4, G2, G5, G0, G3), such as a .tfw file (for tiff format images) or a .jgw file (for jpeg format images). S4, associating railway line position data, specifically includes the following steps:
[0119] S4-1, associate the railway mileage points with the coordinate data of the stereoscopic image, so as to enable querying by the stereoscopic image or the railway mileage points:
[0120] Based on the railway line position data in S1, its position association with the stereo film is calculated, and the index relationship between the railway mileage point and the stereo film is established. For each railway mileage point in the survey area, its geographic spatial coordinates are used to determine whether it is within the ground coverage of the stereo film. If it is within the range, the stereo film information is associated with the mileage point and recorded in the database. At the same time, the virtual object point P of the stereo image pair is calculated. t The plane distance to the railway mileage point, sort all the stereo slices associated with the mileage point in ascending order according to the plane distance. Representing the many-to-many index relationship between the railway mileage point set L and the stereoscopic film set U, the forward index formula (9) for querying the corresponding stereoscopic film based on the railway mileage point is:
[0121] R(l)={u∈U|(l,u)∈R} (9)
[0122] There is also a reverse index relationship formula (10) for querying the corresponding railway mileage points based on the stereo image:
[0123] R -1 (u)={l∈L|(l,u)∈R} (10)
[0124] S4-2, Railway Line Projection Drawing:
[0125] The railway mileage points contained in each stereo image are projected and connected so that the railway line position can be observed in the stereo image. First, for each stereo image pair, all the railway mileage points covered by it are found according to formula (10), and then the coordinates (X w ,Y w ,Z w ) are converted into the coordinates of the image coordinate system of the left and right aerial photography images (x l,w ,y l,w ) and (x r,w ,y r,w ):
[0126]
[0127] Then, connect the railway mileage points with their corresponding positions on the left and right aerial images, and delete the lines that only exist on one side of the aerial image to obtain the railway mileage point projection lines. The lines corresponding to the left aerial image are drawn in red, and the lines corresponding to the right aerial image are drawn in cyan, which is a mixture of blue and green.
[0128] S4-3, perform color change of the three-dimensional film:
[0129] Set the band of the stereoscopic film obtained in S3-2 to (R l ,G r ,B r ), where R l The red band of the aerial photography image on the left, G r ,B r Specifically, based on the principle of complementary colors, the image separation conditions for artificial stereoscopic vision are realized. Taking the red-blue stereoscopic film as an example, the color filter is red on the left and blue on the right, that is, the left filter only retains the red channel of the image, and the right filter only retains the blue and green channels of the image, so that the two eyes observe the left and right aerial images respectively, thus forming a stereoscopic image. For the left and right aerial images, their red, green and blue bands are (R l ,G l ,B l ), (R r ,G r ,B r ), the three bands of the synthesized stereo film are (R l ,G r ,B r ).
[0130] A red and blue stereo film with projection lines of railway mileage points is obtained.
[0131] S5, stereo scene map service release, includes the following steps:
[0132] S5-1 map tile production:
[0133] Use the red and blue stereo images obtained by S4 to make map tiles.
[0134] Take the SuperMap tile generation tool as an example: the first step is to import the stereo slice into the SuperMap tile generation tool to generate a mosaic dataset; the second step is to generate a three-dimensional image cache, set the tile type to global segmentation, the tile storage type to discrete or compact, the tile image type to JPG_PNG, the tile size to 256*256, the starting level to 6 levels, and the ending level to 18 levels; the third step is to use the publishing engine iServer to publish the image data tile cache as a two- and three-dimensional service; the fourth step is to provide the data map service access address URL and data layer name to support two- and three-dimensional application scenarios.
[0135] S5-2, service release and parameter configuration:
[0136] Through the visual map engine, the data access address published by S5-1 is used to display the three-dimensional scene.
[0137] Based on the survey area division information, layers are set up for each survey area. Each layer corresponds to the stereo scene of a survey area, and the main azimuth angle of the survey area is α. The default rotation angle of each layer is configured to be (90°-α). When the user calls the stereo scene map service, the layer is automatically rotated clockwise by (90°-α) to keep the baseline direction of the stereo film in the three-dimensional scene consistent with the left and right direction of the binocular baseline, achieving a stereoscopic visual effect. For users who need to specify the railway mileage for viewing, the index formula (8) established in step S4-1 is used to spatially locate the corresponding stereo film.
Claims
1. A method for producing railway three-dimensional geographic scene data service based on red-blue stereo film, characterized in that: The following steps are involved: S1, prepare basic data: Collect railway line position data within the project area and aerial survey data of all survey areas, the aerial survey data of the survey area including aerial photography, internal orientation elements corresponding to the aerial photography, external orientation elements in the object coordinate system corresponding to the aerial photography, survey area division information and digital elevation model (DEM) within the survey area; S2, organizing data, includes the following steps: S2-1, calculate the main azimuth α and average ground height Z of each survey area avg The main azimuth angle α is the angle between the flight direction of the first survey line in the corresponding survey area and the true north direction. The average ground height Z avg It is obtained by averaging the elevation values in the digital elevation model DEM; S2-2, construct stereo image pair S <P l ,P r >, P l represents the left aerial image in the stereo pair, P r Indicates the right aerial photography image in the stereoscopic image pair, and the left aerial photography image and the right aerial photography image have overlapping parts; S3, making stereoscopic film: S3-1, calculate parallax: For each stereo pair S <P l ,P r >, first construct a virtual object point in the object coordinate system, the elevation value of the virtual object point is the average ground height Z of the survey area avg , and then project them to the image coordinate system of the left and right aerial photographs respectively to obtain the parallax of the left and right aerial photographs; S3-2, using the parallax obtained in S3-1 to merge the left and right aerial photographs in the stereoscopic image pair into a stereoscopic film; S3-3, calculating geographic transformation parameters, includes the following steps: S3-3-1, calculating the coordinates of all corner points of the stereoscopic film in the object coordinate system: S3-3-2, coordinate system transformation of the stereo film is as follows: Among them, (x col ,y row ) is the coordinate of a point on the stereoscopic film in the image coordinate system, wherein the image coordinate system is a coordinate system with the upper left corner of the stereoscopic film as the origin and pixels as the unit; (X p ,Y p ) are the coordinates of the points on the stereoscopic film in the object coordinate system; G0-G5 are affine transformation parameters used to transform the coordinates of the points on the stereoscopic film; Substitute the coordinates of the corner points of the aerial photograph obtained in S3-3-1 in the object coordinate system and their coordinates in the image coordinate system of the corresponding stereo film into the above formula, solve the affine transformation parameters, and use the obtained affine transformation parameters to transform the points on the corresponding stereo film into the object coordinate system; S4, associating railway line position data, specifically includes the following steps: S4-1, associating the coordinate data of the railway mileage point with the stereoscopic image, so as to query the stereoscopic image or the railway mileage point; S4-2, Railway line projection drawing: Project and connect the railway mileage points contained in each stereoscopic film so that the railway line position can be observed in the stereoscopic film; S4-3, perform three-dimensional film color change: Set the band of the stereo film obtained in S3-2 to (R l ,G r ,B r ), where R l The red band of the aerial photography image on the left, G r , B r They are the green and blue bands of the aerial photography image on the right, and a red and blue stereo film with railway mileage point projection lines is obtained; S5, 3D scene map service release: First, the red and blue stereoscopic film with railway mileage point projection lines obtained by S4 is used to make map tiles; then the stereoscopic scene is displayed through the visual map engine.
2. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 1, characterized in that: The survey area division information in S1 includes the survey area range, the survey lines included in the survey area, the information of the aerial photography images included in each survey line and the actual aerial photography order; the grid resolution of the digital elevation model DEM is ≤30m, and the elevation system of the digital elevation model DEM is consistent with the elevation system in the exterior orientation elements of the aerial photography images; the railway line position data includes the railway name, mileage range, broken chain division, and railway mileage points; among them, the railway mileage point includes the mileage value corresponding to the point and the coordinates in the object coordinate system; the selection of mileage points is determined according to actual working conditions.
3. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 1, characterized in that: S2-1 Calculate the average ground height Z by the following formula avg : Among them, Z g It represents the elevation value of the grid point of the digital elevation model DEM in S1, g represents the number of the grid point, g∈[1,G].
4. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 1, characterized in that: S2-2 constructs a stereo pair S <P l ,P r The method of < is: The aerial image in S1 is i is the number of the survey line, and n is the number of the aerial photography image on the survey line i; When i is an odd number, the set of stereo pairs constructed is: When i is an even number, since the flight direction is opposite to the odd-numbered survey line, the constructed stereo image pair set is: Wherein, m is a positive integer greater than 0; a is the number of aerial photographs between two stereo pairs, and the following formula is available: Where, o is the heading overlap rate of the aerial photography images, Indicates rounding down; The aerial photographs in each survey area are matched one by one to obtain a stereo pair set, which includes several stereo pairs S <P l ,P r >.
5. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 1, characterized in that: The specific method of calculating the parallax in step S3-1 is: First, establish a virtual object point P v : The plane coordinates of the virtual object point are the midpoint of the line connecting the photography centers of the left and right aerial photographs in the stereo image pair; In the stereo pair S <P l ,P r >, the exterior orientation elements of the aerial image on the left are The exterior orientation elements of the aerial image on the right are The internal orientation element is IOP(x0,y0,f), where (X l ,Y l ,Z l ) and (X r ,Y r ,Z r ) is the coordinate of the photography center of the corresponding aerial image in the object coordinate system, and It describes the aerial attitude angle of the aerial photography image plane at the moment of photography; x0, y0 are the positions of the image principal point relative to the image center, and f is the vertical distance from the lens center to the image plane; Use the following formula to calculate the virtual object point P v The coordinates (X v ,Y v ,Z v ): Then, the virtual object point P is calculated according to the following formula: v Projection coordinates in the image coordinate system of the left or right aerial photography image: Wherein, D is l or r; Solve by the following formula: Finally, use the virtual object point P v The projection coordinates of the left and right aerial photographs in the image coordinate system are calculated by the following formula to obtain the disparity p of the corresponding stereo image pair S: x and p y :
6. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 5, characterized in that: S3-3-1 is specifically: using the following formula to solve the coordinates of the corner points of the stereoscopic film in the object coordinate system: Where j is the number of iterations, Represents the coordinates of the corner point t of the stereo film in the image coordinate system of the corresponding left-side aerial photography image; Indicates the coordinates of the corner point t of the jth iteration in the object coordinate system; t is the number of the corner point, 1≤t≤4, First, the average ground height Z of the survey area is used avg As the initial elevation of corner point t Substituting into the above formula, the coordinates are calculated as Then the coordinates Interpolate the digital elevation model DEM in S1 to get the corresponding elevation value Finally, you will get Substituting into the above formula, we get the coordinates Continue iterating until and and The iteration error is less than 0.1 meters, and the accurate coordinates of the corner point t in the object coordinate system are obtained.
7. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 5, characterized in that: Step S4-2 is specifically as follows: First, for each stereo image pair, all the railway mileage points covered by it are found, and the coordinates (X w ,Y w ,Z w ) are transformed into the coordinates (x l,w ,y l,w ) and (x r,w ,y r,w ): Then connect the railway mileage points with their corresponding positions on the left and right aerial photographs, delete the connection lines that only exist on one side of the aerial photograph, and obtain the railway mileage point projection connection lines; among which, the connection line corresponding to the left aerial photograph is drawn in red, and the connection line corresponding to the right aerial photograph is drawn in cyan, which is a mixture of blue and green.
8. The method for producing railway three-dimensional geographic scene data service based on red-blue stereo film according to claim 1, characterized in that: The display of the stereoscopic scene is specifically as follows: according to the measurement area division information in S1, the layer setting is performed, each layer corresponds to the stereoscopic scene of a measurement area, and the default rotation angle of each layer is configured to be (90°-α). When the user views the layer, the layer is automatically rotated clockwise (90°-α), and the baseline direction of the stereoscopic film in the corresponding stereoscopic scene is kept consistent with the left and right direction of the binocular baseline to achieve a stereoscopic visual effect.
Citation Information
Patent Citations
Method for generating ortho-photo map of narrow and long region of border by digital photogrammetry system
CN110763205A
Rapid positioning and three-dimensional reconstruction method for dangerous falling rocks along railway
CN111540052A
Method for establishing building three-dimensional temperature model based on unmanned aerial vehicle infrared image
CN112381942A
Bursaphelenchus xylophilus recognition and positioning method based on multiple spectrums of unmanned aerial vehicle
CN118135441A
Three-dimensional image projection employing retro-reflective screens
CN1640153A