Method and device for determining boundary coordinates of building, intelligent terminal, computer readable storage medium and computer program product
By matching building outline templates with actual buildings using smart terminals and calculating the matching degree using pixel matrices, the problem of not being able to provide building boundary coordinates in existing technologies is solved, achieving higher-precision positioning and application expansion.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-18
- Publication Date
- 2026-03-27
AI Technical Summary
Existing map data cannot provide the boundary coordinates of buildings, which limits many application scenarios that rely on precise boundary coordinates, such as the inability to accurately calculate the actual distance between a user and a building and to determine which building a user has entered.
The target building is determined by the user's current coordinates through a smart terminal. The building outline template is matched with the actual building. By aligning the center coordinate points and the coverage area under multiple rotation angles, the matching degree is calculated based on the pixel matrix. The boundary coordinates of the outline template are directly used as the boundary coordinates of the building.
Precise quantification of the similarity between buildings and outline templates improves the reliability and positioning accuracy of building boundary coordinate determination, and expands the application scenarios of boundary coordinates, such as calculating distances and determining entry into buildings.
Smart Images

Figure CN121746482A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of smart terminal technology, and further to a method and apparatus for determining the boundary coordinates of a building, a smart terminal, a computer-readable storage medium, and a computer program product. Background Technology
[0002] With the development of mobile internet and IoT technologies, online map-based applications are becoming increasingly widespread. For example, existing technologies often analyze the similarity between a plot of land on a map and a preset plot model to achieve digital reconstruction of urban 3D scenes.
[0003] However, existing map data has significant deficiencies in terms of building boundary information. For example, current mainstream map service providers only provide the center coordinates of buildings, but cannot provide the boundary coordinates of buildings. Summary of the Invention
[0004] To address the aforementioned technical problems, this application provides a method and apparatus for determining building boundary coordinates, a smart terminal, a computer-readable storage medium, and a computer program product, which solves the problem that the prior art cannot provide the boundary coordinates of buildings.
[0005] In a first aspect, this application provides a method for determining the boundary coordinates of a building, applied to a smart terminal, comprising: determining a target building based on the user's current coordinates; determining a target building outline template based on the target building; aligning the center coordinate points of the target building and the target building outline template, and determining the target area on the map covered by the target building outline template under multiple rotation angles; determining a first matching degree and / or multiple second matching degrees of the target building and the target building outline template based on a first pixel matrix of the target area corresponding to each rotation angle and a second pixel matrix corresponding to the target building outline template; when there is a second matching degree greater than a first preset threshold among the multiple second matching degrees, and / or the first matching degree is greater than the first preset threshold, using the boundary coordinates of the target building outline template as the boundary coordinates of the target building.
[0006] The above method for determining building boundary coordinates identifies the target building based on the user's current coordinates. It then matches the target building's outline template with the actual building, aligning the center coordinates and determining the coverage area at multiple rotation angles. The matching degree is calculated based on the pixel matrix, precisely quantifying the similarity between the building and the outline template, providing a reliable basis for judgment. Finally, when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the building's boundary coordinates, solving the problem of existing technologies that cannot provide the building's boundary coordinates.
[0007] In one implementation, based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template, multiple second matching degrees of the target building and the target building outline template are determined. Specifically, this includes: determining the difference between corresponding pixels of each first pixel matrix and the second pixel matrix based on each first pixel matrix and the second pixel matrix; and determining the second matching degree corresponding to each rotation angle based on the difference between corresponding pixels and a second preset threshold.
[0008] In one implementation, a first matching degree between the target building and the target building outline template is determined based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template. Specifically, this includes: determining the difference between corresponding pixels of each first pixel matrix and the second pixel matrix based on each first pixel matrix and the second pixel matrix; determining the second matching degree corresponding to each rotation angle based on the difference between corresponding pixels and a second preset threshold; and performing a weighted summation of the second matching degrees corresponding to each rotation angle to determine the first matching degree.
[0009] The method described above for determining building boundary coordinates accurately quantifies the difference between the first pixel matrix of the target region and the second pixel matrix of the target building outline template at each rotation angle, providing a precise basis for calculating the matching degree. Simultaneously, a second matching degree corresponding to each rotation angle is determined based on these differences and a second preset threshold. Furthermore, a first matching degree is obtained by weighted summing of the second matching degrees at all rotation angles. When the first and / or second matching degrees meet the corresponding conditions, the boundary coordinates of the target building outline template can be used as the boundary coordinates of the target building. The setting of the first and second matching degrees not only improves the compatibility of this method but also enhances the reliability of determining the building boundary coordinates.
[0010] In one implementation, the method further includes: processing the target building and the target building outline template using an image matching algorithm to determine a first matching degree and / or multiple second matching degrees.
[0011] In one implementation, the target building is determined based on the user's current coordinates, specifically by: selecting multiple buildings from an area at a preset distance from the current coordinates; and selecting one building from the multiple buildings as the target building based on the user's movement direction or the distance between each building and the current coordinates.
[0012] In one implementation, it also includes: determining the distance between the user and the boundary of the target building based on the current coordinates and the boundary coordinates, and determining the target building into which the user enters the target building.
[0013] The method described above for determining building boundary coordinates identifies the target building based on the user's current coordinates. It matches the target building's outline template with the actual building, aligning the center coordinates and determining the coverage area at multiple rotation angles. The matching degree is calculated based on the pixel matrix; when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the boundary coordinates of the target building. This method, after obtaining the target building's boundary coordinates, effectively expands the application scenarios of boundary coordinates, such as calculating distances and determining the target building a user is entering. Simultaneously, it significantly improves positioning accuracy.
[0014] Secondly, this application also provides an apparatus for determining the boundary coordinates of a building, applied to a smart terminal, comprising: a template selection module configured to: determine a target building based on the user's current coordinates; determine a target building outline template based on the target building; a matching degree determination module configured to: align the center coordinate points of the target building and the target building outline template, and determine the target area on the map where the target building outline template covers the target building under multiple rotation angles; determine a first matching degree or multiple second matching degrees between the target building and the target building outline template based on a first pixel matrix of the target area corresponding to each rotation angle and a second pixel matrix corresponding to the target building outline template; and a processing module configured to, when there is a second matching degree greater than a first preset threshold among the multiple second matching degrees, or when the first matching degree is greater than the first preset threshold, use the boundary coordinates of the target building outline template as the boundary coordinates of the target building.
[0015] Thirdly, this application provides a smart terminal, including a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the method for determining the boundary coordinates of a building, as implemented above.
[0016] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method for determining the boundary coordinates of a building according to any of the above implementations.
[0017] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method for determining the boundary coordinates of a building according to any of the above implementations.
[0018] Compared with the prior art, the present invention has at least one of the following beneficial effects:
[0019] 1. Determine the target building based on the user's current coordinates. Match the target building's outline template with the actual building, aligning the center coordinates and determining the coverage area at multiple rotation angles. Calculate the matching degree based on the pixel matrix, which can precisely quantify the similarity between the building and the outline template, providing a reliable basis for judgment. Finally, when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the boundary coordinates of the building, solving the problem of not being able to provide the building's boundary coordinates in existing technologies.
[0020] 2. By calculating the pixel differences between the first pixel matrix of the target region and the second pixel matrix of the target building outline template at each rotation angle, the differences between the two can be accurately quantified, providing a precise basis for calculating the matching degree. Simultaneously, the second matching degree corresponding to each rotation angle is determined based on these differences and a second preset threshold. Furthermore, the first matching degree is obtained by weighted summation of the second matching degrees at all rotation angles. When the first matching degree and / or the second matching degree meet the corresponding conditions, the boundary coordinates of the target building outline template can be used as the boundary coordinates of the target building. The setting of the first and second matching degrees not only improves the compatibility of this method but also enhances the reliability of determining the building boundary coordinates.
[0021] 3. Determine the target building based on the user's current coordinates. Match the target building's outline template with the actual building, aligning the center coordinates and determining the coverage area at multiple rotation angles. Calculate the matching degree based on the pixel matrix. When the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the boundary coordinates of the target building. This method, after obtaining the boundary coordinates of the target building, can effectively increase the application scenarios of boundary coordinates, such as calculating distances and determining the target building the user is entering. Simultaneously, it can significantly improve positioning accuracy. Attached Figure Description
[0022] The preferred embodiments will now be described in a clear and easy-to-understand manner, in conjunction with the accompanying drawings, to further explain the above-mentioned characteristics, technical features, advantages, and implementation methods of the present invention.
[0023] Figure 1 A flowchart illustrating a method for determining building boundary coordinates according to an embodiment of this application is shown;
[0024] Figure 2 This application provides a flowchart for determining a second matching degree according to an embodiment of the present application;
[0025] Figure 3 This invention provides a structural block diagram of a device for determining the coordinates of a building boundary according to an embodiment of the present application.
[0026] Figure 4 A structural block diagram of a smart terminal provided in an embodiment of this application is shown. Detailed Implementation
[0027] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the specific implementation methods of the present invention will be described below with reference to the accompanying drawings. Obviously, the drawings described below are merely some embodiments of the present invention. For those skilled in the art, other drawings and other implementation methods can be obtained based on these drawings without any creative effort.
[0028] To keep the drawings concise, each figure only schematically shows the parts relevant to the invention, and these do not represent the actual structure of the product. Furthermore, to facilitate understanding, in some figures, only one of components with the same structure or function is schematically depicted, or only one is labeled. In this document, "one" not only means "only one," but can also mean "more than one."
[0029] It should also be further understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0030] In this document, it should be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to fixed connections, detachable connections, or integral connections; they can refer to mechanical connections or electrical connections; they can refer to direct connections or indirect connections through an intermediate medium; and they can refer to the internal communication between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.
[0031] Furthermore, in the description of this application, the terms "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0032] It should be noted that the above embodiments can be freely combined as needed. The above are merely preferred embodiments of the present invention. It should be pointed out that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
[0033] With the development of mobile internet and IoT technologies, the application scenarios based on online maps are becoming increasingly widespread. Existing technologies often analyze the similarity between a plot of land on the map and a preset plot model. For example, the similarity between a plot of land and a preset plot model can be determined by Euclidean distance. When the similarity meets the conditions, the building model corresponding to the preset plot model can be placed on the corresponding plot, thereby realizing the digital reconstruction of the city's 3D scene on the map.
[0034] However, existing map data has significant shortcomings in terms of building boundary information. Currently, mainstream map service providers can only provide the center coordinates (such as latitude and longitude) of buildings, but not their boundary coordinates. This limits many applications that rely on precise boundary coordinates, such as the inability to accurately calculate the actual distance between a user and a building, or to determine whether the user entered the building from a specific building.
[0035] Therefore, this application provides a method for determining the coordinates of building boundaries to solve the technical problems existing in the prior art.
[0036] The following explanation is based on the accompanying diagram:
[0037] Reference Appendix Figure 1 The document illustrates a flowchart of a method for determining building boundary coordinates according to an embodiment of this application. This method is applied to smart terminals, such as… Figure 1 As shown, it includes:
[0038] S100 determines the target building based on the user's current coordinates, and determines the target building outline template based on the target building.
[0039] S110, align the center coordinates of the target building and the target building outline template, and determine the target area of the target building covered by the target building outline template on the map under multiple rotation angles.
[0040] S120, based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template, determine the first matching degree and / or multiple second matching degrees of the target building and the target building outline template.
[0041] S130, when there is a second matching degree greater than the first preset threshold among multiple second matching degrees, and / or the first matching degree is greater than the first preset threshold, the boundary coordinates of the target building outline template are used as the boundary coordinates of the target building.
[0042] Smart terminals may include, but are not limited to, smartphones, smartwatches, smart bracelets, smart glasses, and tablets. Smart terminals may or may not have positioning capabilities. That is, a smart terminal can achieve user location through positioning technologies such as GPS and BeiDou, or it can receive location data from other devices. This application does not limit the method of positioning implementation.
[0043] After obtaining the user's current coordinates (which have been converted from the Earth coordinate system to the map coordinate system), the smart terminal can determine the target building from the map provided by the map provider. Then, based on the type of the target building (e.g., residential, school, shopping mall, etc., if type information is available), the corresponding target building outline template can be loaded from the outline template library for that type. If the type of the target building is unknown, all types of outline template libraries are traversed. Each outline template library pre-generates templates at different scale levels (e.g., small, medium, large) to accommodate target buildings of different sizes.
[0044] Align the center coordinates of the target building and its outline template on the map, and rotate the outline template according to a preset rotation step (rotating it one full turn from 0° to 360°). With each rotation, the target area covered by the outline template at each rotation angle can be calculated based on the target building's center coordinates and the outline template's dimensions. This yields the target areas corresponding to all rotation angles. Extract pixel values from all target areas and the outline template, and binarize them to obtain a first pixel matrix and a second pixel matrix for each rotation angle. Calculate the absolute value of the difference between corresponding pixels in each first and second pixel matrix, and then calculate the percentage of pixels whose absolute difference is less than a second preset threshold. Use each percentage as the matching degree, which is the second matching degree between the target building and its outline template for each rotation angle. Weighted summation of the second matching degrees for each rotation angle yields the first matching degree.
[0045] When any of the second matching degrees is greater than the first preset threshold, or when the first matching degree is greater than the first preset threshold, the boundary coordinates of the target building outline template are used as the boundary coordinates of the target building. The first and second preset thresholds can be set according to user needs, and this application does not impose any restrictions.
[0046] This application's embodiments determine the target building based on the user's current coordinates. The target building's outline template is matched against the actual building, with the coverage area determined by center coordinate point alignment and multiple rotation angles. The matching degree is calculated based on the pixel matrix, enabling precise quantification of the similarity between the building and the outline template, providing a reliable basis for judgment. Finally, when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the building's boundary coordinates, solving the problem in existing technologies where the building's boundary coordinates cannot be provided.
[0047] In one embodiment of this application, when the second matching degree or the first matching degree meets the corresponding condition, the boundary coordinates of the target building outline template can be used as the boundary coordinates of the target building. For example, see Appendix Figure 2 This illustrates a flowchart of determining a second matching degree provided in an embodiment of this application. Figure 2 As shown, it includes:
[0048] S200, based on each first pixel matrix and the second pixel matrix, determine the difference between corresponding pixels in each first pixel matrix and the second pixel matrix.
[0049] S210, determine the second matching degree corresponding to each rotation angle based on the difference between corresponding pixels and the second preset threshold.
[0050] The first matching degree can be achieved based on the determination of the second matching degree. For example, the first matching degree can be determined by weighted summation of the second matching degrees corresponding to each rotation angle.
[0051] After obtaining the first pixel matrix and the second pixel matrix corresponding to each rotation angle, the absolute value of the difference between corresponding pixels in each first pixel matrix and the second pixel matrix is calculated. Then, the proportion of pixels whose absolute value of the difference in each first pixel matrix is less than a second preset threshold is calculated among all corresponding pixels in each first pixel matrix. Each proportion is used as the matching degree, which is the second matching degree between the target building and the target building outline template corresponding to each rotation angle. A weighted sum of the second matching degrees corresponding to each rotation angle yields the first matching degree.
[0052] When there is a second matching degree greater than the first preset threshold among all the second matching degrees, or when the first matching degree is greater than the first preset threshold, the boundary coordinates of the target building outline template are used as the boundary coordinates of the target building.
[0053] This embodiment of the application calculates the pixel difference between the first pixel matrix of the target region and the second pixel matrix of the target building outline template at each rotation angle, which can accurately quantify the difference between the two and provide a precise basis for calculating the matching degree. Simultaneously, a second matching degree corresponding to each rotation angle is determined based on these differences and a second preset threshold. Furthermore, a first matching degree is obtained by weighted summing of the second matching degrees at all rotation angles. When the first matching degree and / or the second matching degree meet the corresponding conditions, the boundary coordinates of the target building outline template can be used as the boundary coordinates of the target building. The setting of the first and second matching degrees not only improves the compatibility of this method but also enhances the reliability of determining the building boundary coordinates.
[0054] In one embodiment of this application, the method further includes: processing the target building and the outline template of the target building using an image matching algorithm to determine a first matching degree and / or multiple second matching degrees.
[0055] The second matching degree between the target building and its outline template at different rotation angles is directly calculated using an image matching algorithm (such as a convolutional neural network). Then, a weighted sum of multiple second matching degrees is performed to obtain the first matching degree. The image matching algorithm determines either the first matching degree or multiple second matching degrees, which also improves the compatibility of this method.
[0056] In one embodiment of this application, determining the target building based on the user's current coordinates specifically includes: selecting multiple buildings from an area at a preset distance from the current coordinates; and selecting one building from the multiple buildings as the target building based on the user's movement direction or the distance between each building and the current coordinates.
[0057] After obtaining the user's current coordinates, the smart terminal can select multiple buildings and their center coordinates from a map provided by the map provider, within a preset distance from the current coordinates. Then, based on the user's direction of movement, it can select one building from the multiple buildings as the target building. Alternatively, it can select the building closest to the current coordinates based on the distances between each building. This embodiment of the application demonstrates diverse selection methods and improves the user experience.
[0058] In one embodiment of this application, the method further includes: determining the distance between the user and the boundary of the target building based on the current coordinates and the boundary coordinates, and determining the target building in which the user enters the target building.
[0059] After obtaining the boundary coordinates of the target building, both the user's current coordinates and the target building's boundary coordinates can be converted to the Earth coordinate system. Then, based on the converted current and boundary coordinates, the distance between the user and the target building's boundary can be calculated, as well as the target building the user entered. For example, if the target building includes both Building A and Building B, the converted current and boundary coordinates can determine which building the user entered from.
[0060] This application embodiment determines the target building based on the user's current coordinates. It matches the target building's outline template with the actual building, aligning the center coordinates and determining the coverage area at multiple rotation angles. The matching degree is calculated based on the pixel matrix; when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the boundary coordinates of the target building. This method, after obtaining the boundary coordinates of the target building, effectively expands the application scenarios of boundary coordinates, such as calculating distances and determining the target building a user enters. Simultaneously, it significantly improves positioning accuracy.
[0061] Reference Appendix Figure 3 The diagram illustrates a structural block diagram of a device for determining building boundary coordinates according to an embodiment of this application. Figure 3 As shown, the device 300 includes: a template selection module 310, configured to: determine a target building based on the user's current coordinates; determine a target building outline template based on the target building; a matching degree determination module 320, configured to: align the center coordinate points of the target building and the target building outline template, and determine the target area on the map where the target building outline template covers the target building under multiple rotation angles; determine a first matching degree or multiple second matching degrees between the target building and the target building outline template based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template; and a processing module 330, configured to: when there is a second matching degree greater than a first preset threshold among the multiple second matching degrees, or when the first matching degree is greater than the first preset threshold, use the boundary coordinates of the target building outline template as the boundary coordinates of the target building.
[0062] This application's embodiments determine the target building based on the user's current coordinates. The target building's outline template is matched against the actual building, with the coverage area determined by center coordinate point alignment and multiple rotation angles. The matching degree is calculated based on the pixel matrix, enabling precise quantification of the similarity between the building and the outline template, providing a reliable basis for judgment. Finally, when the matching degree meets a preset threshold, the boundary coordinates of the outline template are directly used as the building's boundary coordinates, solving the problem in existing technologies where the building's boundary coordinates cannot be provided.
[0063] Reference Appendix Figure 4 This application also provides a smart terminal 400, which includes a memory 410, a processor 420, and a computer program stored in the memory 410. The processor 420 executes the computer program to implement the steps of the method for determining building boundary coordinates in any of the above embodiments.
[0064] The memory 410 can be non-volatile memory (NVM), such as, but not limited to, semiconductor non-volatile memory, disk storage, or optical storage. Semiconductor non-volatile memory includes, but is not limited to, read-only memory (ROM) or flash memory, such as mask ROM, programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), NAND flash memory, or NOR flash memory.
[0065] Memory 410 can also be volatile memory, such as random access memory (RAM). RAM includes, for example, static random-access memory (SRAM) or dynamic random-access memory (DRAM). DRAM includes, for example, synchronous dynamic RAM (SDRAM) or double data rate SDRAM (DDR). With the development of technology, DDR includes, but is not limited to, DDR1, DDR2, DDR3, ..., DDR5, and may also include future DDR6.
[0066] Processor 420 is a circuit with signal processing capabilities. In one example, the processor can be a circuit with instruction read and execute capabilities; such as a central processing unit (CPU), microcontroller unit (MCU), microprocessor unit (MPU), graphics processing unit (GPU), or digital signal processor (DSP). In another example, the processor can realize its processing capabilities through the logical relationships of hardware circuits, which can be fixed or reconfigurable; for example, the processor can be a dedicated processor, such as a processor implemented with an application-specific integrated circuit (ASIC), which realizes its processing capabilities through the design of the logical relationships between components within the circuit; or a processor implemented with a programmable logic device (PLD), which realizes its processing capabilities by configuring the logical relationships between logic devices through a configuration file; for example, a processor implemented with a field-programmable gate array (FPGA). In another example, the processor can be a hardware circuit designed for artificial intelligence, which can be understood as an ASIC, such as a neural network processing unit (NPU), tensor processing unit (TPU), deep learning processing unit (DPU), etc. This application is not limited to the type of processor.
[0067] The smart terminal used in this application embodiment is basically similar to the method embodiment, so the description is relatively simple. For relevant details, please refer to the description of the method embodiment.
[0068] This application also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the method for determining building boundary coordinates in any of the above embodiments.
[0069] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method for determining building boundary coordinates in any of the above embodiments.
[0070] It should be noted that the above embodiments can be freely combined as needed. The above are merely preferred embodiments of the present invention. It should be pointed out that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for determining the coordinates of a building boundary, applied to a smart terminal, characterized in that, include: Determine the target building based on the user's current coordinates; Based on the target building, determine the outline template of the target building; Align the center coordinates of the target building and the outline template of the target building, and determine the target area of the target building covered by the outline template of the target building on the map under multiple rotation angles; Based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template, determine the first matching degree and / or multiple second matching degrees between the target building and the target building outline template; When there is a second matching degree greater than a first preset threshold among multiple second matching degrees, and / or the first matching degree is greater than the first preset threshold, the boundary coordinates of the target building outline template are used as the boundary coordinates of the target building.
2. The method for determining building boundary coordinates according to claim 1, characterized in that, The step of determining multiple second matching degrees between the target building and the target building outline template based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template specifically includes: Based on each of the first pixel matrix and the second pixel matrix, determine the difference between corresponding pixels in each of the first pixel matrix and the second pixel matrix; The second matching degree corresponding to each rotation angle is determined based on the difference between the corresponding pixels and the second preset threshold.
3. The method for determining building boundary coordinates according to claim 1, characterized in that, The step of determining the first matching degree between the target building and the target building outline template based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template specifically includes: Based on each of the first pixel matrix and the second pixel matrix, determine the difference between corresponding pixels in each of the first pixel matrix and the second pixel matrix; Based on the difference between the corresponding pixels and the second preset threshold, the second matching degree corresponding to each rotation angle is determined; The first matching degree is determined by weighted summation of the second matching degree corresponding to each rotation angle.
4. The method for determining building boundary coordinates according to claim 1, characterized in that, Also includes: The target building and its outline template are processed by an image matching algorithm to determine the first matching degree and / or multiple second matching degrees.
5. The method for determining building boundary coordinates according to claim 1, characterized in that, The process of determining the target building based on the user's current coordinates specifically includes: Select multiple buildings from an area that is a preset distance away from the current coordinates; Based on the user's movement direction or the distance between each of the buildings and the current coordinates, select one building from the multiple buildings as the target building.
6. The method for determining building boundary coordinates according to any one of claims 1-5, characterized in that, Also includes: Based on the current coordinates and the boundary coordinates, determine the distance between the user and the boundary of the target building, and determine the target building in which the user enters the target building.
7. A device for determining the coordinates of a building boundary, applied to a smart terminal, characterized in that, include: The template selection module is configured to determine the target building based on the user's current coordinates. Based on the target building, determine the outline template of the target building; The matching degree determination module is configured to: align the center coordinates of the target building and the target building outline template, and determine the target area of the target building outline template covering the target building on the map under multiple rotation angles; and determine a first matching degree or multiple second matching degrees between the target building and the target building outline template based on the first pixel matrix of the target area corresponding to each rotation angle and the second pixel matrix corresponding to the target building outline template. The processing module is configured to use the boundary coordinates of the target building outline template as the boundary coordinates of the target building when there is a second matching degree greater than a first preset threshold among a plurality of second matching degrees, or when the first matching degree is greater than the first preset threshold.
8. A smart terminal, comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the steps of the method for determining building boundary coordinates as described in any one of claims 1-6.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the steps of the method for determining the boundary coordinates of a building as described in any one of claims 1-6.
10. A computer program product, comprising a computer program, characterized in that, When executed by a processor, the computer program implements the steps of the method for determining the boundary coordinates of a building as described in any one of claims 1-6.