Plane detection method and device, electronic equipment and storage medium
By introducing the logo in the area to be detected, and the fusion of the target plane based on the fusion method of the logo and the map point, the problem of poor plane in the number of map points in the existing technologies is insufficient or poor quality. Plane detection and higher accuracy.
Patent Information
- Application Number
- CN202411388121.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-30
- Publication Date
- 2025-01-28
AI Technical Summary
In the prior art, when generating planes based on map points, when the number of local map points is insufficient or the quality is poor, the generated planes may be poor or difficult to generate.
By introducing the logo in the area to be detected, the target plane is generated based on the fusion method of the logo and the map point, and the space position of the map point is optimized through the plane constraint.
It improves the effect of graphic detection, solves the problem of slow, slow expansion, and slow convergence of plane detection, speeding up the convergence speed of the map point, and improving the accuracy of the map point.
Smart Images

Figure CN119379790A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the computer field, and in particular to a plane detection method, device, electronic equipment and storage medium. Background Art
[0002] When a user wears or holds an augmented reality device and moves in space, the user obtains data about the surrounding environment through the perception sensors of the AR (Augmented Reality) device. The SLAM algorithm (Simultaneous Localization And Mapping) uses the perceived environmental data to add and update map points, and the plane method detects and updates the plane through the map points. However, due to the limitations of the SLAM hardware solution and software accuracy, there are problems such as slow plane detection, slow plane expansion, and slow plane convergence. Summary of the invention
[0003] The present disclosure provides a plane detection method, device, electronic device and storage medium to at least solve the above technical problems existing in the prior art.
[0004] According to a first aspect of the present disclosure, a plane detection method is provided, the method comprising: responding to a plane detection instruction, performing plane detection on an area to be detected, and acquiring a detection image and detection data of the area to be detected; determining a marker in the detection image based on the detection image; processing the detection image and the detection data based on a simultaneous positioning and mapping algorithm to determine a map point; and generating a target plane based on the marker and the map point.
[0005] In one possible implementation, the detection image and the detection data are processed based on the simultaneous positioning and mapping algorithm to determine the map points, including: determining the posture of the electronic device based on the detection image and the detection data; obtaining the feature points of the current frame based on the detection image; matching the feature points of the current frame with the feature points of the historical frame to obtain a feature point matching relationship; and determining the map points based on the posture of the electronic device and the feature point matching relationship.
[0006] In one possible implementation, generating a target plane based on the marker and the map point includes: generating an initial plane according to the marker; and expanding the initial plane according to the map point to generate a target plane.
[0007] In one possible implementation, after generating an initial plane according to the marker, the method further comprises: optimizing the spatial position of the map point by plane constraints.
[0008] In one possible implementation, the optimizing the spatial position of the map point by plane constraint includes: obtaining an imaging point corresponding to the map point on an imaging plane; determining a depth value of the map point according to a focal length of the electronic device, a pixel position of the imaging point on the imaging plane, and a physical position of the map point in a shooting coordinate system; determining a distance from the map point to the initial plane based on the depth value; and performing plane constraint processing on the distance.
[0009] According to a second aspect of the present disclosure, a plane detection device is provided, which includes: an acquisition module, which is used to respond to a plane detection instruction, perform plane detection on an area to be detected, and acquire a detection image and detection data of the area to be detected; a first determination module, which is used to determine a marker in the detection image based on the detection image; a second determination module, which is used to process the detection image and the detection data based on a simultaneous positioning and mapping algorithm to determine a map point; and a generation module, which is used to generate a target plane based on the marker and the map point.
[0010] In one possible implementation, the second determination module includes: a first determination submodule, used to determine the posture of the electronic device based on the detection image and the detection data; a first acquisition submodule, used to acquire feature points of the current frame based on the detection image; a matching submodule, used to match the feature points of the current frame with the feature points of the historical frame to obtain a feature point matching relationship; and a second determination submodule, used to determine the map point based on the posture of the electronic device and the feature point matching relationship.
[0011] In one possible implementation, the generation module includes: a first generation submodule, used to generate an initial plane according to the marker; and a second generation submodule, used to expand the initial plane according to the map points to generate a target plane.
[0012] In one possible implementation, the device further includes: an optimization module for optimizing the spatial position of the map point through plane constraints after an initial plane is generated according to the marker.
[0013] In one possible implementation, the optimization module includes: a second acquisition submodule, used to acquire the imaging point corresponding to the map point on the imaging plane; a third determination submodule, used to determine the depth value of the map point according to the focal length of the electronic device, the pixel position of the imaging point on the imaging plane and the physical position of the map point in the shooting coordinate system; the third determination submodule is also used to determine the distance from the map point to the initial plane based on the depth value; and a processing submodule, used to perform plane constraint processing on the distance.
[0014] According to a third aspect of the present disclosure, there is provided an electronic device, including:
[0015] at least one processor; and
[0016] a memory communicatively connected to the at least one processor; wherein,
[0017] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method described in the present disclosure.
[0018] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause the computer to execute the method described in the present disclosure.
[0019] The present invention discloses a plane detection method, device, electronic device and storage medium, which first responds to a plane detection instruction, performs plane detection on the area to be detected, obtains the detection image and detection data of the current detection area, then analyzes the detection image, determines the markers in the detection image, and processes the detection image and detection data based on a simultaneous positioning and map construction algorithm to determine the map points, and finally generates a target plane based on the markers and map points. The application of this method can solve the problem in the prior art that when a plane is generated based on map points, the generated plane is poor or difficult to generate when the number of map points is insufficient or the quality is poor. By introducing markers in the area to be detected and performing plane detection based on the fusion of markers and map points, the plane detection effect can be better, and adding distance constraints from map points to the plane to optimize the depth information of map points can accelerate the convergence speed of map points and improve the accuracy of map points.
[0020] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood by reading the detailed description below with reference to the accompanying drawings. In the accompanying drawings, several embodiments of the present disclosure are shown in an exemplary and non-limiting manner, in which:
[0022] In the drawings, the same or corresponding reference numerals represent the same or corresponding parts.
[0023] Figure 1 The schematic diagram shows the implementation process of a plane detection method according to an embodiment of the present disclosure. Figure 1 ;
[0024] Figure 2 The schematic diagram shows the implementation process of a plane detection method according to an embodiment of the present disclosure. Figure 2 ;
[0025] Figure 3 The schematic diagram shows the implementation process of a plane detection method according to an embodiment of the present disclosure. Figure 3 ;
[0026] Figure 4 A schematic diagram of a scenario for determining a depth value of a map point is shown;
[0027] Figure 5 A schematic diagram of a module of a plane detection device according to an embodiment of the present disclosure is shown;
[0028] Figure 6 A schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0029] In order to make the purpose, features, and advantages of the present disclosure more obvious and easy to understand, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present disclosure.
[0030] Figure 1 The schematic diagram shows the implementation process of a plane detection method according to an embodiment of the present disclosure. Figure 1 ,include:
[0031] Step 101, responding to a plane detection instruction, performing plane detection on a to-be-detected area, and acquiring a detection image and detection data of the to-be-detected area.
[0032] The plane detection method of the present application is applied to an electronic device, and the electronic device is an intelligent device with a display function, such as an intelligent wearable device, an augmented reality device, etc. When using the above electronic device, in order to make the user's scene interaction effect more realistic, a more accurate plane detection is usually required. When the electronic device receives a plane detection instruction, it responds to the plane detection instruction, and the plane detection instruction is used to instruct the electronic device to perform a plane detection. After the electronic device responds to the plane detection instruction, it performs a plane detection on the area to be detected, and obtains a detection image of the area to be detected through an image acquisition module in the electronic device, such as a camera, and obtains detection data of the area to be detected through a sensor module in the electronic device.
[0033] Among them, the situations where an electronic device is started, the display area of the electronic device changes, or a plane detection instruction is received from a user through a key, voice, etc. are all considered to have received a plane detection instruction. It should be noted that this application does not specifically limit the manner in which a plane detection instruction is received. As long as a plane detection is required, it can be considered to have received a plane detection instruction. For example, when an electronic device detects that a plane detection is required, it can also be considered to have received a plane detection instruction.
[0034] Step 102: Determine a marker in the detection image based on the detection image.
[0035] The marker is located in the area to be detected and is presented in the form of a two-dimensional image. The length, width and other size information of the two-dimensional image are known. After the image acquisition module of the electronic device captures the area to be detected to obtain a detection image, the marker in the detection image is determined.
[0036] Step 103: Process the detection image and detection data based on the simultaneous positioning and mapping algorithm to determine the map points.
[0037] The plane detection process is inseparable from the determination of map points. Therefore, this application needs to generate map points through a simultaneous positioning and map construction algorithm. The simultaneous positioning and map construction algorithm processes the detection image and detection data to determine the map points. The process of determining map points is a prior art and will not be repeated in this application.
[0038] Step 104, generating a target plane based on the landmarks and the map points.
[0039] After obtaining the map points, the plane can be generated directly based on the map points. However, when the device does not move sufficiently, the number of map points is small or the quality is poor, it is difficult to detect the plane, resulting in slow plane detection. Therefore, this application uses markers in the plane detection process, fuses map points and markers to generate the target plane, which can speed up the detection of the plane.
[0040] The present application first performs plane detection on the area to be detected by responding to a plane detection instruction, obtains a detection image and detection data of the area to be detected, obtains markers and map points in the detection image based on the detection image and the detection data, and finally generates a target plane based on the markers and map points. This can solve the problem in the prior art that when a plane is generated only based on map points, the generated plane is poor or difficult to generate when the number of map points is insufficient or the quality is poor. By introducing markers in the area to be detected and performing plane detection based on the fusion of markers and map points, the plane detection effect can be better.
[0041] In one possible implementation, Figure 2 As shown, based on the simultaneous positioning and mapping algorithm, the detection image and detection data are processed to determine the map points, including:
[0042] Step 201, determining the position and posture of the electronic device according to the detection image and the detection data;
[0043] Step 202, acquiring feature points of the current frame according to the detected image;
[0044] Step 203, matching the feature points of the current frame with the feature points of the historical frames to obtain a feature point matching relationship;
[0045] Step 204: determine the map point based on the posture of the electronic device and the matching relationship between the feature points.
[0046] The sensor in the electronic device is an inertial measurement unit (IMU). The detection data obtained by the inertial measurement unit is accelerometer data and gyroscope data, that is, angular velocity data. The position and posture of the electronic device can be calculated in real time based on the acceleration data, angular velocity data and detection image. The feature points of the current frame can be extracted from the detection image through the image processing algorithm, and then the feature points of the current frame are matched with the feature points of the historical frame corresponding to the historical detection image to obtain the matching relationship of the feature points. The position and matching relationship of the electronic device and the feature points are triangulated based on the coordinate system of the image acquisition module. After triangulation, the position of the feature points of the current frame in the coordinate system of the image acquisition module is calculated, and the feature points in the current frame can be converted into map points.
[0047] In one possible implementation, generating a target plane based on the markers and the map points includes: generating an initial plane according to the markers; and expanding the initial plane according to the map points to generate the target plane.
[0048] The marker recognition algorithm can be used to determine the marker and directly generate the initial plane. Marker recognition is specifically to find the area representing the same features as the detection image taken by the image acquisition module from the template library, and obtain the position of the identified area in the subsequent image by tracking. After the marker is identified, the initial plane can be directly generated by the generation algorithm. After the initial plane is generated, the generated initial plane can be expanded by the determined map points. Since the size information of the marker is determined, the initial plane identified by the marker is accurate. By generating the initial plane by the marker, the plane detection can be realized quickly and accurately, solving the problem of slow plane detection. When the electronic device continues to move, new map points will be generated. The initial plane can be expanded by the newly generated map points, speeding up the plane expansion.
[0049] In one possible implementation, after generating an initial plane according to the marker, the method further includes: optimizing the spatial position of the map point by plane constraints.
[0050] After generating the initial plane based on the marker and obtaining the map points, the spatial position of the map points can be optimized through plane constraints. Since the depth information of the map points in the area covered by the marker is accurate, the convergence of the map points can be accelerated through plane constraints, which can further accelerate the convergence of the plane and make the presented target plane better.
[0051] Further, such as Figure 3 and Figure 4 As shown in the figure, the spatial position of the map points is optimized through plane constraints, including:
[0052] Step 301, obtaining the imaging point corresponding to the map point on the imaging plane;
[0053] Step 302, determining a depth value of the map point according to the focal length of the electronic device, the pixel position of the imaging point on the imaging plane, and the physical position of the map point in the shooting coordinate system;
[0054] Step 303, determining the distance from the map point to the initial plane based on the depth value;
[0055] Step 304: Perform plane constraint processing on the distance.
[0056] Figure 4 The following is a schematic diagram of a scene for determining the depth value of a map point. Figure 4 As shown in the figure, taking the image acquisition module as a camera as an example, based on the pinhole camera projection model, let Oxyz be the camera coordinate system, where the z axis is the coordinate axis pointing to the front of the camera, the x axis is the coordinate axis pointing to the right, the y axis is the coordinate axis pointing downward, and O is the optical center of the camera. Determine the map point P in the space, and after projection, it falls on the imaging plane, and its corresponding imaging point is P ′ , through the principle of similar triangles, the depth value of the map point can be determined, specifically: Where z is the depth value of the map point P in the camera coordinate system, f is the focal length of the camera, and X is the position of the map point on the x-axis of the camera coordinate system, which can be obtained through the size information of the landmark. ′ is the pixel position of the imaging point on the imaging plane. The plane of the initial plane can be expressed as: in is the unit normal vector of the initial plane, and d is the distance from the origin to the plane; therefore, the distance from the map point P to the initial plane is: where p T is the transposed vector representing the spatial position of the map point. The depth value of the map point obtained above is a dimension of the map point in the spatial position. is the unit normal vector of the initial plane, d is the distance from the origin to the plane, σ is the plane observation noise, and the σ value is 0 in an ideal state. The distance from the map point to the initial plane is constrained linearized to obtain Among them, H P is the Jacobian matrix of the map points, H Π is the Jacobian matrix of the initial plane, σ is the plane observation noise, is the error amount, representing the difference between the true state Z and the estimated state The difference between is the error of the map spatial position, which represents the difference between the real spatial position p of the map point and the estimated spatial position of the map point The difference between is the error of the initial plane, indicating the difference between the true initial plane Π and the estimated initial plane The difference. This solution uses the distance constraint from the map point to the initial plane to optimize the spatial position of the map point. Since the plane detected by the landmark is accurate, by adding the distance constraint from the map point to the initial plane and optimizing the depth information of the map point, it can be optimized directly in the direction of accurate depth, thereby accelerating the convergence speed of the map point and improving the accuracy of the map point. Map points with optimized spatial positions can be used for plane detection and updating. In areas with existing planes, they are mainly used for plane expansion, and in areas without planes, they are mainly used for plane detection. Plane detection can be achieved through clustering or RANSAC (Random Sample And Consensus) and other methods.
[0057] Figure 5 A module schematic diagram of a plane detection device according to an embodiment of the present disclosure is shown.
[0058] See also Figure 5 According to the second aspect of the present disclosure, a plane detection device is provided, and the device includes: an acquisition module 501, which is used to respond to a plane detection instruction, perform plane detection on an area to be detected, and obtain a detection image and detection data of the current detection area; a first determination module 502, which is used to determine a marker in a detection image based on the detection image; a second determination module 503, which is used to process the detection image and the detection data based on a simultaneous positioning and mapping algorithm to determine a map point; and a generation module 504, which is used to generate a target plane based on the marker and the map point.
[0059] In one embodiment, the second determination module 503 includes: a first determination submodule 5031, used to determine the posture of the electronic device based on the detection image and the detection data; a first acquisition submodule 5032, used to acquire the feature points of the current frame based on the detection image; a matching submodule 5033, used to match the feature points of the current frame with the feature points of the historical frame to obtain a feature point matching relationship; a second determination submodule 5034, used to determine the map point based on the posture of the electronic device and the feature point matching relationship.
[0060] In one embodiment, the generation module 504 includes: a first generation submodule 5041, used to generate an initial plane according to the marker; and a second generation submodule 5042, used to expand the initial plane according to the map points to generate a target plane.
[0061] In one possible implementation, the device further includes: an optimization module 505 for optimizing the spatial position of the map point through plane constraints after the initial plane is generated according to the marker.
[0062] In one embodiment, the optimization module 505 includes: a second acquisition submodule 5051, used to obtain the imaging point corresponding to the map point on the imaging plane; a third determination submodule 5052, used to determine the depth value of the map point according to the focal length of the electronic device, the pixel position of the imaging point on the imaging plane and the physical position of the map point in the shooting coordinate system; the third determination submodule 5053, also used to determine the distance from the map point to the initial plane based on the depth value; the processing submodule 5053, used to perform plane constraint processing on the distance.
[0063] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.
[0064] Figure 6 A schematic block diagram of an example electronic device 600 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0065] like Figure 6 As shown, the device 600 includes a computing unit 601, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the device 600 can also be stored. The computing unit 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0066] A number of components in the device 600 are connected to the I / O interface 605, including: an input unit 606, such as a keyboard, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a disk, an optical disk, etc.; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 609 allows the device 600 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0067] The computing unit 601 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 601 performs the various methods and processes described above, such as a plane detection method. For example, in some embodiments, a plane detection method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 608. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 600 via ROM 602 and / or communication unit 609. When the computer program is loaded into RAM 603 and executed by the computing unit 601, one or more steps of a plane detection method described above may be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to perform a plane detection method in any other appropriate manner (e.g., by means of firmware).
[0068] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0069] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0070] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0071] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0072] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0073] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0074] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0075] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0076] The above is only a specific embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present disclosure, which should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.
Claims
1. A plane detection method, characterized in that: The method comprises: In response to the plane detection instruction, perform plane detection on the area to be detected, and obtain the detection image and detection data of the area to be detected; determining a marker in the detection image based on the detection image; Processing the detection image and the detection data based on a simultaneous positioning and mapping algorithm to determine a map point; A target plane is generated based on the landmarks and the map points.
2. The method according to claim 1, characterized in that: The processing of the detection image and the detection data based on the simultaneous positioning and mapping algorithm to determine the map points includes: Determining the position and posture of the electronic device according to the detection image and the detection data; Acquire feature points of the current frame according to the detection image; Match the feature points of the current frame with the feature points of the historical frame to obtain a feature point matching relationship; The map points are determined based on the position and posture of the electronic device and the matching relationship between the feature points.
3. The method according to claim 1, characterized in that The generating a target plane based on the marker and the map point comprises: generating an initial plane according to the marker; The initial plane is expanded according to the map points to generate a target plane.
4. The method according to claim 3, characterized in that After generating an initial plane according to the marker, the method further comprises: optimizing the spatial position of the map point by plane constraints.
5. The method according to claim 4, characterized in that The optimizing the spatial position of the map point by plane constraint includes: Obtaining an imaging point corresponding to the map point on the imaging plane; Determining a depth value of the map point according to a focal length of the electronic device, a pixel position of the imaging point on the imaging plane, and a physical position of the map point in a shooting coordinate system; Determining a distance from the map point to the initial plane based on the depth value; A plane constraint is performed on the distance.
6. A plane detection device, characterized in that: The device comprises: An acquisition module is used to respond to a plane detection instruction, perform plane detection on the area to be detected, and obtain a detection image and detection data of the area to be detected; A first determination module, configured to determine a marker in the detection image based on the detection image; A second determination module is used to process the detection image and the detection data based on a simultaneous positioning and mapping algorithm to determine a map point; A generation module is used to generate a target plane based on the marker and the map point.
7. The device according to claim 6, characterized in that The second determining module includes: A first determination submodule, used to determine the position and posture of the electronic device according to the detection image and the detection data; An acquisition module, used for acquiring feature points of the current frame according to the detection image; A matching module is used to match the feature points of the current frame with the feature points of the historical frames to obtain a feature point matching relationship; The second determination submodule is used to determine the map point based on the posture of the electronic device and the matching relationship between the feature points.
8. The device according to claim 6, characterized in that The generating module comprises: A first generating submodule, used for generating an initial plane according to the marker; The second generating submodule is used to expand the initial plane according to the map points to generate a target plane.
9. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 5.
10. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-5.