A method, apparatus, device, and medium for detecting an empty parking space

By acquiring and processing continuous depth images, a denoised binary map is generated to update the parking space status, solving the problem of incorrect parking space status judgment caused by environmental fluctuations, achieving accurate and timely parking space status detection, and reducing labor costs.

CN117456436BActive Publication Date: 2026-04-10SHANGHAI INTEGRATED CIRCUIT MFG INNOVATION CENT CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHANGHAI INTEGRATED CIRCUIT MFG INNOVATION CENT CO LTD
Filing Date
2022-07-19
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

Existing parking space detection solutions are susceptible to abnormal fluctuations in the environment, leading to incorrect judgments of parking space status and resulting in wasted time and parking space.

Method used

By acquiring depth images of parking spaces in N consecutive frames, comparing pixel depths within the region of interest, generating an original binary image, and then generating a denoised binary image through an AND operation, the parking space status is updated by counting the number of effective pixels, thus reducing environmental interference.

Benefits of technology

It improves the accuracy of parking space status judgment, avoids erroneous judgments caused by environmental fluctuations, allows users to know the parking space status in a timely manner, and reduces the steps and labor costs of human judgment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117456436B_ABST
    Figure CN117456436B_ABST
Patent Text Reader

Abstract

The application provides a method for detecting idle parking spaces, which is applied to an intelligent parking system and comprises the following steps: acquiring N continuous frames of depth images about parking spaces from an image acquisition unit; for a kth frame of depth images contained in the N frames of depth images, the kth frame of depth images being any one of the N frames of depth images, the following processing is performed: comparing the pixel depth of each pixel point in a region of interest in the kth frame of depth images with a preset maximum value and a preset minimum value respectively; generating an original binary image corresponding to the kth frame of depth images according to the comparison result; performing an AND operation on the original binary image of the kth frame of depth images and a k-mth frame of original binary images to generate a denoised binary image; counting the number of pixel points with effective values in the denoised binary image; when the number of pixel points with effective values is greater than a threshold value, updating the parking space state to a state with a vehicle; and when the number of pixel points with effective values is less than or equal to the threshold value, updating the parking space state to an idle state, so as to detect the idle parking space state.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of intelligent parking, and in particular to a method, device, equipment and medium for detecting an idle parking space. BACKGROUND

[0002] At present, the existing parking space detection scheme is generally based on deep learning and sensor physical feature detection technology, which is easily affected by abnormal fluctuations in the environment, and dust or pedestrian movement can cause parking space state judgment errors, which is inconvenient for accurately obtaining the parking space state. Time is wasted in waiting for an idle parking space. At the same time, if the parking space state is not obtained in time, the parking space will be wasted while the user is still waiting for the parking space. Therefore, there is an urgent need for a method, device, equipment and medium for detecting an idle parking space to improve the above problems. SUMMARY

[0003] The present application aims to provide a method, device, equipment and medium for detecting an idle parking space, which is used for detecting an idle parking space state.

[0004] In a first aspect, the present application provides a method for detecting an idle parking space, applied to an intelligent parking system, comprising: acquiring N consecutive frames of depth images about a parking space from an image acquisition unit; for a kth frame of depth images contained in the N frames of depth images, the kth frame of depth images being any one of the N frames of depth images, performing the following processing: comparing the pixel depth of each pixel point in the region of interest (ROI) in the kth frame of depth images with a preset maximum value and a preset minimum value respectively; generating an original binary image corresponding to the kth frame of depth images according to the comparison result; performing an AND operation on the original binary image of the kth frame of depth images and the original binary image of the kth-mth frame to generate a denoising binary image; k and m are both arbitrary positive integers, and m is less than or equal to k-1; counting the number of pixel points with valid values in the denoising binary image; when the number of pixel points with valid values is greater than a threshold, updating the parking space state to a vehicle state; when the number of pixel points with valid values is less than or equal to the threshold, updating the parking space state to an idle state.

