Automatically driving based visual positioning method and device, electronic equipment and storage medium

By acquiring ideal and current illuminance, controlling the vehicle's lighting status and adjusting camera parameters, the problem of strict illuminance requirements in the visual positioning of autonomous vehicles is solved, improving positioning accuracy and reducing hardware costs and space occupation.

CN116261037BActive Publication Date: 2025-11-21DONGFENG MOTOR GRP +1
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202111493501.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-08
Publication Date
2025-11-21
Estimated Expiration
2041-12-08

AI Technical Summary

Technical Problem

Existing autonomous vehicles require strict illumination requirements for visual positioning, necessitating the installation of illuminance meters, which increases hardware costs and space requirements. Furthermore, adjusting the illumination cannot guarantee positioning accuracy.

Method used

By acquiring the ideal illuminance and the current illuminance, the system controls the vehicle's lighting status and adjusts camera parameters to ensure that the difference between the visual positioning results is within a preset threshold.

Benefits of technology

No additional illuminance meter is required. By adjusting the lighting and camera parameters, the accuracy of visual positioning is improved, while reducing hardware costs and space occupation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116261037B_ABST
    Figure CN116261037B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a visual positioning method and device based on automatic driving, electronic equipment and storage medium, comprising: obtaining ideal illumination of vehicle automatic positioning, the ideal illumination is the illumination of the vehicle using the visual positioning algorithm to achieve the specified positioning accuracy; obtaining the first illumination of the current running environment of the vehicle; controlling the working state of the vehicle light according to the ideal illumination and the first illumination, and obtaining the second illumination of the vehicle in the working state; adjusting the camera parameters on the vehicle under the second illumination, so that the difference between the visual positioning result obtained based on the visual positioning algorithm and the visual positioning result under the ideal illumination is not greater than the first preset threshold. According to the ideal illumination and the first illumination of the current running environment of the vehicle, the working state of the vehicle light is controlled, and on this basis, the camera parameters on the vehicle are adjusted. Since the definition of the camera shooting photo is close to the photo obtained under the ideal illumination, the accuracy of the visual positioning result is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The embodiment of the application relates to the technical field of artificial intelligence, and particularly relates to a visual positioning method and device based on automatic driving, electronic equipment and a storage medium. BACKGROUND

[0002] In an automatic driving scene, an unmanned vehicle, such as an automatic driving taxi Robotaxi, usually adopts a visual positioning algorithm to automatically position the vehicle. However, when the visual positioning algorithm is used for automatic positioning, there is a strict requirement for the ambient light intensity. In order to ensure the accuracy of positioning, a light intensity meter is usually installed on the vehicle, and the opening or closing of the vehicle light is determined according to the ambient light intensity measured by the light intensity meter.

[0003] However, the installation of the light intensity meter on the vehicle increases the hardware cost and occupies the installation space of the vehicle accessories. On the other hand, even if the vehicle light is opened or closed, it cannot guarantee that the ambient light intensity promotes the VSLAM algorithm, so the existing light intensity adjustment method cannot guarantee the accuracy of positioning in the automatic driving scene. SUMMARY

[0004] The embodiment of the application provides a visual positioning method and device for automatic driving, electronic equipment and a storage medium, so as to realize accurate positioning in an automatic driving scene.

[0005] In a first aspect, the embodiment of the application provides a visual positioning method based on automatic driving, which comprises the following steps: acquiring ideal light intensity for automatic positioning of a vehicle, wherein the ideal light intensity is light intensity required by the vehicle to reach a specified positioning accuracy by using a visual positioning algorithm;

[0006] acquiring a first light intensity of a current running environment of the vehicle;

[0007] controlling a working state of a vehicle light according to the ideal light intensity and the first light intensity, and acquiring a second light intensity of the vehicle in the working state;

[0008] adjusting a camera parameter on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained based on the visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold.

[0009] In a second aspect, the embodiment of the application provides a visual positioning device based on automatic driving, which comprises: an ideal light intensity acquisition module configured to acquire ideal light intensity for automatic positioning of a vehicle, wherein the ideal light intensity is light intensity required by the vehicle to reach a specified positioning accuracy by using a positioning algorithm;

[0010] a first light intensity acquisition module configured to acquire a first light intensity of a current running environment of the vehicle;

