A method for detecting information, a computing device, and a storage medium
By using deep learning models and clustering algorithms to automatically detect lane lines, the problem of time-consuming and labor-intensive manual lane line marking is solved, achieving efficient and automatic lane line recognition and violation detection, which is applicable to a variety of traffic scenarios.
Patent Information
- Application Number
- CN202010732512.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-27
- Publication Date
- 2025-12-05
- Estimated Expiration
- 2040-07-27
AI Technical Summary
In existing technologies, lane line detection requires manual calibration, which leads to a waste of manpower and time, and is particularly difficult to perform efficiently with a large number of intersection images.
By acquiring image description information and classification feature data, lane lines are automatically detected using a deep learning model, including semantic segmentation and instance segmentation, and then combined with clustering algorithms for lane line recognition and tracking.
It enables automated and rapid lane line detection, saving manpower, and timely identification of vehicle violations. It supports concurrent detection by multiple cameras and is suitable for scenarios such as traffic, airports, docks, and stations.
Smart Images

Figure CN113989731B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a method for detecting information, a method for detecting lane lines, a method for detecting vehicle violations, a computing device, and a storage medium. Background Technology
[0002] In traffic conditions, cameras can be used to monitor traffic flow in real time, allowing for manual determination of whether cameras are illuminating the road at the correct angle and whether vehicles are violating traffic rules. To automate these determinations, lane markings need to be detected. However, currently, lane markings still require manual labeling on the images, and this requires labeling lane markings in images from multiple different viewpoints. Given that there are thousands of cameras on a road segment, labeling lane markings for each camera's image is undoubtedly time-consuming and labor-intensive for manual work. Summary of the Invention
[0003] This application provides a method for detecting information, a method for detecting lane lines, a method for detecting vehicle violations, a computing device, and a storage medium, which can automatically detect target objects, saving manpower and time.
[0004] This application provides an information detection method, comprising: acquiring an image; determining descriptive information for describing the location of a target object in the image; acquiring classification feature data of the image, wherein the classification feature data can be used to distinguish the target object in the image; and dividing the classification feature data of the target object according to the descriptive information and the classification feature data of the image to detect the target object.
[0005] This application embodiment also provides a lane line detection method, including: acquiring a road condition image, determining descriptive information for describing the position of lane lines in the road condition image; acquiring classification feature data of the road condition image, the classification feature data being used to distinguish each lane line in the road condition image; dividing the classification feature data of the lane lines according to the descriptive information and the classification feature data of the road condition image, and detecting the lane lines.
[0006] This application embodiment also provides a method for detecting vehicle violations, including: acquiring a road condition image and determining descriptive information for describing the position of lane lines in the road condition image; acquiring classification feature data of the road condition image, the classification feature data being used to distinguish lane lines in the road condition image; dividing the classification feature data of the lane lines according to the descriptive information and the classification feature data of the road condition image, and detecting the lane lines; determining the position of a vehicle in the road condition image, and determining whether the vehicle in the road condition image is in violation of traffic rules based on the vehicle position and the detected lane lines.
[0007] This application embodiment also provides a computing device, including: a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program to: acquire an image; determine descriptive information for describing the location of a target object in the image; acquire classification feature data of the image, the classification feature data being used to distinguish target objects in the image; and, based on the descriptive information and the classification feature data of the image, divide the classification feature data of the target object to detect the target object.
[0008] This application embodiment also provides a computing device, including: a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program for: acquiring a road condition image and determining descriptive information for describing the position of lane lines in the road condition image; acquiring classification feature data of the road condition image, the classification feature data being used to distinguish lane lines in the road condition image; and dividing the classification feature data of the lane lines according to the descriptive information and the classification feature data of the road condition image to detect the lane lines.
[0009] This application embodiment also provides a computing device, including: a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program for: acquiring a road condition image and determining descriptive information for describing the position of lane lines in the road condition image; acquiring classification feature data of the road condition image, the classification feature data being used to distinguish lane lines in the road condition image; dividing the classification feature data of the lane lines according to the descriptive information and the classification feature data of the road condition image, and detecting the lane lines; determining the position of a vehicle in the road condition image, and determining whether the vehicle in the road condition image is in violation of traffic rules based on the vehicle position and the detected lane lines.
[0010] This application also provides a computer-readable storage medium storing a computer program, which, when executed by one or more processors, causes the one or more processors to perform the steps in the above-described method.
[0011] In this embodiment, an image is acquired, and descriptive information is determined to describe the location of the target object in the image. Classification feature data of the image is acquired, which can be used to distinguish target objects in the image. Based on the descriptive information and the classification feature data of the image, the classification feature data of the target object is divided, and the target object is detected. The target object can be automatically classified using the descriptive information and classification feature data, thereby detecting the corresponding target object. Specifically, the descriptive information identifies which objects in the image are target objects, and the classification feature data further categorizes these target objects belonging to the same category according to their individual characteristics, thus detecting each target object.
[0012] Correspondingly, the target object can be lane lines, thus enabling the automatic detection of lane lines in road condition images. This saves manpower and time, while also allowing for relatively quick identification of lane lines, timely determination of vehicle violations or even traffic accidents, and prompt follow-up responses. Attached Figure Description
[0013] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0014] Figure 1 This is a schematic diagram of the structure of an information detection system as an exemplary embodiment of this application;
[0015] Figure 2 This is a schematic flowchart of an information detection method according to an exemplary embodiment of this application;
[0016] Figure 3 This is a schematic diagram illustrating the acquisition of an image, which is yet another exemplary implementation of this application.
[0017] Figure 4 A schematic diagram of a binary image, which is yet another exemplary embodiment of this application;
[0018] Figure 5 A schematic diagram of a filtered image, which is yet another exemplary implementation of this application;
[0019] Figure 6 This is a schematic diagram of an image after skeleton extraction, which is another exemplary embodiment of this application;
[0020] Figure 7 A schematic diagram of an image of the lane lines for the final detection, as another exemplary implementation of this application;
[0021] Figure 8 This is a schematic flowchart of a lane line detection method according to an exemplary embodiment of this application;
[0022] Figure 9 A flowchart illustrating an information detection method as another exemplary embodiment of this application;
[0023] Figure 10 This is a schematic flowchart of a vehicle violation detection method according to an exemplary embodiment of this application;
[0024] Figure 11 A schematic diagram of the structure of an information detection device provided in yet another exemplary embodiment of this application;
[0025] Figure 12 A schematic diagram of the structure of an information detection device provided in yet another exemplary embodiment of this application;
[0026] Figure 13 A schematic diagram of the structure of a vehicle violation detection device provided as an exemplary embodiment of this application;
[0027] Figure 14 A schematic diagram of the structure of a computing device provided in an exemplary embodiment of this application;
[0028] Figure 15 A schematic diagram of the structure of a computing device provided in yet another exemplary embodiment of this application;
[0029] Figure 16 A schematic diagram of the structure of a computing device provided as another exemplary embodiment of this application. Detailed Implementation
[0030] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0031] As discussed earlier, lane line detection is crucial in current traffic scenarios, as it's essential for determining subsequent vehicle violations and other issues. However, the current practice of manually detecting lane lines in a large volume of intersection images results in a significant waste of manpower and time.
[0032] Therefore, this application proposes a method to reduce the cost and cumbersome process of manually marking lane lines.
[0033] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0034] Figure 1 This is a schematic diagram of the structure of an information detection system provided for an exemplary embodiment of this application. For example... Figure 1 As shown, the system 100 may include a first device 101 and a second device 102.
[0035] The first device 101 can be a device with certain computing capabilities, capable of sending data to the second device 102. The basic structure of the first device 101 may include at least one processor. The number of processors may depend on the configuration and type of the device with computing capabilities. The device with computing capabilities may also include memory, which can be volatile, such as RAM, or non-volatile, such as read-only memory (ROM), flash memory, or both. The memory typically stores an operating system (OS), one or more applications, and may also store program data. In addition to the processing unit and memory, the device with computing capabilities also includes some basic configurations, such as a network interface card (NIC) chip and an I / O bus. Optionally, the first device 101 can be an image acquisition device, such as a camera, which can rotate to capture images of the same scene from different angles.
[0036] The second device 102 refers to a device that can provide computing processing services in a network virtual environment. It can be a device that uses the network to perform image processing and detect target objects in the image. In physical implementation, the second device 102 can be any device capable of providing computing services, responding to service requests, and returning data processing results; for example, it could be a cloud server, cloud host, virtual data center, or conventional server. The second device 102 mainly consists of a processor, hard disk, memory, system bus, etc., similar to a general computer architecture.
[0037] In this embodiment, the first device 101 sends an image to the second device 102. The second device 102 acquires the image and determines descriptive information to describe the location of a target object in the image; it acquires classification feature data of the image, which can be used to distinguish target objects in the image; based on the descriptive information and the classification feature data of the image, it divides the classification feature data of the target object and detects the target object. The target object can be a lane line.
[0038] In addition, after detecting lane lines, the second device 102 can also track other objects in the image, such as vehicles, to determine the vehicle's position in the image and thus determine whether the vehicle has committed a traffic violation.
[0039] The system 100 may also include a third device 103, the basic structure of which is similar to that of the first device 101, and will not be described in detail here. The third device 103 can be a smart terminal, such as a computer. When a violation occurs, the second device 102 can send a violation message to the third device 103 so that the user of the third device 103 can receive the message and take action.
[0040] In the traffic application scenario of this application embodiment, the first device 101 is, for example, multiple cameras installed on both sides and above the road. The following explanation uses cameras as an example. The cameras can capture intersection images in real time and send the captured intersection images to the second device 102, such as a cloud server. The following explanation uses a cloud server and cameras as an example. After receiving the intersection images sent by multiple cameras, the cloud server can first determine whether the received road condition image is a valid image, i.e., an image without quality problems. Then, it extracts image feature data from the valid road condition image. This image feature data can be input into a first preset model, and all lane lines in the road condition image can be marked as 1, while other objects in the image, i.e., other content, are marked as 0. The image with 0 and 1 markings is output from the first preset model. Simultaneously, the cloud server can send the image feature data to a second preset model to obtain the classification feature data of each pixel in the image, which can be a 4-dimensional vector matrix. After obtaining an image labeled with 0s and 1s, the cloud server filters out invalid pixels and extracts the lane line skeleton, resulting in an image where the lane line skeleton is 1 and all other content is 0. The cloud server then multiplies this image with the classification feature data of each pixel in the image to obtain the classification feature data of the pixels corresponding to the lane line skeleton. This classification feature data is then input into a clustering algorithm for data clustering, and curve fitting is performed based on the clustered classification feature data to obtain a function representing the lane lines in the image, thus detecting the lane lines.
[0041] After detecting lane lines, the cloud server can continue detecting lane lines in other images and track vehicles within these images to determine their positions. Based on the vehicle's position and the detected lane lines, it determines whether there is overlap between the two in the image. If there is overlap, it is identified as a violation, such as an illegal lane change. It can also determine if the vehicle is driving in the wrong direction. After identifying a violation, the cloud server can send a message to a third-party device 103, such as the computer of a violation processing personnel, so that the personnel can receive the message, verify it, and issue a penalty to the offending vehicle.
[0042] It should be noted that the first device 101 can be installed on various roads and in places where the first device 101 can be installed, such as highways and high-altitude locations in cities.
[0043] The aforementioned system 100 can be applied not only to lane detection in traffic but also to detection in other scenarios, such as airports. It can detect objects or markers of the same or different types on the airport tarmac, including aircraft, supply vehicles, and shuttle buses. After detecting targets such as aircraft, supply vehicles, and shuttle buses, its location can be determined. Especially when multiple objects are identified in the same area of the tarmac, the system can determine whether any anomalies have occurred on the tarmac based on the location of each object, and then take appropriate action.
[0044] Furthermore, it can be applied to target detection in various transportation hubs such as docks and stations, including ships entering and leaving the port, as well as those docked at the dock; and buses entering, leaving, and stopping at stations. The system 100 can determine the locations of ships of the same or different types at the dock, and also the locations of vehicles of the same or different types at the station. These locations can then be used to determine if any anomalies have occurred at the dock or station, such as accidents or congestion.
[0045] Furthermore, it can also be applied to various scenarios requiring target detection, such as industrial workshops and construction sites. For example, it can be used to detect workers, machines, and tools in industrial workshops. It can also be used to detect vehicles, workers, and equipment on construction sites. By determining the location of workers, machines, and tools in industrial workshops, it can determine whether an accident is imminent or has already occurred. Similarly, by determining the location of vehicles, workers, and equipment on construction sites, it can determine whether an accident is imminent or has already occurred.
[0046] It should be understood that the settings of each device in System 100 may differ for different application scenarios, and can be adjusted according to the application scenario. Furthermore, the data processed by each device in System 100 may differ, and the processed data may vary depending on the scenario, but the specific processing methods are similar, and will not be elaborated further here.
[0047] In the above embodiment, the device can connect to a network, which can be a wireless connection. If it is a communication connection, the mobile network standard can be any one of 2G (GSM), 2.5G (GPRS), 3G (WCDMA, TD-SCDMA, CDMA2000, UTMS), 4G (LTE), 4G+ (LTE+), WiMax, 5G, etc.
[0048] The following detailed description of information detection is provided in conjunction with the method implementation examples.
[0049] Figure 2 This is a flowchart illustrating an exemplary embodiment of an information detection method according to this application. The method 200 provided in this embodiment is executed by a computing device, such as a cloud server. The method 200 includes the following steps:
[0050] 201: Acquire the image and determine descriptive information to describe the location of the target object in the image.
[0051] 202: Obtain the classification feature data of the image. The classification feature data can be used to distinguish target objects in the image.
[0052] 203: Based on the description information and the classification feature data of the image, the classification feature data of the target object is divided to detect the target object.
[0053] The following is a detailed explanation of the above steps:
[0054] 201: Acquire the image and determine descriptive information to describe the location of the target object in the image.
[0055] The descriptive information refers to information used to describe the location of a target object in the image, such as the location of lane lines. This information can be determined by identifiers, such as 0 or 1. Therefore, the target object can be identified as 1, and other objects as 0.
[0056] It's important to note that if multiple target objects exist within the same image, such as lane lines, then all target objects can be assigned the same identifier, such as 1. All other objects in the image, such as cars, trees, and the sky, should be set to 0. While it's possible to assign different identifiers to other objects or target objects, this is inconvenient for subsequent data processing. The former approach reduces processing steps in later stages. Furthermore, while using different identifiers to describe target objects is possible, it increases the processing complexity at this stage.
[0057] The image acquisition method can be to acquire multiple images from an image acquisition device. The image acquisition device can be placed in different locations depending on the scenario. In traffic scenarios, it can be placed above the road, such as in the urban skyline, or mounted on supporting structures along the road, such as on a bridge or traffic light. The image acquisition device can be a camera.
[0058] For example, as mentioned above, the camera can capture images of the road conditions within its field of view in real time and send multiple images to a cloud server. Specifically, the camera can periodically rotate to change its field of view, acquiring different angles of the same road condition at the intersection and sending them to the cloud server.
[0059] in, Figure 3 An acquired image 300 is shown, which has multiple lane lines 302 and multiple vehicles 301.
[0060] Furthermore, if real-time requirements are not particularly high, the image acquisition device can also send images to a device used for image storage, such as a storage server. The cloud server can then retrieve these images from this device, such as the storage server.
[0061] It should be understood that in addition to capturing images, the image acquisition device can also capture video in real time and send the video to a cloud server, so that the cloud server can perform subsequent processing on each frame of the video.
[0062] In computing devices, such as cloud servers, after receiving an image, the image quality can be determined. If the image quality does not meet the requirements, it is deleted. These quality requirements could include detecting whether the image has a black screen, no displayed content, etc. This improves processing efficiency and image quality.
[0063] In addition, in order to improve the processing speed of subsequent images, such as model speed, computational overhead, and memory usage, it is necessary to preprocess the images first, such as converting the images into image formats that can improve processing speed. However, at the same time, it is also necessary to ensure image quality so that the target objects can be better identified in the later stage, and to ensure the accuracy of the identification.
[0064] Specifically, the method 200 also includes: after acquiring the image, converting the image into an image of a predetermined size.
[0065] For example, as mentioned above, after receiving an image, the cloud server can scale the image to a predetermined size, such as an image with a size of 512*288.
[0066] It should be understood that both the aforementioned image quality determination and image size / format conversion can further improve image processing results and speed. However, even without these methods, subsequent image processing can continue.
[0067] After acquiring the image, image processing can be performed directly. For example, the image can be sent to a pre-built model for processing. This pre-built model uses an encoder-decoder framework. The encoder can use any currently available open-source deep learning model framework, such as ResNet, VGG, DRN, MobileNet, etc., for image compression encoding. These different model frameworks correspond to different neural network models, such as CNN (Convolutional Neural Networks) and RNN (Recurrent Neural Networks). The specific image compression process is as follows:
[0068] Specifically, the method 200 further includes: after acquiring the image, generating image feature data in a preset vector matrix format, and performing a step of determining the position of the target object in the image based on the image feature data.
[0069] For example, as mentioned above, such as Figure 8 As shown, after the cloud server acquires the image, or after the object undergoes preprocessing (i.e., quality determination and / or image size and format conversion), it can execute step 801: input the image to the encoder, use the RNN model corresponding to the encoder as a feature extractor or encoder, compress and encode the current image according to a preset image compression algorithm, extract image feature data, and obtain a vector matrix of preset dimensions to represent the image feature data. This allows for subsequent image processing, such as determining descriptive information.
[0070] Specifically, determining the descriptive information used to describe the location of the target object in the image includes: based on the image feature data of the image, identifying the pixels of the target object in the image through a first preset model to obtain the target identifier of the pixel, and using the target identifier as descriptive information; the identifier of each pixel of the target object in the image is the same.
[0071] The first pre-defined model is used for semantic segmentation. It labels the target object to be predicted, such as lane lines, as 1, and the background (other objects) as 0, forming a semantic segmentation task with only two labels. The training process involves using a large number of pre-labeled images of the target object and other objects, and training this first pre-defined model based on image feature data. This model can be an RNN, CNN, etc. A common binary-cross-entropy loss function is used for model training to obtain the first pre-defined model. This pre-defined model can also perform the decoder part in deep learning, restoring image resolution. Specific implementations include pixel shuffle, upsampling, and transposed convolution.
[0072] Therefore, the cloud server can input image feature data into the first preset model and perform step 802: semantic segmentation. Based on this model, the image is labeled, and lane lines in the image can be labeled as 1.
[0073] In addition, other objects in the image can also be identified as 0. Specifically, based on the image feature data, the pixels of other objects in the image are identified using a first preset model to obtain other identifiers for the pixels of other objects. The pixels of the target object are distinguished from the pixels of other objects by different identifiers, while the pixels of other objects have the same identifier.
[0074] Thus, the model can output an image that has already been marked with 0 and 1, which is a 0-1 binary image.
[0075] in, Figure 4 The binary image 400 is shown. In this image 400, white can represent lane lines marked as 1, and black can represent other objects marked as 0.
[0076] It should be noted that while it's possible to identify the target object in an image, for ease of subsequent processing, other objects can also be identified. Setting other objects to 0 allows them to be filtered out during image processing, allowing direct processing of the target object. Conversely, setting the target object's identification to 1 preserves its classification features in the image, enabling direct classification.
[0077] After obtaining the binary image, invalid pixels, such as isolated pixels, can be filtered and denoised. Connectivity analysis can be used to filter out some invalid pixels. That is, step 803: Connectivity Analysis.
[0078] Specifically, 1) the method 200 further includes: after determining the identifier of the pixel of the image, determining other identifiers set in the target identifier area; and removing other identifiers if the determined other identifiers meet the removal conditions.
[0079] For example, as described above, after obtaining the binary image, the cloud server identifies the target region that is marked as 0 within the region marked as 1. That is, in image 400, black areas can be seen surrounded by white. When the number of black areas surrounded by white (marked as 0) is less than a threshold number of pixels, a closing operation (e.g., dilation followed by erosion) is performed on this black image to remove the small black dots surrounded by white in image 400.
[0080] in, Figure 5 The filtered image 500 is shown. Comparing image 500 with image 400, it can be seen that some black pixels have been removed and white pixels have been converted, thus correcting the image.
[0081] Specifically, 2) the method also includes: after determining the pixel identifiers of the image, determining the target identifiers set in other identifier areas; and removing the target identifiers if the target identifiers meet the removal conditions.
[0082] Similar to the previous text, this will not be repeated here. It will only be noted that the cloud server can perform connected component analysis and filter out isolated white blocks based on a set pixel number threshold (which can be 500 in this embodiment).
[0083] Comparing image 500 with image 400, it can be seen that some white pixels were removed and converted to black pixels, thus correcting the image.
[0084] It should be noted that if the image only contains the identifier of the target object, no filtering is required. Alternatively, the pixels of the target object can be filtered. This filtering process identifies isolated pixels. Or, all pixels of the target object can be directly detected, i.e., the set of pixels in the image with an identifier of 1 is determined to be greater than the number of pixels threshold, and then the filtering is determined.
[0085] After denoising the image, and considering image 500, it was found that the features at the edges of the binary lane lines were not obvious, and directly extracting these lane line features would significantly increase the computational load of subsequent algorithms. Therefore, skeleton features were extracted from the lane lines in the binary image to reduce subsequent computation and improve the robustness of feature extraction. It should be understood that skeleton extraction can also be performed on images containing only lane line markings.
[0086] Specifically, the method 200 further includes: after determining the descriptive information, extracting descriptive information from the descriptive information to describe the shape and structure of the target object; dividing the classification feature data of the target object according to the extracted descriptive information and the classification feature data of the image, and detecting each target object.
[0087] In this context, the skeleton refers to the shape and structure used to describe the target object. Extracting the skeleton involves extracting its corresponding descriptive information, such as identifiers.
[0088] For example, as described above, the cloud server can extract the skeleton of the lane lines in the aforementioned binary image using a skeleton extraction algorithm, i.e., execute step 804: skeleton extraction, which involves extracting the corresponding skeleton description information from the description information. This skeleton description information is the identifier that best represents the shape and structure of the lane lines. Then, all other description information can be set to a value of 0.
[0089] in, Figure 6 Image 600 after skeleton extraction is shown. The extraction result can be seen in image 600.
[0090] After extracting the corresponding skeleton description information, the extracted binary image can be multiplied with the classification feature data to obtain only the classification feature data corresponding to the skeleton of the target object, and then classification can be performed.
[0091] 202: Obtain the classification feature data of the image. The classification feature data can be used to distinguish target objects in the image.
[0092] The process of obtaining the classification feature data of the image includes: encoding each pixel in the image using a second preset model based on the image feature data of the image to generate multi-dimensional vector data, which is used to represent the classification feature data of each pixel.
[0093] The second pre-set model is used for instance segmentation encoding. Each pixel in the image is encoded into a 4-dimensional (or higher) vector, resulting in an output instance segmentation result of 512*288*4.
[0094] The training process can involve training with a large number of pre-labeled images of different target objects. For example, an image might contain six lane lines, labeled sequentially as 1, 2, 3, 4, 5, and 6. Based on the image feature data, a second pre-built model is trained; this model could be an RNN, CNN, or similar. The training uses the open-source discriminative loss method as the loss function. During training, instance segmentation encoding is performed on the image feature data to obtain a multi-dimensional vector or matrix for each pixel. Under the premise of satisfying the loss function, this multi-dimensional vector can effectively classify pixels, resulting in multiple different target objects, such as multiple lane lines. Based on this, the trained instance segmentation encoding algorithm is used to segment and encode instances in the detected image, thereby performing classification.
[0095] Meanwhile, the second pre-built model can also perform the decoder part in the deep learning process mentioned above, which can restore the resolution of the image. Specific implementation methods include pixel shuffle, upsampling, transposed convolution, etc.
[0096] Therefore, for example, as described above, the cloud server can input image data features into the second pre-set model and execute step 805: instance segmentation encoding to obtain the image's classification feature data for subsequent classification.
[0097] 203: Based on the description information and the classification feature data of the image, the classification feature data of the target object is divided to detect the target object.
[0098] It should be noted that, for step 203, the above-mentioned quality determination, image size and format conversion, filtering and noise reduction, skeleton extraction, etc., can be directly performed. The data can be directly divided using descriptive information and classification feature data.
[0099] Specifically, based on the descriptive information and the classification feature data of the image, the classification feature data of the target object is divided to detect the target object, including: determining the classification feature data corresponding to the target object in the image based on the descriptive information and the classification feature data; dividing the classification feature data of the determined target object for each target object in at least one target object to obtain the classification feature data corresponding to each target object; generating data representing each target object based on the classification feature data corresponding to each target object; and detecting each target object based on the generated data.
[0100] Specifically, for each target object, the classification feature data of the determined target object is divided to obtain the classification feature data corresponding to each target object. This division can be achieved by clustering the classification feature data.
[0101] Specifically, the classification feature data of the determined target objects is divided to obtain the classification feature data corresponding to each target object, including: clustering the classification feature data to obtain at least one class of classification feature data; and using the at least one class of classification feature data as the classification feature data corresponding to each target object.
[0102] This clustering method can be implemented using a clustering model. The DBSCAN clustering model can be used; DBSCAN is a relatively mature density-based clustering algorithm with noise reduction capabilities. It is particularly useful when the number of target objects is not fixed, such as in any scenario where the number of lane lines is variable, making other classic supervised clustering algorithms like K-means and kmes++ unsuitable. Therefore, DBSCAN is chosen here.
[0103] For example, as described above, the cloud server can multiply a binary image with an image containing categorical feature data (e.g., a 4-dimensional vector for each pixel), selecting the non-zero parts, i.e., the non-zero categorical feature data, which represents the lane line categorical feature data. This is step 806: determining the instance segmentation code for the lane lines. DBSCAN clustering is then performed on this categorical feature data to obtain the categorical feature data corresponding to each lane line, i.e., step 807: feature clustering. Finally, the categorical feature data corresponding to each lane line is aggregated, and step 808: regression fitting is performed to form a function representing each lane line; that is, the corresponding lane line can be detected based on this function.
[0104] In addition, classification can also be achieved based on descriptive information used for the aforementioned quality determination, image size and format conversion, filtering and noise reduction, skeleton extraction, etc.
[0105] Specifically, based on the extracted descriptive information and image classification feature data, the classification feature data of the target objects are divided, and each target object is detected. This will not be elaborated further here.
[0106] Alternatively, classification can be performed based on at least one of the above-mentioned processes, such as quality determination, image size and format conversion, filtering and noise reduction, and skeleton extraction.
[0107] In the description information, if it is only to identify the target object, the classification feature data corresponding to the pixel can be determined directly based on the pixel of the target object corresponding to the identifier.
[0108] Specifically, based on the descriptive information and classification feature data, the classification feature data of the target object in the image is determined, including: based on the target identifier of the target object's pixels, the classification feature data of the corresponding pixels of the target object is determined.
[0109] For example, as mentioned above, the cloud server can determine the corresponding pixel based on the lane line identifier 1, and then determine the corresponding classification feature data (e.g., the 4-dimensional vector of the corresponding pixel) from the classification feature data (e.g., the 4-dimensional vector of each pixel) based on these pixels. This allows for DBSCAN clustering and aggregation.
[0110] The aggregation process described above can be as follows:
[0111] Specifically, based on the classification feature data corresponding to each target object, data representing each target object is generated. This includes: for each target object, performing data fitting on its corresponding classification feature data to generate fitted data representing the corresponding target object. This can include curve fitting based on the shape of the target object, i.e., data fitting.
[0112] For example, as mentioned earlier, after obtaining the classification feature data (e.g., 4-dimensional vectors) corresponding to each lane line, the cloud server uses a quadratic curve to perform regression fitting on the lane lines based on their shape. This involves calculating the coefficients of the quadratic, linear, and constant terms for each lane line, generating the corresponding function. Each of these data fittings has its own corresponding fitting error. For pixel classes with larger fitting errors (i.e., the classification feature data corresponding to the target object), secondary clustering is required. The feature data for secondary clustering is no longer instance segmentation encoding, but other feature data. This is because instance segmentation encoding sometimes cannot accurately represent spatial relationships, and spatially inconsistent target objects require further spatial clustering separation.
[0113] Specifically, the method 200 further includes: for each target object, determining the data fitting error; based on the data fitting error (also known as the fitting error), determining the classification feature data corresponding to the error condition; dividing the position according to the position of the pixel corresponding to the classification feature data in the image to obtain the position corresponding to the target object; generating data representing the corresponding target object based on the corresponding position; and detecting the corresponding target object based on the generated data.
[0114] If the fitting error is outside a reasonable range, i.e., if the fitting error exceeds the error threshold, it means that two target objects have been misidentified as one target object, such as misidentifying two lane lines as one lane line.
[0115] The position of a pixel in an image refers to the coordinates of the pixel in the image.
[0116] For example, as described above, the cloud server can perform step 808: regression fitting during the curve fitting process, and simultaneously calculate the fitting error of the final fitted function (i.e., determining the fitting error in step 808). The mean squared error can be selected as the fitting error. Then, step 809 is executed: determining whether the fitting error meets the error condition. If the fitting error exceeds the error threshold, it is necessary to perform secondary clustering on the incorrectly clustered lane lines using their positions, i.e., returning to step 807: feature clustering. The lane line position is the coordinate of the lane line pixels in the image. The coordinate set corresponding to the lane lines is input into DBSCAN for secondary clustering. Then, each re-clustered category, i.e., the coordinate set corresponding to each re-clustered lane line, is subjected to secondary curve fitting again, and the output is the final lane line function. If the fitting error does not exceed the error threshold, step 810: outputting the final lane line function can be executed directly.
[0117] in, Figure 7 Image 700 of the final detected lane lines is shown. In this image 700, multiple lane lines 701 were detected.
[0118] It should be noted that the fitting error can be used to determine if there are any problems with the fitted curve. For example, if DBSCAN identifies two lane lines as one lane line, this anomaly can be identified through the fitting error. If the fitting error is within a reasonable range, then the lane line function can be used as the final output.
[0119] Furthermore, the embodiments of this application can intelligently, automatically, and efficiently apply algorithms to traffic camera scenarios in cities and highways to automatically detect lane lines. Moreover, the embodiments of this application are not limited to the number of lane lines in the image; for highways and cities from an overhead view, all lane lines can be identified, and in actual use, the total lane line detection time for a single frame can be controlled to approximately 50 milliseconds (ms), supporting concurrent detection by 32 cameras.
[0120] It should also be noted that the specific implementation of this method 200 can also be applied to the various scenarios mentioned above, such as airports, train stations, docks, industrial workshops, and construction sites.
[0121] In different scenarios, detection can be performed on target objects of the same type, which are identical, such as aircraft of the same model. It can also be performed on target objects of different types, such as aircraft of different types. However, even for target objects of different types, if their appearance is similar, or in other words, their structure and shape are similar, then detection is still possible.
[0122] Based on the above-mentioned similar inventive concepts. Figure 9A flowchart illustrating a lane line detection method provided in another exemplary embodiment of this application is shown. The method 900 provided in this embodiment can be executed by the aforementioned server, such as... Figure 9 As shown, the method 900 includes the following steps:
[0123] 901: Acquire traffic images and determine descriptive information used to describe the position of lane lines in the traffic images.
[0124] 902: Obtain classification feature data from road condition images. Classification feature data can be used to distinguish lane lines in the image.
[0125] 903: Based on the description information and the classification feature data of the road condition image, the classification feature data of the lane lines are divided and the lane lines are detected.
[0126] Since the specific implementation methods of steps 901-903 have been described in detail above, they will not be repeated here.
[0127] Specifically, acquiring road condition images includes: acquiring multiple road condition images; wherein, the method 900 further includes: for each road condition image, performing a step of determining descriptive information used to describe the position of lane lines in the image.
[0128] Since this has already been explained in detail above, it will not be repeated here.
[0129] Additionally, for any details not described in this method 900, please refer to the steps in the above method 200.
[0130] Based on the above-mentioned similar inventive concepts. Figure 10 This illustration shows a flowchart of a vehicle violation detection method provided in another exemplary embodiment of this application. The method 1000 provided in this embodiment can be executed by the aforementioned server, such as... Figure 10 As shown, the method 1000 includes the following steps:
[0131] 1001: Acquire a road condition image and determine descriptive information to describe the position of lane lines in the road condition image.
[0132] 1002: Obtain classification feature data from road condition images. Classification feature data can be used to distinguish lane lines in road condition images.
[0133] 1003: Based on the description information and the classification feature data of the road condition image, the classification feature data of the lane lines are divided and the lane lines are detected.
[0134] 1004: Determine the position of vehicles in the traffic image, and based on the vehicle position and the detected lane lines, determine whether the vehicles in the traffic image are in violation of traffic rules.
[0135] Since the specific implementation methods of steps 1001-1003 have been described in detail above, they will not be repeated here. Only this will be noted: In step 1004, the coordinates of the vehicles in each image can be determined according to the tracking algorithm. Since the images are transmitted continuously, such as images of consecutive time intervals within the same road segment, or images of connected road segments, the same vehicle can be tracked within images of connected road segments. Therefore, the tracking algorithm can be used to track the same vehicle or locate different vehicles within the same road segment in the images.
[0136] After detecting the vehicle's coordinates in the road condition image, the vehicle's coordinates are compared with the lane line coordinates to determine if there is any overlap. If there is, a violation has occurred, such as the vehicle not driving in a restricted area or having illegally changed lanes.
[0137] Furthermore, based on manual calibration of lane line directions, after detecting lane lines, the direction of each lane line in each road segment can be determined according to the connection relationship of road segments. After determining the direction of each lane line, the movement position of vehicles in the road condition image can be used to determine whether a vehicle is driving in the wrong direction.
[0138] Furthermore, by analyzing multiple consecutive road condition images of the same road segment, it can determine whether the position of the same vehicle has moved, or the distance it has moved within a preset time, thereby determining whether traffic congestion or even traffic accidents have occurred. It can also determine whether the camera is illuminating the road surface at a normal angle based on the detected lane markings.
[0139] In addition, the method 1000 also includes: when a vehicle violation is determined, sending a violation message to the processing device.
[0140] For example, as mentioned above, after a traffic violation is identified, the cloud server can recognize the vehicle's license plate and send the violation message to the computer of the traffic violation processing personnel. This message can carry the license plate of the violating vehicle so that the personnel can process the message further.
[0141] Specifically, acquiring road condition images includes: acquiring multiple road condition images; wherein, the method 1000 further includes: for each road condition image, performing a step of determining descriptive information used to describe the position of lane lines in the road condition image.
[0142] In addition, the method 1000 also includes: determining whether a traffic accident has occurred in the current road condition based on the vehicle position in each of the multiple road condition images and the detected lane lines.
[0143] Specifically, based on the vehicle's position and the detected lane lines, it is determined whether a vehicle in the traffic image has violated traffic rules. This includes determining whether a vehicle has violated traffic rules if the vehicle's position and the lane line's position in the traffic image at least partially overlap.
[0144] Since this has already been explained in detail above, it will not be repeated here.
[0145] Additionally, for any details not described in this method 1000, please refer to the steps in the above method 200.
[0146] It should be noted that, in addition to detecting traffic violations, this method can also be applied to various scenarios, such as airports, train stations, docks, industrial workshops, and construction sites. After detecting the target objects in each scenario, it can also determine, based on the similarity method of Method 1000, whether an accident is about to occur, has already occurred, or whether there is congestion of vehicles or ships in different scenarios. Specifically, within the same scenario, it can determine whether the positions of detected target objects overlap. If they overlap, a collision may have occurred. If they do not overlap, but the positions are close together, such as within a certain threshold, a collision may be imminent, and a warning should be issued. Further details will not be elaborated here.
[0147] Figure 11 This is a schematic diagram of the structural framework of an information detection device provided for an exemplary embodiment of this application. The device 1100 can be applied to a server. The device 1100 includes: an acquisition model 1101 and a segmentation module 1102; the functions of each module are described in detail below:
[0148] Model 1101 is used to acquire images and determine descriptive information to describe the location of the target object in the image.
[0149] Model 1101 is used to obtain classification feature data of the image. The classification feature data can be used to distinguish target objects in the image.
[0150] The segmentation module 1102 is used to segment the classification feature data of the target object based on the description information and the classification feature data of the image, and to detect the target object.
[0151] In addition, the device 1100 also includes a conversion module for converting the acquired image into an image of a predetermined size.
[0152] In addition, the device 1100 also includes a generation module, which generates image feature data in a preset vector matrix format after acquiring the image, and performs a step of determining the position of the target object in the image based on the image feature data.
[0153] Specifically, model 1101 is used to: identify the pixels of target objects in the image based on the image feature data of the image, through the first preset model, to obtain the target identifier of the pixel, and use the target identifier as descriptive information; the pixel identifier of each target object in the image is the same.
[0154] Specifically, model 1101 is used to encode each pixel in the image based on the image feature data of the image through the second preset model, generating multi-dimensional vector data to represent the classification feature data of each pixel.
[0155] Specifically, the segmentation module 1102 includes: a determination unit, used to determine the classification feature data corresponding to the target object in the image based on the description information and classification feature data; a segmentation unit, used to segment the determined classification feature data of each target object to obtain the classification feature data corresponding to each target object; a generation unit, used to generate data representing each target object based on the classification feature data corresponding to each target object; and a detection unit, used to detect each target object based on the generated data.
[0156] Specifically, the generation unit is used to fit the corresponding classification feature data of each target object to generate fitted data representing the corresponding target object.
[0157] In addition, the device 1100 further includes: a determination module, used to determine the data fitting error for each of the at least one target objects; and to determine the classification feature data corresponding to the error condition based on the data fitting error; a division module 1102, used to divide the position according to the position of the pixel corresponding to the classification feature data in the image to obtain the position corresponding to the target object; and a generation module, used to generate data representing the corresponding target object based on the corresponding position; the device 1100 further includes: a detection module, used to detect the corresponding target object based on the generated data.
[0158] Specifically, the determining unit is used to: determine the classification feature data of the corresponding pixels of the target object based on the target identifier of the target object's pixels.
[0159] In addition, the device 1100 further includes: an identification module, used to identify the pixels of other objects in the image based on the image feature data of the image and through a first preset model, to obtain other identifiers of the pixels of other objects, wherein the pixels of the target object are distinguished from the pixels of other objects by different identifiers, and the pixels of other objects have the same identifier; a determination module, used to determine other identifiers set in the target identification area after determining the identifiers of the pixels of the image; and a rejection module, used to reject other identifiers if the determined other identifiers meet the rejection conditions.
[0160] In addition, the determination module is also used to determine the target identifier set in other identifier areas after determining the identifier of the image pixels; the elimination module is also used to eliminate the target identifier if the target identifier meets the elimination conditions.
[0161] In addition, the device 1100 also includes: an extraction module, used to extract descriptive information for describing the shape and structure of the target object from the descriptive information after the descriptive information is determined; and a segmentation module 1102, used to segment the classification feature data of the target object according to the extracted descriptive information and the classification feature data of the image, and detect each target object.
[0162] Specifically, the partitioning unit is used to: cluster the categorical feature data to obtain at least one class of categorical feature data; and use the at least one class of categorical feature data as the categorical feature data corresponding to each target object.
[0163] Figure 12 This is a schematic diagram of the structural framework of a lane line detection device provided for an exemplary embodiment of this application. The device 1200 can be applied to a server. The device 1200 includes: an acquisition module 1201 and a segmentation module 1202; the functions of each module are described in detail below:
[0164] The acquisition module 1201 is used to acquire road condition images and determine descriptive information to describe the position of lane lines in the road condition images.
[0165] The acquisition module 1201 is used to acquire classification feature data of road condition images. The classification feature data can be used to distinguish lane lines in road condition images.
[0166] The segmentation module 1202 is used to segment the classification feature data of lane lines based on the description information and the classification feature data of the road condition image, and detect the lane lines.
[0167] Specifically, the acquisition module 1201 is used to acquire road condition images, and to acquire multiple road condition images; wherein, for each road condition image, a step is performed to determine descriptive information used to describe the position of lane lines in the road condition image.
[0168] It should be noted that for any parts not mentioned in device 1200, please refer to the contents of device 1100 mentioned above.
[0169] Figure 13 This is a schematic diagram of the structural framework of a vehicle violation detection device provided as an exemplary embodiment of this application. The device 1300 can be applied to a server. The device 1300 includes: an acquisition module 1301, a segmentation module 1302, and a determination module 1303; the functions of each module are described in detail below:
[0170] The acquisition module 1301 is used to acquire road condition images and determine descriptive information to describe the position of lane lines in the road condition images.
[0171] The acquisition module 1301 is used to acquire classification feature data of road condition images. The classification feature data can be used to distinguish lane lines in the image.
[0172] The segmentation module 1302 is used to segment the classification feature data of lane lines based on the description information and the classification feature data of the road condition image, and to detect lane lines.
[0173] The determination module 1303 is used to determine the position of vehicles in the road condition image, and to determine whether the vehicles in the image are in violation of traffic rules based on the vehicle position and the detected lane lines.
[0174] In addition, the device 1300 also includes a sending module for sending a violation message to the processing device when a vehicle violation is determined.
[0175] Specifically, the acquisition module 1301 is used to acquire multiple road condition images; wherein, for each road condition image, a step is performed to determine descriptive information used to describe the position of lane lines in the road condition image.
[0176] In addition, the determination module 1303 is used to determine whether a traffic accident has occurred in the current road condition based on the vehicle position in each of the multiple road condition images and the detected lane lines.
[0177] In addition, the determination module 1303 is used to determine a vehicle violation when the vehicle position and the lane line position in the road condition image at least partially overlap.
[0178] It should be noted that for any part of the content not mentioned in device 1300, please refer to the content of device 1100 mentioned above.
[0179] The above describes Figure 11 The internal functions and structure of the device 1100 shown, in one possible design, Figure 11 The structure of the illustrated device 1100 can be implemented as a computing device, such as a server. Figure 14 As shown, the device 1400 may include: a memory 1401 and a processor 1402;
[0180] Memory 1401 is used to store computer programs.
[0181] Processor 1402 is configured to execute a computer program for: acquiring an image; determining descriptive information to describe the location of a target object in the image; acquiring classification feature data of the image, which can be used to distinguish target objects in the image; and classifying the classification feature data of the target object based on the descriptive information and the classification feature data of the image, thereby detecting the target object.
[0182] In addition, the processor 1402 is also used to: after acquiring an image, convert the image into an image of a predetermined size.
[0183] In addition, the processor 1402 is also used to: after acquiring an image, generate image feature data in a preset vector matrix format, and perform a step of determining the position of the target object in the image based on the image feature data.
[0184] Specifically, the processor 1402 is used to: identify the pixels of the target objects in the image based on the image feature data of the image, through a first preset model, to obtain the target identifier of the pixels, and use the target identifier as descriptive information; the identifier of each pixel of the target object in the image is the same.
[0185] Specifically, processor 1402 is used to: encode each pixel in the image based on the image feature data of the image through a second preset model to generate multi-dimensional vector data, which is used to represent the classification feature data of each pixel.
[0186] Specifically, processor 1402 is used to: determine the classification feature data corresponding to the target object in the image based on the description information and classification feature data; divide the determined classification feature data of each target object to obtain the classification feature data corresponding to each target object; generate data representing each target object based on the classification feature data corresponding to each target object; and detect each target object based on the generated data.
[0187] Specifically, processor 1402 is used to: for each target object in at least one target object, perform data fitting on its corresponding classification feature data to generate fitted data representing the corresponding target object.
[0188] In addition, the processor 1402 is also configured to: determine the data fitting error for each target object; determine the classification feature data that does not meet the error condition based on the data fitting error; divide the position according to the position of the pixel corresponding to the classification feature data in the image to obtain the position corresponding to the target object; generate data representing the corresponding target object based on the corresponding position; and detect the corresponding target object based on the generated data.
[0189] Specifically, processor 1402 is used to: determine the classification feature data of the corresponding pixels of the target object based on the target identifier of the target object's pixels.
[0190] In addition, the processor 1402 is also configured to: identify the pixels of other objects in the image based on the image feature data of the image, through a first preset model, to obtain other identifiers of the pixels of other objects, wherein the pixels of the target object are distinguished from the pixels of other objects by different identifiers, and the pixels of other objects have the same identifier; after determining the identifiers of the pixels of the image, determine other identifiers set in the target identifier area; and remove other identifiers if the determined other identifiers meet the removal conditions.
[0191] In addition, the processor 1402 is also configured to: determine the target identifier set in other identifier areas after determining the identifier of the pixels of the image; and remove the target identifier if the target identifier meets the removal conditions.
[0192] In addition, the processor 1402 is also used to: after determining the description information, extract description information from the description information to describe the shape and structure of the target object; and divide the classification feature data of the target object according to the extracted description information and the classification feature data of the image to detect each target object.
[0193] Specifically, processor 1402 is used to: cluster the classification feature data to obtain at least one class of classification feature data; and use the at least one class of classification feature data as the classification feature data corresponding to each target object.
[0194] In addition, embodiments of the present invention provide a computer storage medium in which a computer program, when executed by one or more processors, causes one or more processors to implement... Figure 2 The method embodiment includes the steps of a lane line detection method.
[0195] The above describes Figure 12 The internal functions and structure of the device 1200 shown, in one possible design, Figure 12 The structure of the illustrated device 1200 can be implemented as a computing device, such as a server. Figure 15 As shown, the device 1500 may include: a memory 1501 and a processor 1502;
[0196] Memory 1501 is used to store computer programs.
[0197] Processor 1502 is configured to execute a computer program for: acquiring a road condition image; determining descriptive information to describe the position of lane lines in the road condition image; acquiring classification feature data of the road condition image, which can be used to distinguish lane lines in the road condition image; and, based on the descriptive information and the classification feature data of the road condition image, segmenting the classification feature data of the lane lines and detecting the lane lines.
[0198] Specifically, processor 1502 is used to: acquire road condition images, for acquiring multiple road condition images; wherein, for each road condition image, a step is performed to determine descriptive information used to describe the position of lane lines in the road condition image.
[0199] It should be noted that for any content not mentioned in device 1500, please refer to the content of device 1400 mentioned above.
[0200] In addition, embodiments of the present invention provide a computer storage medium in which a computer program, when executed by one or more processors, causes one or more processors to implement... Figure 9 The method embodiment includes the steps of a lane line detection method.
[0201] The above describes Figure 13 The internal functions and structure of the device 1300 shown, in one possible design, Figure 13 The structure of the illustrated device 1300 can be implemented as a computing device, such as a server. Figure 16 As shown, the device 1600 may include: a memory 1601 and a processor 1602;
[0202] Memory 1601 is used to store computer programs.
[0203] Processor 1602 is configured to execute a computer program for: acquiring a road condition image and determining descriptive information to describe the position of lane lines in the road condition image; acquiring classification feature data of the image, which can be used to distinguish lane lines in the road condition image; classifying the lane line classification feature data according to the descriptive information and the classification feature data of the road condition image, and detecting the lane lines; determining the position of vehicles in the road condition image, and determining whether the vehicles in the road condition image are in violation of traffic rules based on the vehicle positions and the detected lane lines.
[0204] In addition, the processor 1602 is also used to: when a vehicle violation is determined, send a violation message to the processing device.
[0205] Specifically, processor 1602 is used to: acquire multiple road condition images; wherein, for each road condition image, a step is performed to determine descriptive information used to describe the position of lane lines in the road condition image.
[0206] In addition, the processor 1602 is also used to determine whether a traffic accident has occurred in the current road condition based on the vehicle position in each of the multiple road condition images and the detected lane lines.
[0207] In addition, the processor 1602 is also used to determine a vehicle violation when the vehicle position and the lane line position in the road condition image at least partially overlap.
[0208] It should be noted that for any content not mentioned in device 1600, please refer to the content of device 1400 mentioned above.
[0209] In addition, embodiments of the present invention provide a computer storage medium in which a computer program, when executed by one or more processors, causes one or more processors to implement... Figure 10 The method embodiment includes the steps of a vehicle violation detection method.
[0210] Furthermore, in some of the processes described in the above embodiments and accompanying drawings, multiple operations appear in a specific order. However, it should be clearly understood that these operations may not be executed in the order they appear herein, or they may be executed in parallel. The operation numbers, such as 201, 202, 203, etc., are merely used to distinguish different operations and do not represent any execution order. Additionally, these processes may include more or fewer operations, and these operations may be executed sequentially or in parallel. It should be noted that the descriptions such as "first" and "second" in this document are used to distinguish different messages, devices, modules, etc., and do not represent a sequential order, nor do they limit "first" and "second" to different types.
[0211] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0212] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of a necessary general-purpose hardware platform, or by a combination of hardware and software. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a computer product. The present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0213] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable multimedia data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable multimedia data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0214] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable multimedia data processing device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0215] These computer program instructions may also be loaded onto a computer or other programmable multimedia data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0216] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0217] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0218] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0219] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method of detecting information, characterized by, The method comprises: acquiring an acquired image, and determining a binary image for describing a position of a target object in the image; acquiring classification feature data of the image, the classification feature data being used for distinguishing the target object in the image; using a skeleton extraction algorithm to perform skeleton extraction of the target object on the binary image, to obtain a binary image for describing the extracted skeleton of the target object; determining classification feature data corresponding to at least one target object in the acquired image according to the binary image for describing the extracted skeleton of the target object and the classification feature data; for each target object in the at least one target object, clustering the determined classification feature data of the target object, to obtain at least one type of classification feature data, and taking the at least one type of classification feature data as the classification feature data corresponding to each target object; for each target object, performing curve fitting on the classification feature data corresponding to the target object, to generate fitting data representing the corresponding target object; detecting each target object according to the generated data. The method further comprises: for each target object, determining a fitting error of the curve fitting; determining classification feature data corresponding to an error condition that is not met according to the fitting error of the curve fitting, and considering that the error condition that is not met indicates a case where two target objects are misjudged as one target object; performing secondary clustering on coordinates of pixels corresponding to the classification feature data in the acquired image, and performing secondary curve fitting on each type obtained through the secondary clustering, to generate fitting data representing the corresponding target object; detecting the corresponding target object according to the data generated through the secondary curve fitting.
2. The method of claim 1, wherein, The method further comprises: after acquiring the image, converting the image into an image of a predetermined size.
3. The method of claim 1, wherein, The method further comprises: after acquiring the image, generating image feature data in a preset vector matrix format from the image, and performing the step of determining the position of the target object in the image on the image feature data.
4. The method of claim 1, wherein, The binary image for describing the position of the target object in the image comprises: using a first preset model to identify pixels of the target object in the image according to image feature data of the image, to obtain target identification of the pixels, and taking the target identification as the binary image; the identification of the pixels of each target object in the image is the same.
5. The method of claim 1, wherein, The classification feature data of the image comprises: using a second preset model to encode each pixel in the image according to image feature data of the image, to generate multi-dimensional vector data, which is used for representing classification feature data of each pixel.
6. The method of claim 1, wherein, The classification feature data of the target object in the image is determined according to the binary image and the classification feature data, and comprises: determining the classification feature data of the pixels corresponding to the target object according to the target identification of the pixels of the target object.
7. The method of claim 4, wherein, The method further comprises: According to the image feature data of the image, pixels of other objects in the image are identified through a first preset model to obtain other identification of the pixels of the other objects, the pixels of the target object and the pixels of the other objects being distinguished through different identification, the identification of the pixels of the other objects being the same; After determining the identification of the pixels of the image, the other identification set in the target identification area is determined; In a case where the determined other identification meets a rejection condition, the other identification is rejected.
8. The method of claim 7, wherein, The method further comprises: After determining the identification of the pixels of the image, the target identification set in the other identification area is determined; In a case where the determined target identification meets a rejection condition, the target identification is rejected.
9. A method of detecting a lane line, characterized by, Comprise: Obtaining the collected road condition image, and determining a binary image used to describe the position of a lane line in the road condition image; Obtaining classification feature data of the road condition image, the classification feature data being used to distinguish the lane line in the image; Using a skeleton extraction algorithm to perform skeleton extraction of the lane line on the binary image to obtain a binary image used to describe the extracted lane line skeleton; According to the binary image used to describe the extracted lane line skeleton and the classification feature data, determining classification feature data corresponding to at least one lane line in the road condition image; For each lane line in the at least one lane line, clustering the determined classification feature data of the lane line to obtain at least one type of classification feature data, and taking the at least one type of classification feature data as the classification feature data corresponding to each lane line; For each lane line, performing curve fitting on the classification feature data corresponding to the lane line to generate fitting data representing the corresponding lane line; According to the generated data, detecting each lane line; The method further comprises: for each lane line, determining a fitting error of the curve fitting; According to the fitting error of the curve fitting, determining classification feature data not meeting an error condition, and considering that two lane lines are misjudged as one lane line in a case where the fitting error does not meet the error condition; Performing secondary clustering on the coordinates of the pixels corresponding to the classification feature data in the road condition image, and performing secondary curve fitting on each class obtained through the secondary clustering to generate fitting data representing the corresponding lane line; According to the data generated through the secondary curve fitting, detecting the corresponding lane line.
10. The method of claim 9, wherein, The method further comprises: Obtaining a plurality of road condition images; The method further comprises: for each road condition image, performing the step of determining the description information used to describe the position of the lane line in the road condition image.
11. A method of detecting a vehicle violation, the method comprising: Comprise: Obtaining the collected road condition image, and determining a binary image used to describe the position of a lane line in the road condition image; Obtaining classification feature data of the road condition image, the classification feature data being used to distinguish the lane line in the image; Using a skeleton extraction algorithm to perform skeleton extraction of the lane line on the binary image to obtain a binary image used to describe the extracted lane line skeleton; According to the binary image used to describe the extracted lane line skeleton and the classification feature data, determining classification feature data corresponding to at least one lane line in the road condition image; For each lane line in the at least one lane line, clustering the determined classification feature data of the lane line to obtain at least one type of classification feature data, and taking the at least one type of classification feature data as the classification feature data corresponding to each lane line; For each lane line, performing curve fitting on the classification feature data corresponding to the lane line to generate fitting data representing the corresponding lane line; According to the generated data, detecting each lane line; The method further comprises: for each lane line, determining a fitting error of the curve fitting; According to the fitting error of the curve fitting, determining classification feature data not meeting an error condition, and considering that two lane lines are misjudged as one lane line in a case where the fitting error does not meet the error condition; Performing secondary clustering on the coordinates of the pixels corresponding to the classification feature data in the road condition image, and performing secondary curve fitting on each class obtained through the secondary clustering to generate fitting data representing the corresponding lane line; According to the data generated through the secondary curve fitting, detecting the corresponding lane line. The method further comprises: Obtaining a plurality of road condition images; The method further comprises: for each road condition image, performing the step of determining the description information used to describe the position of the lane line in the road condition image. According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected; The position of the vehicle in the road condition image is determined, and whether the vehicle in the road condition image is in violation is determined according to the position of the vehicle and the detected lane line; According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected, including: According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected, including: According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected, including: According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected, including: According to the classification feature data of the binary image used for describing the extracted lane line skeleton and the road condition image, the classification feature data of the lane line is divided, and the lane line is detected, including: The method further includes: for each lane line, determining the fitting error of the curve fitting; According to the fitting error of the curve fitting, the classification feature data corresponding to the error condition not being met is determined, and the fitting error not meeting the error condition is considered as a situation of misjudging two lane lines as one lane line; The coordinates of the pixels corresponding to the classification feature data in the road condition image are secondarily clustered, and each class obtained by the secondary clustering is secondarily curve fitted to generate fitting data representing the corresponding lane line; According to the data generated by the secondary curve fitting, the corresponding lane line is detected.
12. The method of claim 11, wherein, The method further includes: When it is determined that the vehicle is in violation, a violation message is sent to a processing device.
13. The method of claim 11, wherein, The method further includes: A plurality of road condition images are acquired. The method further includes: for each road condition image, the step of acquiring the binary image used for describing the position of the lane line in the road condition image is performed.
14. The method of claim 13, wherein, The method further includes: According to the position of the vehicle in each road condition image and the detected lane line, whether a traffic accident occurs in the current road condition is determined.
15. The method of claim 11, wherein, According to the position of the vehicle and the detected lane line, whether the vehicle in the image is in violation, including: When the position of the vehicle at least partially coincides with the position of the lane line in the road condition image, it is determined that the vehicle is in violation.
16. A computing device comprising: A memory and a processor; The memory is used to store a computer program; The processor is used to execute the computer program, so as to: An acquired image is acquired, and a binary image used for describing the position of a target object in the image is determined; Classification feature data of the image is acquired, and the classification feature data can be used to distinguish the target object in the image; A skeleton extraction algorithm is used to perform skeleton extraction of the target object on the binary image, so as to obtain a binary image used for describing the extracted target object skeleton; According to the binary image used for describing the extracted target object skeleton and the classification feature data, classification feature data corresponding to at least one target object in the collected image is determined; For each target object in the at least one target object, the determined classification feature data of the target object is clustered to obtain at least one type of classification feature data, and the at least one type of classification feature data is taken as the classification feature data corresponding to each target object; For each target object, curve fitting is performed on the classification feature data corresponding to the target object to generate fitting data representing the corresponding target object; According to the generated data, each target object is detected; The processor is further configured to determine, for each target object, a fitting error of the curve fitting; According to the fitting error of the curve fitting, classification feature data that does not satisfy an error condition is determined, and the fitting error that does not satisfy the error condition is considered as a case where two target objects are misjudged as one target object; Coordinates of pixels corresponding to the classification feature data in the collected image are secondarily clustered, and each type obtained through the secondary clustering is secondarily curve fitted to generate fitting data representing the corresponding target object; According to the data generated through the secondary curve fitting, the corresponding target object is detected.
17. A computing device comprising: A memory and a processor; The memory is configured to store a computer program; The processor is configured to execute the computer program, so as to: Collect a road condition image, and determine a binary image used for describing positions of lane lines in the image; Collect classification feature data of the road condition image, and the classification feature data can be used to distinguish the lane lines in the image; Perform skeleton extraction of the lane lines on the binary image by using a skeleton extraction algorithm to obtain a binary image used for describing extracted lane line skeletons; According to the binary image used for describing the extracted lane line skeletons and the classification feature data, classification feature data corresponding to at least one lane line in the road condition image is determined; For each lane line in the at least one lane line, the determined classification feature data of the lane line is clustered to obtain at least one type of classification feature data, and the at least one type of classification feature data is taken as the classification feature data corresponding to each lane line; For each lane line, curve fitting is performed on the classification feature data corresponding to the lane line to generate fitting data representing the corresponding lane line; According to the generated data, each lane line is detected; The processor is further configured to determine, for each lane line, a fitting error of the curve fitting; According to the fitting error of the curve fitting, classification feature data that does not satisfy an error condition is determined, and the fitting error that does not satisfy the error condition is considered as a case where two lane lines are misjudged as one lane line; Coordinates of pixels corresponding to the classification feature data in the road condition image are secondarily clustered, and each type obtained through the secondary clustering is secondarily curve fitted to generate fitting representing the corresponding lane line; According to the data generated through the secondary curve fitting, the corresponding lane line is detected.
18. A computing device comprising: A memory and a processor; The memory is configured to store a computer program; The processor is configured to execute the computer program to: acquire a collected road condition image, and determine a binary image for describing positions of lane lines in the image; acquire classification feature data of the road condition image, the classification feature data being used to distinguish lane lines in the image; extract a skeleton of the lane line from the binary image by using a skeleton extraction algorithm, to obtain a binary image for describing the extracted lane line skeleton; divide classification feature data of the lane line according to the binary image for describing the extracted lane line skeleton and the classification feature data of the road condition image, and detect the lane line; determine a vehicle position in the road condition image, and determine whether the vehicle in the road condition image is in violation according to the vehicle position and the detected lane line; wherein dividing classification feature data of the lane line according to the binary image for describing the extracted lane line skeleton and the classification feature data of the road condition image, and detecting the lane line, comprises: determining classification feature data corresponding to at least one lane line in the road condition image according to the binary image for describing the extracted lane line skeleton and the classification feature data; clustering the determined classification feature data of the lane line for each lane line in the at least one lane line, to obtain at least one type of classification feature data, and taking the at least one type of classification feature data as classification feature data corresponding to each lane line; performing curve fitting on the classification feature data corresponding to each lane line, to generate fitting data representing the corresponding lane line; detecting each lane line according to the generated data; the processor is further configured to determine, for each lane line, a fitting error of the curve fitting; determining classification feature data corresponding to a condition that is not satisfied according to the fitting error of the curve fitting, and considering that a condition that the fitting error is not satisfied is a situation where two lane lines are misjudged as one lane line; performing secondary clustering on coordinates of pixels corresponding to the classification feature data in the road condition image, and performing secondary curve fitting on each class obtained by the secondary clustering, to generate fitting data representing the corresponding lane line; detecting the corresponding lane line according to the data generated by the secondary curve fitting.
19. A computer readable storage medium storing a computer program, characterized in that, The computer program is executed by one or more processors, so as to cause the one or more processors to implement steps in the method of any one of claims 1-15.
Citation Information
Patent Citations
Lane line detection method, device and system, vehicle and storage medium
CN111316284A
Vehicle line pressing violation judgment method and device based on deep learning and storage medium
CN111382704A