[0005] The method has the beneficial effects that: by acquiring N continuous frames of depth images about the parking space from an image acquisition unit; for a kth frame of depth image contained in the N frames of depth images, the kth frame of depth image is any one of the N frames of depth images, the following processing is performed: comparing the pixel depth of each pixel point in the region of interest in the kth frame of depth image with a preset maximum value and a preset minimum value respectively; generating an original binary image corresponding to the kth frame of depth image according to the comparison result; performing an AND operation on the original binary image of the kth frame of depth image and the original binary image of the kth-m frame to generate a denoising binary image; k and m are both arbitrary positive integers, and m is less than or equal to k-1; counting the number of pixel points with valid values in the denoising binary image; when the number of pixel points with valid values is greater than a threshold, updating the parking space state to a car-in state; when the number of pixel points with valid values is less than or equal to the threshold, updating the parking space state to an idle state. It is not easy to be affected by abnormal fluctuations in the environment, dust or pedestrian movement will not cause the parking space state to be judged incorrectly, and the user can accurately obtain the parking space state. At the same time, the user can timely obtain the parking space state, and the waste of parking space caused by the user waiting for an empty space while the parking space is already idle is eliminated, which is beneficial to improve the user's use experience. The method for detecting an idle parking space is simple and low in cost, and reduces the step of manually judging the parking space state, which is beneficial to save labor cost.

[0006] Optionally, when the number of pixel points with valid values is greater than a threshold, updating the parking space state to a car-in state, comprising: when the number of pixel points with valid values is greater than the threshold and lasts for x frames, updating the parking space state to a car-in state; x is an arbitrary positive integer; when the number of pixel points with valid values is less than or equal to the threshold, updating the parking space state to an idle state, comprising: when the number of pixel points with valid values is less than or equal to the threshold and lasts for y frames, updating the parking space state to an idle state; y is an arbitrary positive integer. Its beneficial effects are that: by updating the parking space state to a car-in state when the number of pixel points with valid values is greater than the threshold and lasts for x frames, and updating the parking space state to an idle state when the number of pixel points with valid values is less than or equal to the threshold and lasts for y frames. It is beneficial to avoid frequent changes of the parking space state caused by environmental factors, and to ensure that the user obtains reliable parking space state information.

[0007] Optionally, the generating the original binary image corresponding to the kth frame of depth image according to the comparison result comprises: when the pixel depth of the pixel point is not greater than the preset maximum value and the pixel depth of the pixel point is not less than the preset minimum value, setting a pixel value of the original binary image corresponding to the pixel point as a valid value; when the pixel depth of the pixel point is greater than the preset maximum value or the pixel depth of the pixel point is less than the preset minimum value, setting a pixel value of the original binary image corresponding to the pixel point as an invalid value; and generating the original binary image according to the valid value and the invalid value.

[0008] Optionally, the acquiring the continuous N frames of depth images about the parking space from the image acquisition unit comprises: the image acquisition unit acquires continuous frames of depth images with a horizontal distance of d from a parking line, a height of h from the ground, and a pitch angle of θ; and the height h of the image acquisition unit from the ground satisfies:

[0009]

[0010] wherein H is a preset vehicle height, d is a distance of the image acquisition unit from the rear of the parking line, and L is a length of the parking line.

[0011] Optionally, a field of view (FOV) of the depth image in a vertical direction is α, and a field of view of the depth image in a horizontal direction is β; the field of view α in the vertical direction and the field of view β in the horizontal direction satisfy:

[0012]

[0013]

[0014] wherein d is a horizontal distance of the image acquisition unit from the parking line, L is a length of the parking line, w is a width of the parking line, and h is a height of the image acquisition unit from the ground.

[0015] Optionally, the pitch angle θ of the image acquisition unit satisfies:

[0016]

[0017] wherein d is a distance of the image acquisition unit from the rear of the parking line, h is a height of the image acquisition unit from the ground, and α is a field of view in a vertical direction.

[0018] In a second aspect, the present application provides a parking space detection device for the method of any one of the first aspect, comprising: a processing unit, an image acquisition unit and a storage unit; the image acquisition unit is configured to acquire N consecutive frames of depth images of a parking space; the processing unit is configured to, for a kth frame of depth images contained in the N frames of depth images, the kth frame of depth images being any one of the N frames of depth images, perform the following processing: judging whether the pixel depth of each pixel point in the region of interest in the kth frame of depth images is within a preset range; generating an original binary image corresponding to the kth frame of depth images according to the result of the judgment; performing an AND operation on the original binary image of the kth frame of depth images and the original binary image of the kth-mth frame to generate a denoising binary image; k and m are both arbitrary positive integers, and m is less than or equal to k-1; counting the number of pixel points with valid values in the denoising binary image; when the number of pixel points with valid values is greater than a threshold, updating the parking space state to a car-in state; when the number of pixel points with valid values is less than or equal to the threshold, updating the parking space state to an idle state; and the storage unit is configured to store the parking space state.