[0011] The second light intensity acquisition module is configured to control a working state of vehicle light according to the ideal light intensity and the first light intensity, and acquire a second light intensity of the vehicle in the working state.

[0012] The adjusting module is configured to adjust a camera parameter on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained based on a visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold.

[0013] In a third aspect, an embodiment of the present application provides an electronic device, and the electronic device comprises:

[0014] one or more processors;

[0015] a storage device configured to store one or more programs,

[0016] When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described above.

[0017] In a fourth aspect, an embodiment of the present application provides a computer readable storage medium, and the computer readable storage medium stores a computer program, and the program is executed by a processor to implement the method as described above.

[0018] The technical scheme of the embodiment of the present application controls the working state of vehicle light according to the ideal light intensity and the first light intensity of the current running environment of the vehicle, and adjusts the camera parameter on the vehicle on this basis, so that the definition of the photo taken by the camera is close to the photo obtained under the ideal light intensity, and the accuracy of the visual positioning result is ensured. BRIEF DESCRIPTION OF DRAWINGS

[0019] In order to more clearly illustrate the technical scheme of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation to the scope, and for those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0020] Figure 1 is a flowchart of the visual positioning method based on automatic driving provided by the first embodiment of the present application;

[0021] Figure 2 is a flowchart of the visual positioning method based on automatic driving provided by the second embodiment of the present application;

[0022] Figure 3 is a structural schematic diagram of the visual positioning device based on automatic driving provided by the third embodiment of the present application;

[0023] Figure 4Fig. 1 is a structural schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0024] The present application will be further described below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are intended to be illustrative only and not limiting of the present application.

[0025] It should also be noted that, for the sake of brevity, the figures are not necessarily drawn to scale and that some embodiments are shown exaggerated in the figures. It should be further understood that the specific embodiments shown in the attached figures and described in the following detailed description are simply exemplary embodiments and should not be considered as limiting the scope of the application as there can be numerous other variations and modifications. For the most part, embodiments described in this detailed description do not construe any order to the execution of method steps or implementation of methods in any prescribed temporal order. Additionally, some of the embodiments described in this detailed description do not necessarily require any particular concurrency of method steps or implementation with respect to each other.

[0026] Embodiment One

[0027] Figure 1 Fig. 1 is a flowchart of a visual positioning method based on autonomous driving provided by an embodiment of the present application. The embodiment can be applicable to the case of safe autonomous driving based on a visual positioning algorithm in an autonomous driving scenario. The method can be executed by a visual positioning device based on autonomous driving in the embodiment of the present application, which can be implemented in software and / or hardware. As shown in Fig. 1, the method specifically includes the following operations: Figure 1

[0028] In step S101, an ideal illuminance for vehicle autonomous positioning is obtained.

[0029] The ideal illuminance is the illuminance for the vehicle to achieve a specified positioning accuracy using a visual positioning algorithm. The visual positioning algorithm in the embodiment includes any positioning algorithm based on vision, specifically an algorithm for positioning based on image acquisition by a camera or a camera. For example, a two-dimensional code is set on a driving path, and the two-dimensional code corresponds to a position information after being recognized. An image with the two-dimensional code is acquired by a camera, and an algorithm for recognizing the coordinate position of the two-dimensional code. Of course, the visual positioning algorithm also includes a Visual Simultaneous Localization And Mapping (VSLAM) algorithm, and thus the specific type of the visual positioning algorithm is not limited, and the VSLAM algorithm is mainly taken as an example for description in the embodiment.

[0030] ​Optionally, the ideal light intensity for vehicle automatic positioning is obtained by: obtaining multiple frames of pictures captured by a camera of the autonomous vehicle under at least two preset test light intensities, and a GPS positioning result corresponding to each frame of picture obtained by a Global Positioning System (GPS), determining a VSLAM algorithm positioning value of each frame of picture; screening at least one frame of screened picture with the smallest difference between the VSLAM algorithm positioning value and the GPS positioning result; and obtaining the ideal light intensity according to the test light intensity corresponding to the at least one frame of screened picture.

