Visual relocalization method, device and computer equipment based on scene semantic graph
By establishing a global scene semantic map and combining semantic information and structural information for similarity matching, the problem of low accuracy and efficiency in visual relocation technology is solved, especially in areas with weak textures, achieving higher positioning accuracy and efficiency.
Patent Information
- Application Number
- CN202410609427.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-16
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2044-05-16
AI Technical Summary
Existing visual relocation technology suffers from poor accuracy and low efficiency, especially in complex scenes where areas with weak textures are difficult to accurately locate.
By establishing a global scene semantic graph based on machine learning semantic segmentation and instance segmentation, combining semantic information and structural information, similarity matching is performed on the scene graph of the current frame, candidate matching frames are extracted, and pose calculation is performed to achieve visual relocation. .
Significantly improves the accuracy and efficiency of visual relocation, especially in areas with weak textures, providing more reliable positioning results and adapting to the needs of complex scenes.
Smart Images

Figure CN118196448B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data processing, and in particular to a visual relocalization method, device, computer equipment and storage medium based on a scene semantic graph. Background Art
[0002] Visual relocalization is an important technology in the field of computer vision, which aims to determine the exact position of a camera, robot or other mobile device in an unknown environment through image data. This technology plays a key role in automation, navigation, virtual reality and augmented reality.
[0003] However, current visual relocalization suffers from technical problems of poor accuracy and low efficiency, which have not yet been solved. Summary of the invention
[0004] The main purpose of the present invention is to provide a visual relocalization method, device, computer equipment and storage medium based on scene semantic graph.
[0005] To achieve the above-mentioned purpose, the present invention provides a visual relocalization method based on a scene semantic graph, comprising: obtaining a global scene semantic graph established by semantic segmentation and instance segmentation based on machine learning; performing image acquisition processing on the target scene to obtain a scene graph of the current frame, and constructing the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame; performing similarity matching on the scene semantic graph of the current frame and the global scene semantic graph, and extracting candidate matching frames from the global scene semantic graph; and performing pose calculation on the scene semantic graph of the current frame in combination with the candidate matching frames in the global scene semantic graph to achieve visual relocalization.
[0006] Furthermore, before obtaining a global scene semantic map established based on semantic segmentation and instance segmentation by machine learning, the visual relocalization method includes: pre-acquiring multiple frames of scene images of the target scene; constructing the multiple frames of scene images of the target scene based on semantic segmentation and instance segmentation by machine learning to obtain the global scene semantic map.
[0007] Furthermore, multiple frames of scene images of the target scene are constructed based on semantic segmentation and instance segmentation of machine learning to obtain the global scene semantic graph, including: identifying the object category in each frame of the scene image to obtain a label list for each frame of the scene image, wherein the label list records the text labels of the objects in the scene image, and the text labels record the object categories; detecting the object position in each frame of the scene image, and combining the label list of each frame of the scene image to obtain a 3D bounding box and text label for each object instance; based on the multiple frames of the scene image of the target scene, combined with the 3D bounding box and text label of each object instance, each object instance is used as a node of the global scene semantic graph, and the edge relationship between nodes is constructed to generate a global scene semantic graph of the target scene.
[0008] Furthermore, the object position in each frame of the scene image is detected, and combined with the label list of each frame of the scene image, a 3D bounding box and a text label of each object instance are obtained, including: detecting the object position in each frame of the scene image to obtain a 2D bounding box of the object in each frame of the scene image; fusing the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image, and combining the point cloud distance algorithm to obtain the 3D bounding box and text label of each object instance.
[0009] Furthermore, similarity matching is performed on the scene semantic graph of the current frame and the global scene semantic graph, and candidate matching frames are extracted from the global scene semantic graph, including: feature extraction is performed on the scene semantic graph of the current frame and the global scene semantic graph to obtain key features in the scene semantic graph of the current frame and key features of each frame of scene image in the global scene semantic graph; based on the extracted key features, similarity values between the scene semantic graph of the current frame and each frame of scene image in the global scene semantic graph are calculated; based on the calculated similarity values, a preset number of scene image frames are screened out in the global scene semantic graph from high to low as candidate matching frames.
[0010] Furthermore, in combination with the candidate matching frames in the global scene semantic graph, the scene semantic graph of the current frame is subjected to pose calculation to achieve visual repositioning, including: performing feature extraction and matching processing on the scene semantic graph of the current frame and the candidate matching frames to establish a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph; upon successfully establishing a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph, performing pose calculation based on the 2D-3D matching relationship to achieve visual repositioning.
[0011] Furthermore, after performing feature extraction and matching processing on the scene semantic map of the current frame and the candidate matching frames to establish a 2D-3D matching relationship between the scene semantic map of the current frame and the global scene semantic map, the visual repositioning also includes: in the event that the 2D-3D matching relationship between the scene semantic map of the current frame and the global scene semantic map is not successfully established, screening out the scene image frame with the highest similarity value from the multiple candidate matching frames to perform pose calculation to achieve visual repositioning.
[0012] The present invention also provides a visual relocalization device based on a scene semantic graph, comprising: an acquisition unit, used to acquire a global scene semantic graph established based on semantic segmentation and instance segmentation of machine learning; a construction unit, used to perform image acquisition processing on the target scene to obtain a scene graph of the current frame, and to construct the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame; a screening unit, used to perform similarity matching on the scene semantic graph of the current frame and the global scene semantic graph, and to extract candidate matching frames from the global scene semantic graph; and a relocalization unit, used to perform pose calculation on the scene semantic graph of the current frame in combination with the candidate matching frames in the global scene semantic graph to achieve visual relocalization.
[0013] The present invention also provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of any one of the above methods when executing the computer program.
[0014] The present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned methods are implemented.
[0015] The present invention provides a method, device, computer equipment and storage medium for visual relocalization based on scene semantic graph, which innovatively introduces scene semantic graph in the field of visual relocalization, thereby achieving a deeper understanding of the scene. By making full use of the semantic information and structural information of the scene semantic graph, higher accuracy is achieved when implementing visual relocalization. This indicates that for real-world scenes, the method not only focuses on traditional visual features, but also comprehensively considers the semantic information and structural information of the scene semantic graph, providing more comprehensive background knowledge for positioning tasks.
[0016] In this method, the similarity matching mechanism based on the scene semantic graph effectively improves the relocation accuracy of weak texture areas. By making full use of scene semantic information for matching, this method better adapts to areas with weak texture in complex scenes and provides more reliable positioning results for these areas. This innovation provides an effective technical solution to the traditional visual positioning problem caused by weak texture areas.
[0017] In summary, the present invention fully mines image information and improves the accuracy and efficiency of visual relocalization by combining a high-quality global scene semantic map acquired offline with a scene semantic map of the current frame acquired in real time. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 It is a schematic diagram of the steps of a visual relocalization method based on a scene semantic graph in one embodiment of the present invention;
[0019] Figure 2 It is a schematic flow chart of a visual relocalization method based on a scene semantic graph in one embodiment of the present invention;
[0020] Figure 3 It is a structural framework diagram of a visual relocalization device based on a scene semantic graph in one embodiment of the present invention;
[0021] Figure 4 It is a schematic block diagram of the structure of a computer device according to an embodiment of the present invention.
[0022] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0024] Reference Figure 1 , this embodiment provides a visual relocalization method based on a scene semantic graph, comprising the following steps:
[0025] S1, obtains a global scene semantic graph based on semantic segmentation and instance segmentation based on machine learning.
[0026] S2, performing image acquisition processing on the target scene to obtain a scene graph of the current frame, and constructing the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame.
[0027] S3, performing similarity matching on the scene semantic graph of the current frame and the global scene semantic graph, and extracting candidate matching frames from the global scene semantic graph.
[0028] S4, combining the candidate matching frames in the global scene semantic graph, and performing pose calculation on the scene semantic graph of the current frame to achieve visual relocalization.
[0029] It should be noted that the global scene semantic graph may be offline data, that is, offline data that has been downloaded to a local database.
[0030] It should be noted that: the scene graph of the current frame obtained by performing image acquisition processing on the target scene can be the scene graph of the current frame in the video image obtained by performing image acquisition processing on the target scene by a mobile device, wherein the mobile device can be a robot or other device.
[0031] That is, this embodiment provides an innovative visual relocalization method based on scene semantic graph, which aims to understand the real-world scene at a deeper level. First, a global scene semantic graph is established through semantic segmentation and instance segmentation based on machine learning in S1. Subsequently, similar processing is performed on the current frame through S2, which fully considers the semantic information and structural information to establish the scene semantic graph of the current frame.
[0032] In S3, similarity matching is performed through a graph convolutional neural network to extract candidate matching frames from the global scene semantic graph. This step improves the accuracy of matching with the help of scene semantic information, especially for areas with weak textures, providing more reliable matching results. Finally, in S4, pose calculation is performed in combination with candidate matching frames in the global scene semantic graph to achieve visual relocalization, making the overall method more comprehensive and adaptable, greatly improving the accuracy and efficiency of visual relocalization, and bringing significant progress to the field of visual relocalization.
[0033] In summary, this embodiment fully mines image information and improves the accuracy and efficiency of visual relocalization by combining a high-quality global scene semantic map acquired offline and a scene semantic map of the current frame acquired in real time.
[0034] In one example, before obtaining a global scene semantic graph established based on semantic segmentation and instance segmentation by machine learning, the visual relocalization method includes: pre-acquiring multiple frames of scene images of the target scene; constructing multiple frames of scene images of the target scene based on semantic segmentation and instance segmentation by machine learning to obtain the global scene semantic graph, and storing it. That is, the global scene semantic graph preset by the target scene can be pre-constructed and stored offline.
[0035] In one example, multiple frames of scene images of the target scene are constructed based on semantic segmentation and instance segmentation of machine learning to obtain the global scene semantic graph, including: identifying the object category in each frame of the scene image to obtain a label list for each frame of the scene image, wherein the label list records the text labels of the objects in the scene image, and the text labels record the object categories; detecting the object position in each frame of the scene image, and combining the label list of each frame of the scene image to obtain a 3D bounding box and text label for each object instance; based on the multiple frames of the scene image of the target scene, combined with the 3D bounding box and text label of each object instance, each object instance is used as a node of the global scene semantic graph, and the edge relationship between nodes is constructed to generate a global scene semantic graph of the target scene.
[0036] That is, this example constructs a global scene semantic graph of the target scene through multiple frames of scene images. First, the object category in each frame is identified and a label list is generated. Then, by detecting the position of the object in each frame and combining the label list, the 3D bounding box and text label information of each object instance are obtained. In the multi-frame scene images of the entire target scene, each object instance is used as a node of the global scene semantic graph, and the relationship between the nodes is established. This relationship is based on the spatial position and semantic relationship of the object instance, making full use of the scene semantic information and structural information. By integrating this information, a comprehensive global scene semantic graph is generated, which reflects the relationship between each object instance in the target scene.
[0037] In summary, this method achieves a more comprehensive and accurate modeling of the target scene by combining the location information and text labels in multiple frames of scene images. This way of constructing scene semantic graphs helps improve the relocalization accuracy because it makes full use of the multi-level relationships between various object instances in the scene, thereby providing richer information for visual relocalization.
[0038] In one example, the position of an object in each frame of a scene image is detected, and combined with a label list of each frame of the scene image, a 3D bounding box and a text label of each object instance are obtained, including: detecting the position of an object in each frame of the scene image to obtain a 2D bounding box of the object in each frame of the scene image; fusing the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image, and combining a point cloud distance algorithm to obtain a 3D bounding box and a text label of each object instance.
[0039] That is, this example implements a method for obtaining the 3D bounding box and text label of an object instance. First, the object in each frame of the scene image is identified through the object detection algorithm to obtain a 2D bounding box. Subsequently, the label list of each frame of the scene image is fused with the 2D bounding box of the object. This step successfully associates the text label of each object instance with the position information to form a complete object description, and combines it with the point cloud distance algorithm to obtain the 3D bounding box of each object instance, which provides key information for establishing a global scene semantic map and helps to improve the accuracy and precision of visual relocalization.
[0040] In one example, after detecting the position of an object in each frame of a scene image and obtaining a 2D bounding box of the object in each frame of the scene image, the method further includes: determining a mask of the object in each frame of the scene image based on the 2D bounding box of the object to further accurately describe the position information of the object.
[0041] In one example, the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image are fused, including: based on an image feature similarity calculation algorithm and a text label similarity calculation algorithm, the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image are fused.
[0042] For example: Figure 2 As shown, first, the recognize everything model is used to input the image, and the model outputs a list of labels for each frame of the scene image. Secondly, the grounding dino model is used to detect the 2D bounding box of each object category. Then, the SAM model is used to determine the pixel mask of the object in each frame of the scene image. Then, the processing results of each frame of the image are fused, and the 3D bounding box and corresponding label of each object instance are obtained by combining methods such as point cloud distance, clip image feature similarity, and text label similarity. Finally, using chatGPT's real-world general knowledge ability and the positional relationship of each object instance, the relationship between the edges of each node (ie: object instance) is constructed to generate a global scene semantic graph of the target scene.
[0043] In one example, similarity matching is performed on the scene semantic graph of the current frame and the global scene semantic graph, and candidate matching frames are extracted from the global scene semantic graph, including: feature extraction is performed on the scene semantic graph of the current frame and the global scene semantic graph to obtain key features in the scene semantic graph of the current frame and key features of each frame of scene image in the global scene semantic graph; based on the extracted key features, similarity values between the scene semantic graph of the current frame and each frame of scene image in the global scene semantic graph are calculated; based on the calculated similarity values, a preset number of scene image frames are screened out in the global scene semantic graph from high to low as candidate matching frames.
[0044] That is, in this example, a graph convolutional neural network is first used to extract features from the scene semantic graph of the current frame and the global scene semantic graph. This includes obtaining the key features in the scene semantic graph of the current frame and the key features of each frame of the scene image in the global scene semantic graph. GCN is used to effectively capture the relationships and structures in graphic data to extract semantic information. In this example, a GCN network can be used for feature extraction. Then, based on the extracted key features, the similarity values of the scene semantic graph of the current frame and each frame of the scene image in the global scene semantic graph are calculated. The purpose of this step is to quantify the similarity between the two and provide a numerical basis for subsequent matching. Next, based on the calculated similarity values, a preset number of scene image frames are selected from the global scene semantic graph from high to low as candidate matching frames. This step aims to select preset scene image frames with a high degree of similarity to the scene semantic graph of the current frame for subsequent matching processing.
[0045] In one example, in combination with the candidate matching frames in the global scene semantic graph, the scene semantic graph of the current frame is calculated for pose to achieve visual repositioning, including: performing feature extraction and matching processing on the scene semantic graph of the current frame and the candidate matching frames to establish a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph; in a case where the 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph is successfully established, performing pose calculation based on the 2D-3D matching relationship to achieve visual repositioning; in a case where the 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph is not successfully established, screening out the scene image frame with the highest similarity value from the multiple candidate matching frames for pose calculation to achieve visual repositioning.
[0046] In this example, local features of the scene semantic map of the current frame and the candidate matching frames are extracted and matched. This may use local feature descriptors, such as SIFT (Scale-Invariant Feature Transform), to capture key local information of the image. In the case of a successful match, a 2D-3D matching relationship between the scene semantic map of the current frame and the candidate matching frame is established based on the matching result, and the pose calculation is performed based on the established 2D-3D matching relationship to achieve visual relocation. In the case of a matching failure, the pose calculation is performed by screening the scene image frame with the highest similarity value among multiple candidate matching frames to achieve visual relocation. Such a strategy ensures the robustness and reliability of the system when processing scenes with weak texture areas.
[0047] In short, the whole process makes full use of global and local features, combined with the selection strategy of candidate matching frames, to provide a comprehensive and flexible solution for visual relocalization, which has good applicability to various challenges that may exist in actual scenes.
[0048] For example: Figure 2 As shown, the Scale-Invariant Feature Transform (SIFT) is used as a local feature extraction algorithm to extract and match local features of the scene semantic graph of the current frame and the candidate matching frame to establish a 2D-3D matching relationship between the scene semantic graph of the current frame and the candidate matching frame, and the RANSAC (Random Sample Consensus) algorithm is combined with the PnP (Perspective-n-Point) problem solution to further perform pose estimation calculations on the 2D-3D matching to achieve visual relocation. If the extraction and matching fails and the 2D-3D matching relationship between the scene semantic graph of the current frame and the candidate matching frame is not established, the scene image frame with the highest similarity value is selected from the multiple candidate matching frames for pose calculation to achieve visual relocation.
[0049] Among them, the SIFT algorithm can detect and describe key points in an image, and has the characteristics of scale and rotation invariance, so it remains stable when processing different scales and rotation transformations. RANSAC-PnP is a robust estimation method that can effectively deal with noise and outliers and improve the accuracy of pose estimation.
[0050] Reference Figure 3 , this embodiment provides a visual relocalization device based on a scene semantic graph, comprising:
[0051] An acquisition unit 1 is used to acquire a global scene semantic graph established based on semantic segmentation and instance segmentation by machine learning;
[0052] A construction unit 2 is used to perform image acquisition processing on the target scene to obtain a scene graph of the current frame, and to construct the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame;
[0053] A screening unit 3 is used to perform similarity matching between the scene semantic graph of the current frame and the global scene semantic graph, and extract candidate matching frames from the global scene semantic graph;
[0054] The relocation unit 4 is used to combine the candidate matching frames in the global scene semantic graph and perform pose calculation on the scene semantic graph of the current frame to achieve visual relocation.
[0055] In this embodiment, for the specific implementation of each unit in the above device embodiment, please refer to the above method embodiment, which will not be repeated here.
[0056] Reference Figure 4 In an embodiment of the present invention, a computer device is also provided. The computer device may be a server, and its internal structure may be as follows: Figure 4 As shown. The computer device includes a processor, a memory, a display screen, an input device, a network interface and a database connected through a system bus. Among them, the processor designed by the computer is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store the corresponding data in this embodiment. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, the above method is implemented.
[0057] Those skilled in the art will understand that Figure 4 The structure shown in the figure is merely a block diagram of a portion of the structure related to the solution of the present invention, and does not constitute a limitation on the computer device to which the solution of the present invention is applied.
[0058] An embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the above method is implemented. It can be understood that the computer-readable storage medium in this embodiment can be a volatile readable storage medium or a non-volatile readable storage medium.
[0059] The present invention provides a method, device, computer equipment and storage medium for visual relocalization based on scene semantic graph, which innovatively introduces scene semantic graph in the field of visual relocalization, thereby achieving a deeper understanding of the scene. By making full use of the semantic information and structural information of the scene semantic graph, higher accuracy is achieved when implementing visual relocalization. This indicates that for real-world scenes, the method not only focuses on traditional visual features, but also comprehensively considers the semantic information and structural information of the scene semantic graph, providing more comprehensive background knowledge for positioning tasks.
[0060] In this method, the similarity matching mechanism based on the scene semantic graph effectively improves the relocation accuracy of weak texture areas. By making full use of scene semantic information for matching, this method better adapts to areas with weak texture in complex scenes and provides more reliable positioning results for these areas. This innovation provides an effective technical solution to the traditional visual positioning problem caused by weak texture areas.
[0061] In summary, the present invention fully mines image information and improves the accuracy and efficiency of visual relocalization by combining a high-quality global scene semantic map acquired offline with a scene semantic map of the current frame acquired in real time.
[0062] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media provided by the present invention and used in the embodiments may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double-speed data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM.
[0063] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, device, article or method including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, device, article or method. In the absence of further restrictions, an element defined by the sentence "includes a ..." does not exclude the presence of other identical elements in the process, device, article or method including the element.
[0064] The above description is only a preferred embodiment of the present invention, and does not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made by using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A visual relocalization method based on scene semantic graph, characterized in that: The following steps are involved: Obtain a global scene semantic graph based on semantic segmentation and instance segmentation based on machine learning; Performing image acquisition processing on the target scene to obtain a scene graph of the current frame, and constructing the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame; Performing similarity matching on the scene semantic graph of the current frame and the global scene semantic graph, and extracting candidate matching frames from the global scene semantic graph; Combining the candidate matching frames in the global scene semantic graph, performing pose calculation on the scene semantic graph of the current frame to achieve visual relocalization; Among them, before obtaining a global scene semantic graph established by semantic segmentation and instance segmentation based on machine learning, the visual relocation method includes: pre-acquiring multiple frames of scene images of the target scene; identifying the object category in each frame of the scene image, and obtaining a label list for each frame of the scene image, wherein the label list records the text label of the object in the scene image, and the text label records the object category; detecting the position of the object in each frame of the scene image, and obtaining a 2D bounding box of the object in each frame of the scene image; fusing the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image, and combining the point cloud distance algorithm to obtain a 3D bounding box and text label of each object instance; based on the multiple frames of the scene image of the target scene, combined with the 3D bounding box and text label of each object instance, each object instance is used as a node of the global scene semantic graph, and the edge relationship between nodes is constructed to generate a global scene semantic graph of the target scene.
2. The visual relocation method according to claim 1, characterized in that: Performing similarity matching on the scene semantic graph of the current frame and the global scene semantic graph, and extracting candidate matching frames from the global scene semantic graph, including: Performing feature extraction on the scene semantic graph of the current frame and the global scene semantic graph to obtain key features in the scene semantic graph of the current frame and key features of each frame of scene image in the global scene semantic graph; Based on the extracted key features, calculating similarity values between the scene semantic graph of the current frame and each frame of the scene image in the global scene semantic graph; Based on the calculated similarity values, a preset number of scene image frames are screened out in the global scene semantic graph from high to low as candidate matching frames.
3. The visual relocation method according to claim 2, characterized in that: Combining the candidate matching frames in the global scene semantic graph, performing pose calculation on the scene semantic graph of the current frame to achieve visual relocalization, including: Performing feature extraction and matching processing on the scene semantic graph of the current frame and the candidate matching frame to establish a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph; When a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph is successfully established, pose calculation is performed based on the 2D-3D matching relationship to achieve visual repositioning.
4. The visual relocation method according to claim 3, characterized in that: After performing feature extraction and matching processing on the scene semantic graph of the current frame and the candidate matching frame to establish a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph, the visual relocalization further includes: In the case that a 2D-3D matching relationship between the scene semantic graph of the current frame and the global scene semantic graph is not successfully established, a scene image frame with the highest similarity value is selected from a plurality of candidate matching frames for pose calculation to achieve visual repositioning.
5. A visual relocalization device based on scene semantic graph, characterized in that: include: An acquisition unit, used to acquire a global scene semantic graph established based on semantic segmentation and instance segmentation by machine learning; A construction unit, configured to perform image acquisition processing on the target scene to obtain a scene graph of the current frame, and to construct the scene graph of the current frame based on semantic information and structural information to obtain a scene semantic graph of the current frame; A screening unit, configured to perform similarity matching between the scene semantic graph of the current frame and the global scene semantic graph, and extract candidate matching frames from the global scene semantic graph; A relocation unit, configured to calculate a pose of the scene semantic graph of the current frame in combination with the candidate matching frames in the global scene semantic graph to achieve visual relocation; The visual relocalization device is further used to: obtain multiple frames of scene images of the target scene before obtaining the global scene semantic map established by semantic segmentation and instance segmentation based on machine learning; construct the multiple frames of scene images of the target scene based on semantic segmentation and instance segmentation of machine learning to obtain the global scene semantic map; The visual relocalization device is further used to: identify the object category in each frame of the scene image, obtain a label list for each frame of the scene image, wherein the label list records the text label of the object in the scene image, and the text label records the object category; detect the object position in each frame of the scene image, and obtain a 3D bounding box and text label for each object instance in combination with the label list of each frame of the scene image; based on multiple frames of the target scene image, in combination with the 3D bounding box and text label of each object instance, take each object instance as a node of a global scene semantic graph, construct the edge relationship between nodes, and generate a global scene semantic graph of the target scene; Among them, the visual relocation device is also used to: detect the position of the object in each frame of the scene image to obtain the 2D bounding box of the object in each frame of the scene image; fuse the 2D bounding box of the object in each frame of the scene image and the label list of each frame of the scene image, and combine the point cloud distance algorithm to obtain the 3D bounding box and text label of each object instance.
6. A computer device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Visual semantic database construction and global positioning method based on deep learning
CN108830220A
Rapid repositioning method and device based on visual semantic information
CN110189373A
Repositioning method, repositioning device, storage medium and electronic equipment
CN111429517A
Target pose estimation method and device, computing equipment and storage medium
CN115222912A
Semantic tag fusion method and device, electronic equipment and storage medium
CN115601541A