[0019] Optionally, the device further comprises an interaction unit; at least one of the storage unit and the processing unit is electrically connected with the interaction unit; and the interaction unit is configured to acquire the parking space state stored in the storage unit.

[0020] Optionally, the processing unit is configured to generate an original binary image corresponding to the kth frame of depth images according to the comparison result, including: when the pixel depth of the pixel point is not greater than the preset maximum value and the pixel depth of the pixel point is not less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel point is set to a valid value; when the pixel depth of the pixel point is greater than the preset maximum value or the pixel depth of the pixel point is less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel point is set to an invalid value; and the original binary image is generated according to the valid value and the invalid value.

[0021] Optionally, the processing unit is configured to, when the number of pixel points with valid values is greater than a threshold, update the parking space state to a car-in state, including: when the number of pixel points with valid values is greater than the threshold and lasts for x frames, updating the parking space state to a car-in state; x is an arbitrary positive integer; and the processing unit is further configured to, when the number of pixel points with valid values is less than or equal to the threshold, update the parking space state to an idle state, including: when the number of pixel points with valid values is less than or equal to the threshold and lasts for y frames, updating the parking space state to an idle state; y is an arbitrary positive integer.

[0022] In a third aspect, the present application provides an electronic device, comprising a memory and a processor and a depth camera; the memory has a program stored thereon, the program being executable on the processor, and when the program is executed by the processor, the electronic device implements the method of any possible design of any one of the above aspects.

[0023] In a fourth aspect, the present application provides a readable storage medium, the readable storage medium has a program stored therein; the program, when executed, implements the method of any possible design of any one of the above aspects. BRIEF DESCRIPTION OF DRAWINGS

[0024] Figure 1 A flowchart of the method for detecting idle parking spaces provided by the present application is shown in the figure.

[0025] Figure 2 A structural diagram of the structure of the collection unit installed on the parking space provided by the present application is shown in the figure.

[0026] Figure 3 A top view of the collection unit installed on the charging pile provided by the present application is shown in the figure.

[0027] Figure 4 A structural diagram of the device for detecting idle parking spaces provided by the present application is shown in the figure.

[0028] Figure 5 A structural diagram of the electronic device for detecting idle parking spaces provided by the present application is shown in the figure. DETAILED DESCRIPTION

[0029] In order to make the objects, technical solutions and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present application. Unless otherwise defined, the technical terms or scientific terms used herein should be understood as the usual meanings understood by those skilled in the art in the field of the present application. The words such as "comprise" and similar words used herein mean that the elements or objects before the words cover the elements or objects listed after the words and their equivalents, and do not exclude other elements or objects.

[0030] Figure 1 A flowchart of the method for detecting idle parking spaces provided by the present application is shown in the figure.

[0031] In view of the problems in the prior art, the present application provides a method for detecting idle parking spaces, which is applied to an intelligent parking system, such as Figure 1 as shown, comprising:

[0032] S101, acquiring N continuous frames of depth images about the parking space from the image acquisition unit.

[0033] Figure 2 The structure schematic diagram of the acquisition unit provided by the present application is installed on the parking space.

[0034] In some embodiments, the N continuous frames of depth images about the parking space acquired from the image acquisition unit include: Figure 2 As shown, the image acquisition unit 101 acquires continuous frames of depth images with a horizontal distance d from the parking line, a height h from the ground, and a pitch angle θ. The height h of the image acquisition unit 101 from the ground satisfies:

[0035]

[0036] where H is a preset vehicle height, d is the distance of the image acquisition unit 101 from the rear of the parking line, and L is the length of the parking line.

[0037] Figure 3 The top view of the acquisition unit provided by the present application is installed on the charging pile.