[0031] Specifically, an open road can be selected to test the autonomous vehicle to obtain the ideal light intensity. Multiple frames of pictures under different light intensities are collected by a camera on the vehicle. For example, the preset test light intensities are test light intensity A1, test light intensity A2 and test light intensity A3. Two frames of pictures a11 and a12 are captured by the camera under the test light intensity A1, three frames of pictures a21, a22 and a23 are captured by the camera under the test light intensity A2, and one frame of picture a31 is captured by the camera under the test light intensity A3. At the same time, the GPS positioning result corresponding to each frame of picture is obtained. In this embodiment, the GPS positioning result obtained under the condition of no occlusion has an error within the allowable error range (e.g., centimeter level), so as to ensure that the obtained GPS positioning result can be used as a positioning reference value with high reliability. After multiple frames of pictures under each test light intensity are obtained, the VSLAM algorithm positioning result of each frame of picture is determined based on the VSLAM algorithm. Since the specific method of determining the VSLAM algorithm positioning result based on the picture is not the focus of this application, it will not be described in detail in this embodiment. For each frame of picture, the GPS positioning result is used as a reference value to determine the VSLAM algorithm positioning value error of each frame of picture. At least one frame of screened picture with the smallest difference between the VSLAM algorithm positioning value and the GPS positioning result is screened, for example, the screened pictures obtained after screening are a11, a21 and a31.

[0032] In the embodiment, when the ideal illuminance is obtained according to the test illuminance corresponding to the screening picture, extreme values can be deleted first. For example, the test illuminance A1 corresponding to the screening picture a11 is 10, the test illuminance A2 corresponding to the screening picture a21 is 12, and the test illuminance A3 corresponding to the screening picture a31 is 22. Since the illuminance of the screening picture a31 is greatly different from those of the other screening pictures, the screening picture a31 is deleted. Then, the test illuminances corresponding to the remaining screening pictures a11 and a21 are averaged, and the obtained average value is taken as the ideal illuminance. Since the obtained average value is 11, the ideal illuminance obtained through the test is 11. Of course, the embodiment only exemplarily illustrates the method for obtaining the ideal illuminance, and does not limit the method for obtaining the ideal illuminance. As long as the ideal illuminance can be accurately obtained, it is within the protection scope of the application, and the embodiment does not limit the method for obtaining the ideal illuminance.

[0033] In step S102, the first illuminance of the current running environment of the vehicle is obtained.

[0034] Optionally, the first illuminance of the current running environment of the vehicle is obtained by detecting the illuminance of the current running environment of the vehicle through a photosensitive element on the vehicle, and obtaining the first illuminance according to the detection result.

[0035] Specifically, in the embodiment, the illuminance of the current running environment of the vehicle can be detected through the existing photosensitive element on the autonomous vehicle, and the first illuminance of the current running environment is directly obtained according to the detection result.

[0036] It should be noted that the photosensitive element in the embodiment is the existing element on the autonomous vehicle, and does not need to be additionally installed, so as to avoid the occupation of the internal space of the vehicle and the shortage of the internal space of the vehicle.

[0037] In step S103, the working state of the vehicle light is controlled according to the ideal illuminance and the first illuminance, and the second illuminance of the vehicle in the working state is obtained.

[0038] Optionally, the working state of the vehicle light is controlled according to the ideal illuminance and the first illuminance, and the second illuminance of the vehicle in the working state is obtained, including: judging whether the difference between the ideal illuminance and the first illuminance is less than a second preset threshold value, if yes, keeping the working state of the vehicle light unchanged, and taking the first illuminance as the second illuminance.

[0039] If not, when the first light intensity is greater than the ideal light intensity and it is determined that the vehicle light is in the on state, the vehicle light is turned off, and a third light intensity is obtained in the working state in which the vehicle light is turned off; when the first light intensity is less than the ideal light intensity and it is determined that the vehicle light is in the off state, the vehicle light is turned on, and a fourth light intensity is obtained in the working state in which the vehicle light is turned on; wherein the second light intensity is the first light intensity, the third light intensity or the fourth light intensity.

[0040] In the embodiment, when the working state of the vehicle light is controlled according to the ideal light intensity and the first light intensity, the working state of the vehicle light may or may not be switched: when it is determined that the working state of the vehicle light is not switched, the light intensity of the vehicle running environment does not change, so the second light intensity obtained in this case is the original first light intensity; when it is determined that the working state of the vehicle light is switched, the light intensity of the vehicle running environment is updated, so the second light intensity obtained in this case is the updated environmental light intensity.