[0038] In some embodiments, the field of view angle of the depth image in the vertical direction is α. As shown, Figure 3 the field of view angle of the depth image in the horizontal direction is β. The field of view angle α in the vertical direction and the field of view angle β in the horizontal direction satisfy:

[0039]

[0040]

[0041] where d is the horizontal distance of the image acquisition unit 101 from the parking line, L is the length of the parking line, w is the width of the parking line, and h is the height of the image acquisition unit 101 from the ground.

[0042] In some specific embodiments, the image acquisition unit 101 is arranged on the charging pile 110.

[0043] In another specific embodiment, one image acquisition unit 101 corresponds to t parking spaces. t is set to any positive integer. The depth image sets a region of interest for each of the t parking spaces.

[0044] In some embodiments, the pitch angle θ of the image acquisition unit 101 satisfies:

[0045]

[0046] wherein d is the distance from the image acquisition unit 101 to the back of the parking space line. h is the height of the image acquisition unit 101 from the ground. a is the vertical field of view angle.

[0047] It is worth mentioning that the time of the adjacent frames in the depth images of the parking space in the continuous N frames is an arbitrary unit of time. The frame rate of the depth images acquired by the image acquisition unit 101 includes but is not limited to at least one of 30 fps, 60 fps, 90 fps, and 120 fps.

[0048] S102, for the kth frame of the N frames of depth images, the kth frame of depth images is any one of the N frames of depth images, the following processing is performed: comparing the pixel depth of each pixel point in the region of interest in the kth frame of depth images with the preset maximum value and the preset minimum value respectively. According to the result of the comparison, the original binary image corresponding to the kth frame of depth images is generated.

[0049] In some embodiments, according to the result of the comparison, the original binary image corresponding to the kth frame of depth images is generated, including: when the pixel depth of the pixel point is not greater than the preset maximum value and the pixel depth of the pixel point is not less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel point is set to a valid value. When the pixel depth of the pixel point is greater than the preset maximum value or the pixel depth of the pixel point is less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel point is set to an invalid value. The original binary image is generated according to the valid value and the invalid value.

[0050] In some specific embodiments, the valid value is set to 1, and the invalid value is set to 0.

[0051] In another specific embodiment, the valid value is set to 0, and the invalid value is set to 1.

[0052] S103, the original binary image of the kth frame of depth images is ANDed with the original binary image of the k-mth frame to generate a denoising binary image. k and m are both arbitrary positive integers, and m is less than or equal to k-1.

[0053] In some specific embodiments, when the occlusion appears in the first pixel in the original binary image of the kth frame of depth images, the first pixel value is an invalid value. When the occlusion disappears in the first pixel in the original binary image of the kth frame of depth images, the first pixel value is a valid value. The first pixel value in the denoising binary image generated after the AND operation is an invalid value.

[0054] In some embodiments, when an occlusion appears in a first pixel in the original binary image of the kth depth image, the first pixel value is a valid value. When an occlusion disappears in a first pixel in the original binary image of the kth depth image, the first pixel value is a valid value. The first pixel value in the denoised binary image generated after the AND operation is a valid value.

[0055] In S104, the number of pixels with a valid value in the denoised binary image is counted. When the number of pixels with a valid value is greater than a threshold value, the parking space status is updated to a car-present status. When the number of pixels with a valid value is less than or equal to the threshold value, the parking space status is updated to an idle status.

[0056] For example, the threshold value is set to 50% of the total number of pixels in the denoised binary image. It should be noted that the threshold value can be set to any value according to actual needs.

[0057] It should be noted that N consecutive depth images about the parking space are obtained from the image acquisition unit 101. For a kth depth image included in the N depth images, the kth depth image is any one of the N depth images, the following processing is performed: the pixel depth of each pixel point in the region of interest in the kth depth image is compared with a preset maximum value and a preset minimum value, respectively. According to the comparison result, an original binary image corresponding to the kth depth image is generated. The original binary image of the kth depth image and the original binary image of the kth-mth frame are subjected to an AND operation to generate a denoised binary image. k and m are both arbitrary positive integers, and m is less than or equal to k-1. The number of pixels with a valid value in the denoised binary image is counted. When the number of pixels with a valid value is greater than a threshold value, the parking space status is updated to a car-present status. When the number of pixels with a valid value is less than or equal to the threshold value, the parking space status is updated to an idle status. It is not easy to be affected by abnormal fluctuations in the environment, dust or pedestrian movement will not cause the parking space status to be incorrectly judged, and the user can accurately obtain the parking space status. At the same time, the user can timely obtain the parking space status, and the phenomenon of wasting parking space space while the user is still waiting for an empty space due to the parking space being already idle is eliminated.

[0058] In some embodiments, when the number of pixels with a valid value is greater than a threshold value, updating the parking space status to a car-present status includes: when the number of pixels with a valid value is greater than the threshold value and lasts for x frames, updating the parking space status to a car-present status. x is an arbitrary positive integer.

[0059] It should be noted that when the number of pixels with a valid value is greater than the threshold value and lasts for a frames, the parking space status remains unchanged. a is an arbitrary positive integer less than x.

[0060] In some embodiments, when the number of pixel points with valid values is less than or equal to the threshold value, the parking space state is updated to be an idle state, including: when the number of pixel points with valid values is less than or equal to the threshold value and lasts for y frames, the parking space state is updated to be an idle state. y is any positive integer.

[0061] It is worth noting that when the number of pixel points with valid values is less than or equal to the threshold value and lasts for b frames, the parking space state remains unchanged. b is any positive integer less than y.

[0062] Figure 4 A structural schematic diagram of the device for detecting idle parking spaces provided by the present application is shown.

[0063] As shown in Figure 4 The present application provides a parking space detection device 100 for the method of any one of the above embodiments, including a processing unit 102, an image acquisition unit 101, and a storage unit 103. The image acquisition unit 101 is configured to acquire N consecutive frames of depth images of a parking space. The processing unit 102 is configured to, for a kth frame of depth image contained in the N frames of depth images, the kth frame of depth image being any one of the N frames of depth images, perform the following processing: determining whether the pixel depth of each pixel point in a region of interest in the kth frame of depth image is within a preset range. According to the result of the determination, an original binary image corresponding to the kth frame of depth image is generated. The original binary image of the kth frame of depth image and the original binary image of the k-mth frame are subjected to an AND operation to generate a denoised binary image. k and m are both any positive integer, and m is less than or equal to k-1. The number of pixel points with valid values in the denoised binary image is counted. When the number of pixel points with valid values is greater than a threshold value, the parking space state is updated to be a vehicle state. When the number of pixel points with valid values is less than or equal to the threshold value, the parking space state is updated to be an idle state. The storage unit 103 is configured to store the parking space state.

[0064] In some embodiments, the device further includes an interaction unit 104. At least one of the storage unit 103 and the processing unit 102 is electrically connected to the interaction unit 104. The interaction unit 104 is configured to acquire the parking space state stored in the storage unit 103.

[0065] In some embodiments, the processing unit 102 is configured to generate a raw binary image corresponding to the kth frame of depth image according to a result of the comparison, including: when the pixel depth of the pixel point is not greater than the preset maximum value and the pixel depth of the pixel point is not less than the preset minimum value, setting a pixel value of a raw binary image corresponding to the pixel point as a valid value. When the pixel depth of the pixel point is greater than the preset maximum value or the pixel depth of the pixel point is less than the preset minimum value, setting the pixel value of the raw binary image corresponding to the pixel point as an invalid value. The raw binary image is generated according to the valid value and the invalid value.

[0066] In some embodiments, the processing unit 102 is configured to update the parking space state to a car state when the number of pixel points with the valid value is greater than a threshold value, including: when the number of pixel points with the valid value is greater than the threshold value and lasts for x frames, updating the parking space state to the car state. x is any positive integer. The processing unit 102 is further configured to update the parking space state to an idle state when the number of pixel points with the valid value is less than or equal to the threshold value, including: when the number of pixel points with the valid value is less than or equal to the threshold value and lasts for y frames, updating the parking space state to the idle state. y is any positive integer.

[0067] Figure 5 A structural schematic diagram of an electronic device for detecting an idle parking space is provided.