[0041] Specifically, in actual application, the difference between the ideal light intensity and the first light intensity is compared with a second preset threshold value, which is set in advance in the embodiment. When it is determined that the difference is less than the second preset threshold value, the working state of the vehicle light does not need to be changed, i.e., the first light intensity is directly taken as the second light intensity as described above. For example, when the current environment is dark and the first light intensity is less than the ideal light intensity, the positioning error of the collected image can be less than the first preset threshold value by adjusting the camera parameters (increasing the aperture or prolonging the exposure time), which is equivalent to adjusting the light intensity, so the working state of the vehicle light does not need to be changed. In some embodiments, the adjustment range of the camera parameters needs to be considered when setting the second preset threshold value. Specifically, the light intensity that has the same positioning effect as the collected image under the current camera parameters is taken as the first equivalent light intensity, and then it is determined whether the difference between the ideal light intensity and the first light intensity is positive. If it is positive, the value of the camera parameter needs to be adjusted to the maximum, and the light intensity that has the same positioning effect as the collected image under the maximum adjustable camera parameter is taken as the second equivalent light intensity, and the second preset threshold value is determined according to the difference between the first equivalent light intensity and the second equivalent light intensity. If it is negative, the value of the camera parameter needs to be adjusted to the minimum, and the light intensity that has the same positioning effect as the collected image under the minimum adjustable camera parameter is taken as the second equivalent light intensity, and the second preset threshold value is determined according to the difference between the first equivalent light intensity and the second equivalent light intensity. Therefore, the second preset threshold value in the embodiment dynamically changes according to the actual situation of the current camera parameter.

[0042] When it is determined that the difference is greater than the second preset threshold, the working state of the vehicle light needs to be switched, and the specific switching manner needs to compare the first illuminance with the ideal illuminance, and determine according to the comparison result. For example, when the first illuminance is greater than the ideal illuminance and it is determined that the vehicle light is in the on state, it is indicated that the large positioning error is caused by the too large illuminance of the external environment, the vehicle light needs to be turned off, and the updated ambient illuminance obtained after the vehicle light is turned off, that is, the third illuminance, is taken as the second illuminance. When the first illuminance is less than the ideal illuminance and it is determined that the vehicle light is in the off state, it is indicated that the large positioning error is caused by the too small illuminance of the external environment, the vehicle light needs to be turned on, and the updated ambient illuminance obtained after the vehicle light is turned on, that is, the fourth illuminance, is taken as the second illuminance. From the above content, it can be known that the second illuminance in the embodiment is not unique, and is determined according to different scenes.

[0043] Step S104, adjusting the camera parameter on the vehicle under the second illuminance, so that the difference between the visual positioning result obtained based on the visual positioning algorithm and the visual positioning result under the ideal illuminance is not greater than the first preset threshold.

[0044] Among them, the camera parameter of the embodiment includes: the exposure time of the camera and the aperture size of the camera.

[0045] Optionally, adjusting the camera parameter on the vehicle under the second illuminance can include: when it is determined that the second illuminance is less than the ideal illuminance, lengthening the exposure time of the camera and / or enlarging the aperture size of the camera; when it is determined that the second illuminance is greater than the ideal illuminance, shortening the exposure time of the camera and / or reducing the aperture size of the camera.

[0046] Specifically, since the vehicle light adjustment is only to achieve a rough adjustment, there is still a slight error in the visual positioning based on the picture taken by the camera on the vehicle after the working state of the vehicle light is controlled and the second illuminance of the vehicle in the determined working state is obtained, so the camera parameters on the vehicle need to be further fine-tuned to achieve accurate visual positioning. That is, the second illuminance is kept unchanged, and according to the size comparison between the second illuminance and the ideal illuminance, the exposure time of the camera is extended and / or the aperture size of the camera is enlarged to supplement light for the taken picture, or the exposure time of the camera is shortened and / or the aperture size of the camera is reduced to reduce light, so that the picture taken by the camera is clearer, so that the difference between the visual positioning result obtained based on the visual positioning algorithm and the visual positioning result under the ideal illuminance is not greater than the first preset threshold, thereby further improving the accuracy of the visual positioning, and the first preset threshold is greater than the second preset threshold in the above step. Of course, the present embodiment only takes adjusting the exposure time and aperture size of the camera as an example for description, and the specific adjustment method of the camera is not limited in the present embodiment.

[0047] The technical scheme of the embodiment of the present application controls the working state of the vehicle light according to the ideal illuminance and the first illuminance of the current running environment of the vehicle, and adjusts the camera parameters on the vehicle on this basis. Since the clarity of the picture taken by the camera is close to the picture obtained under the ideal illuminance, the accuracy of the visual positioning result is ensured.

[0048] Embodiment two

[0049] Figure 2 is a flowchart of the visual positioning method based on automatic driving provided by the embodiment of the present application. Based on the above embodiment, the present embodiment specifically describes the acquisition of the second illuminance of the vehicle in the working state in the above step S103. The method steps specifically include the following operations:

[0050] Step S201: acquiring the image collected by the camera on the vehicle in the working state, and determining the pixel point with the maximum pixel value in the image.

[0051] It should be noted that in the present embodiment, the second illuminance of the vehicle in the working state can be acquired according to the image collected by the camera and the camera parameters, i.e. without the need to install an additional photosensitive element. After the working state of the vehicle light is controlled according to the ideal illuminance and the first illuminance, the image collected by the camera on the vehicle in the determined working state is acquired, the image is identified and analyzed to acquire the pixel value of each pixel point in the image, and each pixel point is compared and judged to screen out the pixel point with the maximum pixel value.

[0052] Step S202: determining the maximum total pixel value of the image based on the maximum pixel value and the number of pixel points.

[0053] The number of the pixel points with the maximum pixel value is determined, and based on the number of the pixel points with the maximum pixel value and the maximum pixel value, the maximum total pixel value of the image is determined, which can be specifically obtained by multiplying the pixel value corresponding to the pixel point with the maximum pixel value by the number of the pixel points, and taking the result as the maximum total pixel value of the image.

[0054] In step S203, the second light intensity of the vehicle in the working state is obtained according to the camera parameter and the maximum total pixel value.

[0055] In the embodiment, the camera parameter includes the exposure time of the camera and the aperture size of the camera. When the second light intensity of the vehicle in the working state is obtained, the obtained value can be calculated by using the following formulas (1) and (2):

[0056] Maximum total pixel value / exposure time=light flux (1)

[0057] Light flux / aperture size=light intensity (2)

[0058] It should be noted that, since the second light intensity in the embodiment is the first light intensity obtained before the switching of the vehicle light state, and the third light intensity or the fourth light intensity obtained after the switching of the vehicle light state, the above-mentioned method of obtaining the light intensity according to the collected image and the camera parameter is still effective for the method of obtaining the first light intensity of the vehicle in the current running environment in step S102 of the above-mentioned embodiment.

[0059] The technical scheme of the embodiment of the application controls the working state of the vehicle light according to the ideal light intensity and the first light intensity of the vehicle in the current running environment, and adjusts the camera parameter on the vehicle on this basis. Since the definition of the photo taken by the camera is close to the photo obtained under the ideal light intensity, the accuracy of the visual positioning result is ensured. In the embodiment, the light intensity of the vehicle running environment is obtained according to the image collected by the vehicle camera and the camera parameter, without the need for additional installation of a light meter or other equipment for detection, which is accurate and convenient, thereby further improving the accuracy of the visual positioning result.

[0060] Embodiment three

[0061] Figure 3 The structure schematic diagram of the visual positioning device based on automatic driving provided by the embodiment of the application is shown in the figure, which comprises an ideal light intensity obtaining module 310, a first light intensity obtaining module 320, a second light intensity obtaining module 330 and an adjusting module 340.

[0062] The ideal light intensity obtaining module 310 is used to obtain the ideal light intensity of the vehicle automatic positioning, wherein the ideal light intensity is the light intensity of the vehicle reaching the specified positioning accuracy by using the positioning algorithm.

[0063] The first light intensity acquisition module 320 is configured to acquire a first light intensity of a current running environment of the vehicle.

[0064] The second light intensity acquisition module 330 is configured to control a working state of a vehicle light according to the ideal light intensity and the first light intensity, and acquire a second light intensity of the vehicle in the working state.

[0065] The adjusting module 340 is configured to adjust a camera parameter on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained based on a visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold.

[0066] Optionally, the first light intensity acquisition module is specifically configured to detect the light intensity of the current running environment of the vehicle by using a photosensitive element on the vehicle.

[0067] The first light intensity is acquired according to a detection result.