[0068] As shown in Figure 5 The present application provides an electronic device 200, including a memory 203 and a processor 202 and a depth camera 201. The memory 203 stores a program executable on the processor 202, and when the program is executed by the processor 202, the electronic device 200 implements the method of any one of the above embodiments.

[0069] In a possible design, the processor 202 and the memory 203 can be separately arranged, or integrated on the same integrated circuit chip.

[0070] It should be noted that the processor 202 in the embodiments of the present application can be an image processing chip or an integrated circuit chip, which has the processing capability for image signals. In the implementation process, each step of the above-mentioned method embodiments can be completed by the integrated logic circuit of hardware in the processor or the instructions in the form of software. The above-mentioned processor can be a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. Each method, step and logic block disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor. The steps of the method disclosed in combination with the embodiments of the present application can be directly embodied as hardware decoding processor for execution, or executed by the combination of hardware and software modules in the decoding processor. The software modules can be located in the random access memory, the flash memory, the read-only memory, the programmable read-only memory or the electrically erasable programmable memory, the register and other mature storage media in the art. The storage medium is located in the memory, and the processor reads the information in the memory, and combines the hardware to complete the steps of the above-mentioned method.

[0071] It is to be understood that the memory 203 in the embodiments of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. The non-volatile memory can be a Read-Only Memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an Electrically EPROM (EEPROM), or a flash memory. The volatile memory can be a Random Access Memory (RAM) used as an external cache. By way of example, and not limitation, many forms of RAM can be used, such as a Static RAM (SRAM), a Dynamic RAM (DRAM), a Synchronous DRAM (SDRAM), a Double Data Rate SDRAM (DDR SDRAM), an Enhanced SDRAM (ESDRAM), a Synchlink DRAM (SLDRAM), and a Direct Rambus RAM (DR RAM). It is to be noted that the memory of the system and method described herein is intended to include, without being limited to, these and any other suitable types of memory.

[0072] In some embodiments, the electronic device 200 further comprises a query terminal 204. The query terminal 204 is connected with the memory 203, and is used to acquire the parking space status.

[0073] In some other embodiments, the query terminal 204 is connected with the processor 202, and is used to acquire the parking space status stored in the memory 203 through the processor 202.

[0074] It is to be noted that the query terminal 204 includes, but is not limited to, a smart phone and a parking lot electronic display screen.

[0075] The present application provides a readable storage medium, and the readable storage medium stores a program. When the program is executed, the method of any one of the possible designs in the above embodiments is implemented.

[0076] It should be noted that, if the method is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on such understanding, the technical solutions of the present application or the parts of the technical solutions that essentially contribute to the prior art or the parts of the technical solutions can be embodied in the form of a software product stored in a storage medium, including a plurality of instructions for causing an electronic device to execute all or part of the steps of the method described in the embodiments of the present application. The foregoing storage medium includes a U disk, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk or an optical disk, and various media that can store program codes.

[0077] Although the embodiments of the present application have been described in detail above, it is obvious to those skilled in the art that various modifications and changes can be made to the embodiments. However, it should be understood that such modifications and changes are within the scope and spirit of the present application described in the claims. Moreover, the present application described herein can have other embodiments and can be implemented or realized in various ways.

Claims

1. A method for detecting vacant parking spaces, applied to an intelligent parking system, characterized in that, include: The image acquisition unit acquires N consecutive depth images at a horizontal distance d from the parking line, a height h from the ground, and a pitch angle θ; the height h of the image acquisition unit from the ground satisfies: Where H is the preset vehicle height; d is the distance between the image acquisition unit and the rear of the parking space line; and L is the length of the parking space line. For the k-th depth image contained in the N-frame depth images, where the k-th depth image is any frame in the N-frame depth images, the following processing is performed: The pixel depth of each pixel in the region of interest in the k-th frame depth image is compared with a preset maximum value and a preset minimum value respectively; when the pixel depth of the pixel is not greater than the preset maximum value and the pixel depth of the pixel is not less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel is set to a valid value; When the pixel depth of the pixel is greater than the preset maximum value or the pixel depth of the pixel is less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel is set to an invalid value. Generate the original binary image corresponding to the depth image of the kth frame based on the valid and invalid values; Perform a bitwise AND operation between the original binary image of the k-th frame depth image and the original binary image of the km-th frame to generate a denoised binary image; k and m are both arbitrary positive integers, and m is less than or equal to k-1; The number of pixels with valid values ​​in the denoised binary image is counted; when the number of valid pixels is greater than a threshold, the parking space status is updated to "occupied"; when the number of valid pixels is less than or equal to the threshold, the parking space status is updated to "vacant".