[0068] Optionally, the second light intensity acquisition module is specifically configured to determine whether a difference between the ideal light intensity and the first light intensity is less than a second preset threshold, and if yes, keep the working state of the vehicle light unchanged, and take the first light intensity as the second light intensity.

[0069] If not, when the first light intensity is greater than the ideal light intensity and it is determined that the vehicle light is in an open state, the vehicle light is turned off, and a third light intensity is acquired in a working state in which the vehicle light is turned off.

[0070] When the first light intensity is less than the ideal light intensity and it is determined that the vehicle light is in a closed state, the vehicle light is turned on, and a fourth light intensity is acquired in a working state in which the vehicle light is turned on.

[0071] The second light intensity is the first light intensity, the third light intensity or the fourth light intensity.

[0072] Optionally, the second light intensity acquisition module is further configured to acquire an image collected by a camera on the vehicle in the working state, and determine a pixel point with a maximum pixel value in the image.

[0073] Based on the maximum pixel value and a number of the pixel points, a maximum total pixel value of the image is determined.

[0074] The second light intensity of the vehicle in the working state is acquired according to the camera parameter and the maximum total pixel value.

[0075] Optionally, the camera parameter includes an exposure time of the camera and an aperture size of the camera.

[0076] The second light intensity acquisition module, when acquiring the second light intensity of the vehicle in the working state according to the camera parameter and the maximum total pixel value, is specifically configured to determine the light flux according to the maximum total pixel value and the exposure time of the camera;

[0077] acquire the second light intensity of the vehicle in the working state according to the light flux and the aperture size of the camera.

[0078] Optionally, the adjusting module is specifically configured to, when determining that the second light intensity is less than the ideal light intensity, lengthen the exposure time of the camera and / or enlarge the aperture size of the camera;

[0079] when determining that the second light intensity is greater than the ideal light intensity, shorten the exposure time of the camera and / or reduce the aperture size of the camera

[0080] Optionally, the visual positioning algorithm includes a visual simultaneous localization and mapping (VSLAM) algorithm, and the ideal light intensity acquisition module is specifically configured to acquire a plurality of frames of pictures captured by the camera under at least two preset test light intensities of the autonomous vehicle, and a GPS positioning result corresponding to each frame of image acquired by a global positioning system (GPS),

[0081] determine a VSLAM algorithm positioning value of each frame of picture;

[0082] select at least one frame of screening picture with the smallest difference value between the VSLAM algorithm positioning value and the GPS positioning result;

[0083] acquire the ideal light intensity according to the test light intensity corresponding to the at least one frame of screening picture.

[0084] The device described above can execute the visual positioning method based on autonomous driving provided by any embodiment of the present application, has the function modules and beneficial effects corresponding to the execution method. Technical details not described in detail in the present embodiment can be referred to the method provided by any embodiment of the present application.

[0085] Embodiment Four

[0086] Figure 4 is a structural schematic diagram of an electronic device provided by an embodiment of the present application. Figure 4 A block diagram of an example electronic device 412 suitable for implementing an embodiment of the present application is shown. Figure 4 The electronic device 412 shown is merely an example and should not impose any limitation on the function and use range of the embodiments of the present application.

[0087] As Figure 4As shown, the electronic device 412 is in the form of a general- purpose computer. The components of the electronic device 412 can include, but are not limited to, one or more processors 416, a memory 428, and a bus 418 that connects the various system components, including the memory 428 and the processor 416.

[0088] The bus 418 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a graphics accelerator bus, a processor or local bus using any of a variety of bus architectures. By way of example, these architectures include an Industry Standard Architecture (ISA) bus, a Micro Channel Architecture (MAC) bus, an Enhanced ISA bus, a Video Electronics Standards Association (VESA) local bus, and a Peripheral Component Interconnect (PCI) bus.

[0089] The electronic device 412 typically includes a variety of computer system readable media. Such media can be any available media that is accessible by the electronic device 412 and includes both volatile and non- volatile media, removable and non-removable media.

[0090] The memory 428 is used for storing instructions. The memory 428 can include computer system readable media in the form of volatile memory, such as random access memory (RAM) 430 and / or cache memory 432. The electronic device 412 can further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, a storage system 434 can be provided for reading from and writing to non-removable, non-volatile magnetic media (e.g., a "hard drive"). Figure 4 Not shown, a removable / non-removable, volatile / non-volatile computer system storage medium can be used to store data including one or more programs and / or program modules. Figure 4 In these instances, each drive can be connected to the bus 418 by one or more data media interfaces. The memory 428 can include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the application.

[0091] A program / utility 440, having a set (at least one) of program modules 442, can be stored in, for example, memory 428 by way of example, such program modules 442 include an operating system, one or more application programs, other program modules, and program data, each of which or a combination can include implementation of a network environment. The program modules 442 generally carry out the functions and / or methodologies of embodiments of the application as described herein.

[0092] The electronic device 412 can also communicate with one or more external devices 414 such as a keyboard, a pointing device, a display 424, etc.; other devices that enable a user to interact with the electronic device 412; and / or any devices (e.g., a network card, a modem, a television tuner, etc.) that enable the electronic device 412 to communicate with one or more other computing devices. Such communication can occur via an input / output (I / O) interface 422. Still yet, the electronic device 412 can communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or the Internet) through a network adapter 420. As illustrated, the network adapter 420 communicates with the other components of the electronic device 412 via the bus 418. It should be appreciated that although the network adapter 420 is illustrated as a separate component, the network adapter 420 can be integrated with the bus 418 and / or one or more of the other components of the electronic device 412. Figure 4 Other hardware and / or software modules that can be used in conjunction with the electronic device 412, but are not illustrated in FIG. 4, include but are not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data archival storage systems, etc.

[0093] The processor 416 performs various functions through running instructions stored in the memory 428, such as implementing the method for automatic driving based visual positioning provided by the embodiments of the present application: obtaining an ideal light intensity for automatic positioning of a vehicle, wherein the ideal light intensity is a light intensity at which the vehicle reaches a specified positioning accuracy using a visual positioning algorithm; obtaining a first light intensity of a current running environment of the vehicle; controlling a working state of a vehicle light according to the ideal light intensity and the first light intensity, and obtaining a second light intensity of the vehicle in the working state; and adjusting a camera parameter on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained based on the visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold.

[0094] Embodiment five

[0095] The embodiments of the present application provide a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the method for automatic driving based visual positioning provided by all the embodiments of the present application.

[0096] The processor 416 performs various functions through running instructions stored in the memory 428, such as implementing the method for automatic driving based visual positioning provided by the embodiments of the present application: obtaining an ideal light intensity for automatic positioning of a vehicle, wherein the ideal light intensity is a light intensity at which the vehicle reaches a specified positioning accuracy using a visual positioning algorithm; obtaining a first light intensity of a current running environment of the vehicle; controlling a working state of a vehicle light according to the ideal light intensity and the first light intensity, and obtaining a second light intensity of the vehicle in the working state; and adjusting a camera parameter on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained based on the visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold.

[0097] Any combination of one or more computer readable medium can be utilized. The computer readable medium can be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium include: a portable computer diskette, 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 disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium can be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.

[0098] A computer readable signal medium can include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated signal can take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium can be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.

[0099] Program code embodied on a computer readable medium can be transmitted using any appropriate medium, including but not limited to wireless, wire line, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0100] Computer program code for carrying out operations of the present application can be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider). In an embodiment of the application, the remote computer can be a server or another desktop computer.

[0101] Note that the above merely describes preferred embodiments of the present application and the principles of the technology applied. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, modifications and substitutions can be made without departing from the scope of the present application. Therefore, although the present application has been described in detail through the above embodiments, the present application is not limited to the above embodiments, and can include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the claims.

Claims

1. A method for visual positioning based on automatic driving, characterized in that, The method comprises the following steps: acquiring an ideal light intensity for vehicle automatic positioning, wherein the ideal light intensity is a light intensity at which the vehicle reaches a specified positioning accuracy using a visual positioning algorithm, and the visual positioning algorithm comprises a visual simultaneous localization and mapping (VSLAM) algorithm; acquiring a first light intensity of a current operating environment of the vehicle; controlling a working state of vehicle light according to the ideal light intensity and the first light intensity, and acquiring a second light intensity of the vehicle in the working state; adjusting camera parameters on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained by the visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold value; the acquiring of the ideal light intensity for vehicle automatic positioning comprises: acquiring a plurality of frames of pictures captured by a camera on the vehicle under at least two preset test light intensities, and acquiring a global positioning system (GPS) positioning result corresponding to each frame of picture obtained by a GPS, determining a VSLAM algorithm positioning value of each frame of picture; screening at least one frame of screened picture with the smallest difference between the VSLAM algorithm positioning value and the GPS positioning result; acquiring the ideal light intensity according to a test light intensity corresponding to the at least one frame of screened picture.