2. The method according to claim 1, characterized in that, When the number of valid pixels exceeds a threshold, the parking space status is updated to "occupied," including: When the number of valid pixels is greater than the threshold and remains so for x frames, the parking space status is updated to "car present"; x is any positive integer. When the number of valid pixels is less than or equal to the threshold, the parking space status is updated to vacant, including: When the number of valid pixels is less than or equal to the threshold and continues for y frames, the parking space status is updated to idle; y is any positive integer.

3. The method according to claim 1, characterized in that, The depth image has a field of view of α in the vertical direction and a field of view of β in the horizontal direction. The vertical field of view α and the horizontal field of view β respectively satisfy: Where d is the horizontal distance between the image acquisition unit and the parking space line; L is the length of the parking space line; w is the width of the parking space line; and h is the height of the image acquisition unit from the ground.

4. The method according to claim 1, characterized in that, The pitch angle θ of the image acquisition unit satisfies: Where d is the distance between the image acquisition unit and the back of the parking space line; h is the height of the image acquisition unit above the ground; and α is the vertical field of view.

5. A parking space detection device, used in the method according to any one of claims 1-4, characterized in that, include: Processing unit, image acquisition unit, and storage unit; The image acquisition unit is used to acquire N consecutive frames of depth images of the parking space; The processing unit is configured to perform the following processing on the k-th frame depth image contained in the N-frame depth images, wherein the k-th frame depth image is any frame in the N-frame depth images: determine whether the pixel depth of each pixel point in the region of interest of the k-th frame depth image is within a preset range; generate the original binary image corresponding to the k-th frame depth image based on the determination result; perform a bitwise AND operation between the original binary image of the k-th frame depth image and the original binary image of the k-th frame depth image to generate a denoised binary image; k and m are both arbitrary positive integers, and m is less than or equal to k-1; count the number of pixels with valid values ​​in the denoised binary image; when the number of pixels with valid values ​​is greater than a threshold, update the parking space status to "occupied"; when the number of pixels with valid values ​​is less than or equal to the threshold, update the parking space status to "idle". The storage unit is used to store the parking space status.

6. The apparatus according to claim 5, characterized in that, The device further includes an interaction unit; at least one of the storage unit and the processing unit is electrically connected to the interaction unit; the interaction unit is used to obtain the parking space status stored in the storage unit.

7. The apparatus according to claim 5, characterized in that, The processing unit is used to generate the original binary image corresponding to the depth image of the k-th frame based on the comparison result, including: When the pixel depth of the pixel is not greater than the preset maximum value and the pixel depth of the pixel is not less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel is set to a valid value; When the pixel depth of the pixel is greater than the preset maximum value or the pixel depth of the pixel is less than the preset minimum value, the pixel value of the original binary image corresponding to the pixel is set to an invalid value. The original binary image is generated based on the valid values ​​and the invalid values.

8. The apparatus according to claim 5, characterized in that, The processing unit is used to update the parking space status to "occupied" when the number of valid pixels exceeds a threshold, including: When the number of valid pixels is greater than the threshold and remains so for x frames, the parking space status is updated to "car present"; x is any positive integer. The processing unit is further configured to update the parking space status to an idle state when the number of valid pixels is less than or equal to the threshold, including: When the number of valid pixels is less than or equal to the threshold and continues for y frames, the parking space status is updated to idle; y is any positive integer.

9. An electronic device, characterized in that, It includes a memory, a processor, and a depth camera; the memory stores a program that can run on the processor, which, when executed by the processor, causes the electronic device to perform the method of any one of claims 1 to 4.

10. A readable storage medium storing a program therein; characterized in that, When the program is executed, it implements the method of any one of claims 1 to 4.

Citation Information

Patent Citations

  • Free parking space detection method based on computer vision

    CN103065494A

  • Roadside parking intelligent monitoring method on basis of vacant parking space image detection

    CN106781680A