2. The method of claim 1, wherein, the acquiring of the first light intensity of the current operating environment of the vehicle comprises: detecting the light intensity of the current operating environment of the vehicle by a photosensitive element on the vehicle; acquiring the first light intensity according to the detection result.

3. The method of claim 1, wherein, the controlling of the working state of the vehicle light according to the ideal light intensity and the first light intensity, and the acquiring of the second light intensity of the vehicle in the working state, comprises: judging whether a difference between the ideal light intensity and the first light intensity is less than a second preset threshold value, if yes, keeping the working state of the vehicle light unchanged, and taking the first light intensity as the second light intensity; if not, when the first light intensity is greater than the ideal light intensity and it is determined that the vehicle light is in an open state, closing the vehicle light, and acquiring a third light intensity in the working state in which the vehicle light is closed; when the first light intensity is less than the ideal light intensity and it is determined that the vehicle light is in a closed state, opening the vehicle light, and acquiring a fourth light intensity in the working state in which the vehicle light is opened; wherein the second light intensity is the first light intensity, the third light intensity or the fourth light intensity.

4. The method of claim 3, wherein, the acquiring of the second light intensity of the vehicle in the working state, comprises: acquiring an image captured by a camera on the vehicle in the working state, and determining a pixel point with the largest pixel value in the image; determining a maximum total pixel value of the image based on the maximum pixel value and the number of pixel points; acquiring the second light intensity of the vehicle in the working state according to the camera parameters and the maximum total pixel value.

5. The method of claim 4, wherein, the camera parameters comprise an exposure time of the camera and an aperture size of the camera; the acquiring of the second light intensity of the vehicle in the working state according to the camera parameters and the maximum total pixel value, comprises: determining a luminous flux according to the maximum total pixel value and the exposure time of the camera; acquiring the second light intensity of the vehicle in the working state according to the luminous flux and the aperture size of the camera.

6. The method of claim 4, wherein, adjusting camera parameters on the vehicle under the second light intensity, comprising: when it is determined that the second light intensity is less than the ideal light intensity, lengthening an exposure time of the camera and / or expanding an aperture size of the camera; when it is determined that the second light intensity is greater than the ideal light intensity, shortening an exposure time of the camera and / or reducing an aperture size of the camera.

7. An automatic driving based visual positioning device, characterized by, comprising: an ideal light intensity acquisition module, configured to acquire an ideal light intensity for vehicle automatic positioning, wherein the ideal light intensity is a light intensity under which the vehicle reaches a specified positioning accuracy by using a visual positioning algorithm, and the visual positioning algorithm comprises a visual simultaneous localization and mapping (VSLAM) algorithm; a first light intensity acquisition module, configured to acquire a first light intensity of a current operating environment of the vehicle; a second light intensity acquisition module, configured to control a working state of vehicle light according to the ideal light intensity and the first light intensity, and acquire a second light intensity of the vehicle under the working state; an adjustment module, configured to adjust camera parameters on the vehicle under the second light intensity, so that a difference between a visual positioning result obtained by using the visual positioning algorithm and a visual positioning result under the ideal light intensity is not greater than a first preset threshold value; the ideal light intensity acquisition module is configured to acquire a plurality of frames of pictures captured by a camera of an autonomous vehicle under at least two preset test light intensities, and acquire a global positioning system (GPS) positioning result corresponding to each frame of picture by using a GPS, determine a VSLAM algorithm positioning value of each frame of picture; screen at least one frame of screened picture with a minimum difference between the VSLAM algorithm positioning value and the GPS positioning result; and acquire the ideal light intensity according to a test light intensity corresponding to the at least one frame of screened picture.

8. An electronic device, comprising: The electronic device comprises: one or more processors; a storage device configured to store one or more programs, when the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1-6.

9. A computer readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the method according to any one of claims 1-6.

Citation Information

Patent Citations

  • A method and device for automatic control of light supplementary light of shooting device

    CN101102416A

  • Work mode switching method and device of camera

    CN107026967A

  • Apparatus for taking a photograph and method thereof

    KR1020060008105A

  • Local positioning apparatus, and a method therefor

    US6091833A