CN113518162A - Line exposure method, camera and computer readable storage medium - Google Patents

Line exposure method, camera and computer readable storage medium Download PDF

Info

Publication number
CN113518162A
CN113518162A CN202110372750.1A CN202110372750A CN113518162A CN 113518162 A CN113518162 A CN 113518162A CN 202110372750 A CN202110372750 A CN 202110372750A CN 113518162 A CN113518162 A CN 113518162A
Authority
CN
China
Prior art keywords
exposure
time
current
line
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110372750.1A
Other languages
Chinese (zh)
Other versions
CN113518162B (en
Inventor
卢二利
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202110372750.1A priority Critical patent/CN113518162B/en
Publication of CN113518162A publication Critical patent/CN113518162A/en
Application granted granted Critical
Publication of CN113518162B publication Critical patent/CN113518162B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/50Constructional details
    • H04N23/54Mounting of pick-up tubes, electronic image sensors, deviation or focusing coils
    • GPHYSICS
    • G03PHOTOGRAPHY; CINEMATOGRAPHY; ANALOGOUS TECHNIQUES USING WAVES OTHER THAN OPTICAL WAVES; ELECTROGRAPHY; HOLOGRAPHY
    • G03BAPPARATUS OR ARRANGEMENTS FOR TAKING PHOTOGRAPHS OR FOR PROJECTING OR VIEWING THEM; APPARATUS OR ARRANGEMENTS EMPLOYING ANALOGOUS TECHNIQUES USING WAVES OTHER THAN OPTICAL WAVES; ACCESSORIES THEREFOR
    • G03B7/00Control of exposure by setting shutters, diaphragms or filters, separately or conjointly
    • G03B7/08Control effected solely on the basis of the response, to the intensity of the light received by the camera, of a built-in light-sensitive device
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/70Circuitry for compensating brightness variation in the scene
    • H04N23/73Circuitry for compensating brightness variation in the scene by influencing the exposure time

Abstract

The application discloses a line exposure method, a camera and a computer readable storage medium, wherein the line exposure method firstly sends a current frame synchronization signal to an image sensor so that the image sensor acquires a current frame image by using line exposure; then, acquiring the current exposure central point time of a preset line in the current frame image by using the exposure parameter of line exposure and the current frame synchronous signal; then, obtaining an adjustment value by using the current exposure central point time and a plurality of peak times of alternating current for providing exposure energy for the image sensor; and finally, acquiring a next frame of synchronous signals by using the adjustment value, and sending the next frame of synchronous signals to the image sensor, so that when the image sensor acquires the next frame of image, the time of the next exposure central point of the preset line in the next frame of image is adjacent to the time of one peak in the next frame of image. The method and the device can place the preset line in the center of the interested area in the image, so that the exposure energy of the interested area is at the peak of the alternating current, and the interested area is at the bright place with alternate light and shade, thereby improving the recognition efficiency of the shot content.

Description

Line exposure method, camera and computer readable storage medium
Technical Field
The present application relates to the field of video surveillance technology, and in particular, to a line exposure method, a camera, and a computer-readable storage medium.
Background
With the development of video monitoring technology, monitoring cameras are arranged in most public areas, and when the cameras shoot in scenes with insufficient light, an external light source is needed to provide exposure energy, the external light source is usually powered by alternating current provided by mains supply, and the energy of the alternating current periodically changes in a sine wave form. However, when the exposure mode of the camera is line exposure, due to the periodic variation of the exposure energy, the brightness of the shot image may generate periodic variation along with the variation of the line number, that is, a phenomenon of alternate bright and dark appears on the image, and when a multi-frame image appears as a dynamic video, a band (Banding) appears on the video and flickers, thereby adversely affecting the identification of the shot content and reducing the monitoring effect.
Disclosure of Invention
The technical problem mainly solved by the application is to provide a line exposure method, a camera and a computer readable storage medium, which can improve the recognition efficiency of shot contents.
In order to solve the technical problem, the application adopts a technical scheme that: a method of enhancing line exposure, comprising:
sending a current frame synchronization signal to an image sensor so that the image sensor acquires a current frame image by using line exposure;
acquiring the current exposure central point time of a preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronous signal;
obtaining an adjustment value by using the current exposure central point time and a plurality of peak times of alternating current for providing exposure energy for the image sensor;
acquiring a next frame of synchronous signals by using the adjusting value, and sending the next frame of synchronous signals to the image sensor so that when the image sensor acquires a next frame of image, the time of a next exposure central point of a preset row in the next frame of image is adjacent to the time of one peak in the next frame of image; and the number of lines where the preset lines are located in the current frame image and the next frame image is the same.
Further, the step of obtaining the current exposure center point time of the preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronization signal includes:
acquiring a first product of the blanking line number and the interval time and a second product of the preset line number minus 1 and the interval time;
acquiring the current signal starting time of the current frame synchronization signal, the first product and the sum of the second products;
and taking the difference obtained by subtracting half of the duration from the sum as the current exposure center point time.
Further, the step of obtaining an adjustment value using the current exposure center point time and a plurality of peak times of an alternating current for supplying exposure energy to the image sensor includes:
acquiring a peak time closest to the current exposure central point time as a nearest peak time;
and taking the difference value between the latest peak time and the current exposure central point time as the adjusting value.
Further, the step of acquiring the next frame synchronization signal by using the adjustment value includes:
making the total duration of the next frame of synchronization signals the same as the total duration of the current frame of synchronization signals, and taking the sum of the starting time of the current signal, the adjustment value and the integral multiple of the alternating current period as the starting time of the next signal of the next frame of synchronization signals; wherein an integer multiple of the period of the alternating current is greater than or equal to the total duration and is closest to the total duration.
Further, the step of using the sum of the current signal start time, the adjustment value, and the integer multiple of the period of the alternating current as the next signal start time of the next frame synchronization signal includes:
in response to the adjustment value being equal to zero, directly taking the sum of the current signal start time and an integer multiple of the alternating current period as the next signal start time;
in response to the adjustment value being greater than zero, taking a time point obtained by adjusting the sum of the current signal starting time and the integral multiple of the alternating current period backwards according to the adjustment value as the next signal starting time;
and in response to the adjustment value being smaller than zero, taking the time point obtained by forward adjustment of the sum of the current signal starting time and the integral multiple of the alternating current period according to the adjustment value as the next signal starting time.
Further, before the step of obtaining the current exposure center point time of the preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronization signal, the method further includes:
setting a region of interest in the current frame image;
and setting the central row of the region of interest as the preset row.
Further, when the current frame image is the first frame image, the current signal start time and the total duration of the current frame synchronization signal are both preset.
Further, before the step of sending the current frame synchronization signal to the image sensor, the method further includes:
setting a first signal starting time of a first frame synchronization signal as an initial signal starting time, setting a total duration as a preset value, and setting the number of lines of a preset line in a first frame image;
acquiring the expected exposure central point time of the preset line by using the exposure parameters and the first frame synchronization signal;
acquiring a primary adjustment value by utilizing the predicted exposure central point time and the plurality of peak times;
and setting the starting time of the first signal as the starting time of the final signal by using the initial setting value, so that when the image sensor collects the first frame image, the actual exposure central point time of a preset line in the first frame image is adjacent to one peak time.
In order to solve the above technical problem, another technical solution adopted by the present application is: provided is a camera including:
a processor and an image sensor and a memory respectively coupled to the processor;
the memory stores program instructions, and the processor can execute the program instructions and cooperate with the image sensor to implement the line exposure method according to the above technical scheme.
In order to solve the above technical problem, another technical solution adopted by the present application is: there is provided a computer readable storage medium having stored thereon program instructions executable by a processor to implement the line exposure method of the above-described technical solution.
The beneficial effect of this application is: the line exposure method provided by the application firstly sends a current frame synchronization signal to an image sensor so that the image sensor acquires a current frame image by using line exposure; then, acquiring the current exposure central point time of a preset line in the current frame image by using the exposure parameter of line exposure and the current frame synchronous signal; then, obtaining an adjustment value by using the current exposure central point time and a plurality of peak times of alternating current for providing exposure energy for the image sensor; and finally, acquiring a next frame of synchronous signals by using the adjustment value, and sending the next frame of synchronous signals to the image sensor, so that when the image sensor acquires the next frame of image, the time of the next exposure central point of the preset line in the next frame of image is adjacent to the time of one peak in the next frame of image. The number of lines of the preset lines in the current frame image is the same as that of the lines of the preset lines in the next frame image. Therefore, the center position of the region of interest in the shot image can be set by the preset line, so that the exposure energy received by the region of interest is near the wave crest of the alternating current, the region of interest is in the bright place with alternate light and shade, the recognition efficiency of shot contents is improved, and the monitoring effect is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts. Wherein:
fig. 1 is a schematic structural diagram of an embodiment of a camera according to the present application;
FIG. 2 is a schematic flow chart diagram illustrating an embodiment of a line exposure method according to the present application;
FIG. 3 is a schematic diagram of the line exposure of the present application;
FIG. 4 is a flowchart illustrating an embodiment of a step before step S12 in FIG. 2;
FIG. 5 is a flowchart illustrating an embodiment of step S13 in FIG. 2;
FIG. 6 is a flowchart illustrating an embodiment of step S14 in FIG. 2;
FIG. 7 is a flowchart illustrating an embodiment of a step before step S11 in FIG. 2;
FIG. 8 is a schematic structural diagram of an embodiment of a computer-readable storage medium according to the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments that can be obtained by a person skilled in the art without making any inventive step based on the embodiments in the present application belong to the protection scope of the present application.
Referring to fig. 1, fig. 1 is a schematic structural diagram of an embodiment of a camera according to the present application, where the camera includes a processor 110, and an image sensor 120 and a memory 130 respectively coupled to the processor 110. The memory 130 stores program instructions, and the processor 110 can execute the program instructions and cooperate with the image sensor 120 to capture multiple frames of images in a line exposure manner to form a monitoring video. A specific exposure method will be described below.
When the camera operates, the image sensor 120 acquires an image according to the frame synchronization signals XVS, each frame synchronization signal corresponds to one frame of image, when the frame synchronization signals are generated by the image sensor 120, the image sensor 120 operates in the master mode, and when the frame synchronization signals are generated by the processor 110 and transmitted to the image sensor 120, the image sensor 120 operates in the slave mode. In this application, image sensor 120 operates in a slave mode, receiving a frame synchronization signal from processor 110 for each frame of image.
The image sensor 120 needs exposure when acquiring an image, and when the camera works in a scene with insufficient light, an external light source is needed to provide exposure energy, the external light source is usually powered by alternating current provided by mains supply, the energy of the alternating current periodically changes according to a sine wave form, and an expression of a voltage signal u (t) is as follows:
Figure BDA0003009984850000051
wherein, UmIn the voltage effective value, θ is an initial phase angle, f is the frequency of the alternating current energy, and is 100HZ in the european standard, 120HZ in the us standard, and 100HZ in the chinese standard.
When t takes different values, it corresponds to different voltage transients. For simplicity of calculation, assuming that θ is 0, the expression of the instantaneous energy l (t) of the external light source is the following formula (2):
L(t)=U2(t)/R=2L*sin2(πft)=L*(1+cos(2πft));……(2)
wherein R is the resistance of the external light source, and L ═ U2 mand/R represents the peak value of the brightness of the external light source.
In the present application, the image sensor 120 acquires an image by line exposure, and for each line in the same frame of image, the exposure time texpThe exposure start positions are different, the start position interval time Δ t is the same, and the image data of each line is read out within the interval time Δ t corresponding to the line.
When the ith line of a certain frame image is exposed, the exposure energy E (i) obtained by the ith line meets the following formula (3):
Figure BDA0003009984850000061
wherein t1 and t2 are ith row exposureStarting and ending points of light, texpT2-t1, the duration of the ith row exposure.
Then, when exposing the (i + m) th line of the frame image, the start point and the end point are (t1+ m Δ t) and (t2+ m Δ t), respectively, and the exposure energy E (i + m) obtained for the (i + m) th line satisfies the following formula (4):
Figure BDA0003009984850000062
it can be seen that if
Figure BDA0003009984850000063
When k is a positive integer, E (i) ═ E (i + m) ═ L × texpWhen t isexpWhen the exposure energy is integral multiple of (1/f), the exposure energy obtained by each line is the same, and the phenomenon of Banding between bright and dark can not occur. For example, if t is set when f is 100HZexpAnd k is 10ms, the bundling phenomenon cannot occur. However, in practical applications, t is generally limited in order to clearly capture an object moving at a high speed (e.g., a license plate of a car)expIf the time is less than 10ms, for example, 4ms, bright and dark stripes may be generated on the captured image, which is not favorable for recognizing the captured content, for example, the license plate number cannot be clearly recognized.
When t isexpIf the ratio is not an integral multiple of (1/f), i.e. there is a Banding phenomenon, if
Figure BDA0003009984850000064
When is at time
Figure BDA0003009984850000065
As is clear from the above equations (3) and (4), E (i) ═ E (i + m) is also satisfied. That is, the exposure energy obtained for two rows m apart is the same, m being the distance between adjacent light stripes or adjacent dark stripes, and if m is large enough (i.e., Δ t is small enough), the effect of the Banding phenomenon will be small enough. However, due to hardware limitations of the image sensor 120, there is generally a minimum Δ t, that is, the Banding phenomenon still affects recognition of the shot content.
To solve the technical problem, the present application provides a line exposure method, and specifically please refer to fig. 2, fig. 2 is a flowchart illustrating an embodiment of the line exposure method, where an execution main body of the line exposure method is the processor 110, and the method specifically includes the following steps.
Step S11, sending a current frame synchronization signal to the image sensor, so that the image sensor captures a current frame image using line exposure.
Referring to fig. 3, fig. 3 is a schematic diagram illustrating the principle of line exposure according to the present application, when the image sensor 120 receives a current frame synchronization signal (current XVS) sent by the processor 110, the image sensor starts to acquire a current frame image, and a current signal start time t of the current frame synchronization signalxvs_downThe moment when the acquisition starts.
Step S12, acquiring the current exposure center point time of the preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronization signal.
Wherein the exposure parameter comprises a duration t of each line of exposureexpThe interval time delta t between the exposure starting points of adjacent lines and the blanking line number FS from the signal starting point of the frame synchronizing signal to the exposure of the first line. The blank area between the left and right filled areas of each row in FIG. 3 is the duration t of the exposureexp=tn_2-tn_1The interval time Δ t is also the time required for reading each line of data, wherein the time t is from the starting point of the current signalxvs_downUntil the start of outputting the valid data of the first line, there is a time FS Δ t corresponding to the blanking line FS in the middle. The left and right padding areas of each row in fig. 3 represent Δ t.
The camera is generally fixedly installed at a preset position, and multiple frames of images shot by the camera include the same scene, for example, the same intersection, that is, the content (for example, a license plate) which is most desired to be clearly recognized is located at the same position in each frame of image. Therefore, before the step S12, please refer to fig. 4, where fig. 4 is a flowchart illustrating an embodiment of the step before the step S12 in fig. 2, and the method further includes the following steps before the current exposure center point time is obtained.
In step S21, a region of interest is set in the current frame image.
After the current frame image is acquired, the region of interest, i.e. the region where the content that is most desired to be clearly identified is located, is located according to the current frame image.
In step S22, the center row of the region of interest is set as a preset row.
The central row of the region of interest is then set as a preset row. The method and the device for recognizing the license plate of the automobile have the advantages that the preset lines are arranged in the content which is most expected to be clearly recognized in the monitored image, for example, the preset lines are arranged in the area where the license plate of the automobile is located. Assuming that the number of lines of the preset line in the current frame image is n, the current exposure center point time t of the preset line in the current frame image can be obtained through the following stepsn_mid
Step one, acquiring a first product FS x delta t of blanking line number FS and interval time delta t, and a second product (n-1) x delta t of interval time delta t after subtracting 1 from line number n of preset lines;
step two, acquiring the current signal starting point time t of the current frame synchronous signalxvs_downA first product FS Δ t and a sum (t) of a second product (n-1) Δ txvs_down+FS*Δt+ (n-1)*Δt);
Step three, adding the sum value (t)xvs_down+ FS Δ t + (n-1) Δ t) minus duration texpHalf of the resulting difference (t)xvs_down+FS*Δt+(n-1)*Δt-texp/2) as the current exposure center point time tn_mid
That is, the current exposure center point time t of the nth row in the current frame imagen_midSatisfies the following formula (5):
tn_mid=txvs_down+FS*Δt+(n-1)*Δt-texp/2;......(5)
it can be seen that, in any frame synchronization signal, the distance between the time of the signal starting point and the time of the exposure center point of the preset line is (FS × Δ t + (n-1) × Δ t-t)exp2), i.e., the time lengths represented by L1 and L2 in fig. 3 are equal.
In step S13, an adjustment value is obtained using the current exposure center point time and a plurality of peak times of the alternating current that supplies the exposure energy to the image sensor.
As mentioned above, the energy of the ac generally varies periodically in the form of a sine wave, and the peak times of the ac can be obtained by using a detection method known in the art, and then the current exposure center point time t can be usedn_midAnd the plurality of peak time acquisition adjustment values taj
Referring to fig. 5, fig. 5 is a flowchart illustrating an embodiment of step S13 in fig. 2, wherein the adjustment value t can be obtained by the following stepsaj
In step S31, a peak time closest to the current exposure center point time is obtained as the latest peak time.
Firstly, selecting a peak time closest to the time of the current exposure central point from a plurality of peak times as a latest peak time tpeak
In step S32, the difference between the latest peak time and the current exposure center time is used as an adjustment value.
Obtaining the latest peak time tpeakThen, it is compared with the current exposure center point time tn_midThe difference between the two is used as the adjusting value taj. That is, the value t is adjustedajSatisfies the following formula (6):
taj=tpeak-txvs_down-(FS*Δt+(n-1)*Δt-texp/2);......(6)
from the foregoing, tpeak、txvs_down、(FS*Δt+(n-1)*Δt-texp/2) can be calculated, the value t is adjustedajCan also be obtained by calculation, and is convenient for follow-up according to the adjustment value tajThe next frame synchronization signal is obtained.
Step S14, obtaining a next frame synchronization signal by using the adjustment value, and sending the next frame synchronization signal to the image sensor, so that when the image sensor collects a next frame image, the time of a next exposure center point of a preset row in the next frame image is adjacent to the time of one of the peaks.
Specifically, the adjustment value t is acquiredajThereafter, the total duration of the next frame synchronization signal (next XVS in FIG. 3) is first keptThe total duration of the previous frame synchronization signal (current XVS in FIG. 3) is the same, and the current signal is started at time txvs_downAdjusting the value tajAnd the sum of integral multiples (k × T ') of the ac power period T' is used as the next signal start time T 'of the next frame synchronization signal'xvs_down. The integral multiple of the period T 'of the alternating current is greater than or equal to the total duration T and is closest to the total duration T, i.e., a suitable integer k is selected such that k × T' is greater than or equal to T and is closest to T. Therefore, the next signal start time t'xvs_downSatisfies the following formula (7):
t′xvs_down=txvs_down+taj+k*T′;......(7)
that is, the adjustment value t is first adjustedajMoving the current signal start time txvs_downMake the current exposure center point time t in the current frame synchronization signaln_midWith the most recent peak time tpeakAnd overlapping, and then integrally shifting the current frame synchronizing signal backward by k × T' time to obtain the next frame synchronizing signal. Due to the current signal starting time txvs_downTime t from current exposure center pointn_midTime interval therebetween and next signal start time t'xvs_downAnd next exposure center point time t'n_midThe time interval between the two is the same, namely L1 ═ L2 ═ FS ═ Δ t + (n-1) × Δ t-texp/2, so in the next frame sync signal, the next exposure center point time t'n_midMust coincide with another peak time, which is the most recent peak time tpeakFollowed by the k-th peak time.
Wherein, in order not to influence the acquisition of the current frame image, k × T '≧ T needs to be ensured, and in order to improve the exposure efficiency, k × T' needs to be ensured to be closest to T. For example, T 'is 10ms, if 990ms < T ≦ 1000ms, k is 100, and if 1000ms < T ≦ 1010ms, k is 101, i.e., after the current frame sync signal, it is necessary to wait for (k × T' -T) to reach the next signal start time T ″.xvs_down
The next frame synchronization signal thus formed is sent to the image sensor 120, so that the image sensor 120 captures the next frame imageIn time, the next exposure center point time t 'of the preset line in the next frame image'n_midAdjacent to one of the peak times (theoretical calculation is to make the next exposure center point time t'n_midCoincides with one of the peaks, but the signal transmission process may be disturbed, so the next exposure center point time t'n_midIn temporal proximity to one of the peaks).
In the embodiment, the preset line is set at the center position of the interest area in the shot image, and the next frame of synchronous signal is obtained according to the adjustment value, so that the time of the next exposure central point of the preset line in the next frame of image is adjacent to the time of one peak, and the exposure energy received by the center line of the interest area in the next frame of image is near to the peak position of the alternating current. That is to say, this application makes the region of interest be in alternate bright and dark department, can improve the recognition efficiency to the content of shooing, improves the monitoring effect.
In some embodiments, referring to fig. 6, fig. 6 is a flowchart illustrating an embodiment of step S14 in fig. 2, wherein the next frame synchronization signal can be obtained through the following steps.
Step S41, in response to the adjustment value being equal to zero, directly taking the sum of the current signal start time and the integer multiple of the alternating current period as the next signal start time.
If the value t is adjustedajEqual to zero, indicating the current exposure center point time t of the preset line in the current frame imagen_midWith the most recent peak time tpeakThe superposition, that is, the preset line can obtain the peak value of the exposure energy, so that the preset line is positioned at the center of the bright stripe, the region of interest is positioned at the bright place, the frame synchronization signal does not need to be adjusted, and the starting time t of the current signal is directly obtainedxvs_downAnd the sum of the time and an integral multiple k × T ' of the period of the alternating current is used as the starting time T ' of the next signal 'xvs_downThat is, the next frame of synchronization signal is generated according to the periodic rule of the alternating current, so that the preset line in the next frame of image can also obtain the peak value of the exposure energy.
And step S42, responding to the adjustment value being larger than zero, and taking the time point obtained by adjusting the sum of the current signal starting time and the integral multiple of the alternating current period backwards according to the adjustment value as the next signal starting time.
If the value t is adjustedajIf the value is larger than zero, the current exposure central point time t of the preset line in the current frame image is illustratedn_midWith the most recent peak time tpeakNon-coincidence, most recent peak time tpeakAt the current exposure center point time tn_midThen, the preset line does not obtain the peak value of the exposure energy, and in order to make the preset line located at the center of the bright stripe in the next frame of image, the starting time t of the current signal needs to be started firstxvs_downAccording to the adjustment value tajAdjusting backward to make the current exposure central point time tn_midWith the most recent peak time tpeakAdjacent to the current signal, and adjusting the starting time t of the current signalxvs_downThe time point obtained by integral multiple k × T 'of the backward alternating current period is used as the next signal starting point time T'xvs_down. I.e. according to the adjustment value tajAnd moving the current frame synchronous signal, and generating a next frame synchronous signal according to the periodic rule of the alternating current, so that the preset line in the next frame image can also obtain the peak value of the exposure energy.
And step S43, responding to the adjustment value being smaller than zero, and taking the time point obtained by forward adjusting the sum of the current signal starting time and the integral multiple of the alternating current period according to the adjustment value as the next signal starting time.
If the value t is adjustedajLess than zero, it indicates the current exposure center point time t of the preset line in the current frame imagen_midWith the most recent peak time tpeakNon-coincidence, most recent peak time tpeakAt the current exposure center point time tn_midPreviously, as shown in fig. 3, the preset line does not obtain the peak value of the exposure energy, and to make the preset line located at the center of the bright stripe in the next frame image, it is necessary to first determine the starting time t of the current signalxvs_downAccording to the adjustment value tajAdjusting forward to make the current exposure central point time tn_midWith the most recent peak time tpeakAdjacent to the current signal, and adjusting the starting time t of the current signalxvs_downThe time point obtained by shifting back the integral multiple k × T' of the period of the alternating current is used as the starting point of the next signalTime t'xvs_down. I.e. according to the adjustment value tajAnd moving the current frame synchronous signal, and generating a next frame synchronous signal according to the periodic rule of the alternating current, so that the preset line in the next frame image can also obtain the peak value of the exposure energy.
As can be seen from FIG. 3, in the current XVS, tpeakAt tn_midBefore and at a distance of tajAt the time interval of (c), it is necessary to shift the current XVS as a whole forward by tajAnd then overall backward shifting k x T 'to obtain the next XVS, wherein T'n_midIn temporal proximity to another peak.
In the next frame of synchronization signal generated in this embodiment, the time of the next exposure center point of the preset line is adjacent to the time of one of the wave peaks, so that the exposure energy received by the center line of the region of interest in the next frame of image is in the vicinity of the position of the wave peak of the alternating current. That is to say, this application makes the region of interest be in alternate bright and dark department, can improve the recognition efficiency to the content of shooing, improves the monitoring effect.
As can be seen from the foregoing description, the line exposure method provided in the present application is an iterative adjustment process, and continuously adjusts the next frame of synchronization signal according to the current frame of synchronization signal, so that the exposure center point time of the preset line approaches the peak time of the alternating current indefinitely. When the first frame image is collected, data of the previous frame image can not be used as an adjustment basis, so that the signal starting time and the total duration of the first frame synchronization signal are set to be preset, namely the signal starting time and the total duration of the first frame synchronization signal are set according to an empirical value, and then the first frame synchronization signal is adjusted by combining with the peak time to generate a second frame synchronization signal, and the second frame synchronization signal is iterated in sequence.
In other embodiments, the first frame synchronization signal may be generated in other manners, please refer to fig. 7, fig. 7 is a flowchart illustrating an embodiment of a step before step S11 in fig. 2, and before the iterative process starts, the first frame synchronization signal is generated through the following steps.
In step S51, the first signal start time of the first frame synchronization signal is set as the initial signal start time, the total duration is set as a preset value, and the number of lines in the first frame image where the preset line is located is set.
Firstly, setting the starting time of the first signal of the first frame synchronization signal as the starting time t of the initial signal according to the empirical value1_0And setting the total time length T as a preset value, and setting the number n of rows where preset rows are located in the first frame image. At this time, the first frame synchronization signal is not transmitted to the image sensor 120, but rather, an assumed first frame synchronization signal is generated, and after initial adjustment, a real first frame synchronization signal is formed and then transmitted to the image sensor 120.
In step S52, the expected exposure center point time of the preset line is obtained by using the exposure parameters and the first frame synchronization signal.
Specifically, as can be seen from the above equation (5), the exposure center point time t is predicted1_mid0Satisfies the following formula (8):
t1_mid0=t1_0+FS*Δt+(n-1)*Δt-texp/2......(8)
in step S53, the expected exposure center point time and the plurality of peak times are used to obtain the initial setting values.
Specifically, as can be seen from the above equation (6), the initial value t1_ajSatisfies the following formula (9):
t1_aj=t1_peak-t1_0-(FS*Δt+(n-1)*Δt-texp/2);......(9)
wherein, t1_peakIs calculated as the time t corresponding to the predicted exposure center point1_mid0The closest peak time.
Step S54, setting the first signal start time as the final signal start time by using the initial value, so that when the image sensor collects the first frame image, the actual exposure center point time of the preset line in the first frame image is adjacent to one of the peak times.
Then according to the initial value t1_ajSetting the starting time of the first signal as the starting time t of the final signal1_1Specifically, the final signal start time t is obtained according to the following formula (10)1_1
t1_1=t1_0+t1_aj;......(10)
And then generating a first frame synchronization signal by combining the total time length T. That is, the first frame synchronization signal assumed in advance is adjusted to be the real first frame synchronization signal, and is transmitted to the image sensor 120. When the image sensor 120 acquires the first frame image, the time of the actual exposure center point of the preset line in the first frame image is adjacent to the time of one peak, and the region of interest of the preset line is located at the bright position of the light and shade stripe, so that the identification efficiency of the region of interest of the first frame image is improved.
Based on the same inventive concept, the present application further provides a computer-readable storage medium, please refer to fig. 8, fig. 8 is a schematic structural diagram of an embodiment of the computer-readable storage medium of the present application, the storage medium 800 stores program instructions 810, and the program instructions 810 can be executed by a processor to implement the line exposure method according to any of the above embodiments. For details, reference may be made to the above embodiments, which are not described herein again.
The above description is only for the purpose of illustrating embodiments of the present application and is not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application or are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (10)

1. A line exposure method, comprising:
sending a current frame synchronization signal to an image sensor so that the image sensor acquires a current frame image by using line exposure;
acquiring the current exposure central point time of a preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronous signal;
obtaining an adjustment value by using the current exposure central point time and a plurality of peak times of alternating current for providing exposure energy for the image sensor;
acquiring a next frame of synchronous signals by using the adjusting value, and sending the next frame of synchronous signals to the image sensor so that when the image sensor acquires a next frame of image, the time of a next exposure central point of a preset row in the next frame of image is adjacent to the time of one peak in the next frame of image; and the number of lines where the preset lines are located in the current frame image and the next frame image is the same.
2. The line exposure method according to claim 1, wherein the exposure parameters include duration of each line exposure, interval time between adjacent line exposure start points, and blanking line number from a signal start point of a frame synchronization signal to a time before a first line exposure, and the step of obtaining a current exposure center point time of a preset line in the current frame image using the exposure parameters of the line exposure and the current frame synchronization signal comprises:
acquiring a first product of the blanking line number and the interval time, and a second product of the line number of the preset line and the interval time;
acquiring the current signal starting time of the current frame synchronization signal, the first product and the sum of the second products;
and taking the difference obtained by subtracting half of the duration from the sum as the current exposure center point time.
3. The line exposure method according to claim 2, wherein the step of obtaining the adjustment value using the current exposure center point time and a plurality of peak times of an alternating current that supplies the exposure energy to the image sensor comprises:
acquiring a peak time closest to the current exposure central point time as a nearest peak time;
and taking the difference value between the latest peak time and the current exposure central point time as the adjusting value.
4. The line exposure method according to claim 3, wherein the step of acquiring the next frame synchronization signal using the adjustment value comprises:
making the total duration of the next frame of synchronization signals the same as the total duration of the current frame of synchronization signals, and taking the sum of the starting time of the current signal, the adjustment value and the integral multiple of the alternating current period as the starting time of the next signal of the next frame of synchronization signals; wherein an integer multiple of the period of the alternating current is greater than or equal to the total duration and is closest to the total duration.
5. The line exposure method according to claim 4, wherein the step of taking the sum of the current signal start time, the adjustment value, and an integer multiple of the period of the alternating current as the next signal start time of the next frame synchronization signal comprises:
in response to the adjustment value being equal to zero, directly taking the sum of the current signal start time and an integer multiple of the alternating current period as the next signal start time;
in response to the adjustment value being greater than zero, taking a time point obtained by adjusting the sum of the current signal starting time and the integral multiple of the alternating current period backwards according to the adjustment value as the next signal starting time;
and in response to the adjustment value being smaller than zero, taking the time point obtained by forward adjustment of the sum of the current signal starting time and the integral multiple of the alternating current period according to the adjustment value as the next signal starting time.
6. The line exposure method according to claim 1, wherein before the step of obtaining the current exposure center point time of the preset line in the current frame image by using the exposure parameter of the line exposure and the current frame synchronization signal, the method further comprises:
setting a region of interest in the current frame image;
and setting the central row of the region of interest as the preset row.
7. The line exposure method according to claim 6, wherein when the current frame image is the first frame image, the current signal start time and the total duration of the current frame synchronization signal are both preset.
8. The line exposure method of claim 1, wherein the step of sending the current frame synchronization signal to the image sensor is preceded by:
setting a first signal starting time of a first frame synchronization signal as an initial signal starting time, setting a total duration as a preset value, and setting the number of lines of a preset line in a first frame image;
acquiring the expected exposure central point time of the preset line by using the exposure parameters and the first frame synchronization signal;
acquiring a primary adjustment value by utilizing the predicted exposure central point time and the plurality of peak times;
and setting the starting time of the first signal as the starting time of the final signal by using the initial setting value, so that when the image sensor collects the first frame image, the actual exposure central point time of a preset line in the first frame image is adjacent to one peak time.
9. A camera, comprising:
a processor and an image sensor and a memory respectively coupled to the processor;
wherein the memory stores program instructions executable by the processor to implement the line exposure method of any one of claims 1 to 8 in cooperation with the image sensor.
10. A computer-readable storage medium, characterized in that the computer-readable storage medium stores program instructions executable by a processor to implement the line exposure method of any one of claims 1-8.
CN202110372750.1A 2021-04-07 2021-04-07 Line exposure method, camera and computer readable storage medium Active CN113518162B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110372750.1A CN113518162B (en) 2021-04-07 2021-04-07 Line exposure method, camera and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110372750.1A CN113518162B (en) 2021-04-07 2021-04-07 Line exposure method, camera and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN113518162A true CN113518162A (en) 2021-10-19
CN113518162B CN113518162B (en) 2023-04-07

Family

ID=78061345

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110372750.1A Active CN113518162B (en) 2021-04-07 2021-04-07 Line exposure method, camera and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN113518162B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114025055A (en) * 2021-11-29 2022-02-08 上海商汤临港智能科技有限公司 Data processing method, device, system, equipment and storage medium
CN114158156A (en) * 2022-02-10 2022-03-08 深圳佑驾创新科技有限公司 PWM (pulse-width modulation) adjusting method, device, equipment and storage medium of light supplementing lamp

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5254438A (en) * 1990-11-29 1993-10-19 Hewlett-Packard Company Single pass compensation for electron beam proximity effect
JP2009077057A (en) * 2007-09-19 2009-04-09 Olympus Imaging Corp Imaging apparatus, and control method for imaging apparatus
US20140333825A1 (en) * 2013-05-10 2014-11-13 Canon Kabushiki Kaisha Imaging apparatus, control method, and storage medium
US20150138392A1 (en) * 2013-11-20 2015-05-21 Canon Kabushiki Kaisha Image capturing apparatus, method of controlling the same, and storage medium
JP2018006804A (en) * 2016-06-27 2018-01-11 キヤノン株式会社 Imaging apparatus, control method therefor, and program
JP2018006802A (en) * 2016-06-27 2018-01-11 キヤノン株式会社 Imaging apparatus, control method therefor, and program
US20180213141A1 (en) * 2017-01-26 2018-07-26 Qualcomm Incorporated Methods and apparatus for synchronizing camera flash and sensor blanking
US20180309919A1 (en) * 2017-04-19 2018-10-25 Qualcomm Incorporated Methods and apparatus for controlling exposure and synchronization of image sensors
JP2019022023A (en) * 2017-07-13 2019-02-07 キヤノン株式会社 Imaging apparatus and control method of the same
CN111818272A (en) * 2020-06-30 2020-10-23 浙江大华技术股份有限公司 Method for eliminating image flicker, electronic device and storage medium
US20200344398A1 (en) * 2019-04-29 2020-10-29 Samsung Electronics Co., Ltd. Image capture with anti-flicker synchronization
CN112437206A (en) * 2020-11-25 2021-03-02 杭州海康威视数字技术股份有限公司 Light supplement control method and camera

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5254438A (en) * 1990-11-29 1993-10-19 Hewlett-Packard Company Single pass compensation for electron beam proximity effect
JP2009077057A (en) * 2007-09-19 2009-04-09 Olympus Imaging Corp Imaging apparatus, and control method for imaging apparatus
US20140333825A1 (en) * 2013-05-10 2014-11-13 Canon Kabushiki Kaisha Imaging apparatus, control method, and storage medium
US20150138392A1 (en) * 2013-11-20 2015-05-21 Canon Kabushiki Kaisha Image capturing apparatus, method of controlling the same, and storage medium
JP2018006804A (en) * 2016-06-27 2018-01-11 キヤノン株式会社 Imaging apparatus, control method therefor, and program
JP2018006802A (en) * 2016-06-27 2018-01-11 キヤノン株式会社 Imaging apparatus, control method therefor, and program
US20180213141A1 (en) * 2017-01-26 2018-07-26 Qualcomm Incorporated Methods and apparatus for synchronizing camera flash and sensor blanking
US20180309919A1 (en) * 2017-04-19 2018-10-25 Qualcomm Incorporated Methods and apparatus for controlling exposure and synchronization of image sensors
JP2019022023A (en) * 2017-07-13 2019-02-07 キヤノン株式会社 Imaging apparatus and control method of the same
US20200344398A1 (en) * 2019-04-29 2020-10-29 Samsung Electronics Co., Ltd. Image capture with anti-flicker synchronization
CN111818272A (en) * 2020-06-30 2020-10-23 浙江大华技术股份有限公司 Method for eliminating image flicker, electronic device and storage medium
CN112437206A (en) * 2020-11-25 2021-03-02 杭州海康威视数字技术股份有限公司 Light supplement control method and camera

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114025055A (en) * 2021-11-29 2022-02-08 上海商汤临港智能科技有限公司 Data processing method, device, system, equipment and storage medium
CN114158156A (en) * 2022-02-10 2022-03-08 深圳佑驾创新科技有限公司 PWM (pulse-width modulation) adjusting method, device, equipment and storage medium of light supplementing lamp

Also Published As

Publication number Publication date
CN113518162B (en) 2023-04-07

Similar Documents

Publication Publication Date Title
CN113518162B (en) Line exposure method, camera and computer readable storage medium
JP5866200B2 (en) Flicker detection circuit for image sensor using rolling shutter
JP6132510B2 (en) 3D video acquisition device and depth information calculation method in 3D video acquisition device
CN103583035B (en) The flicker detection of spatial variations
US11425358B2 (en) Method and system for unsynchronized structured lighting
JP2009164774A (en) Image processing apparatus, image processing method, program, and storage medium
CN105049736A (en) Multi-exposure imaging system and method for eliminating rolling shutter flicker
CN110445952A (en) Film flicker processing method, device, equipment and the storage medium of camera
US20210250488A1 (en) Reducing a Flicker Effect of Multiple Light Sources in an Image
CN110971835A (en) Monitoring method and device based on double-phase exposure
TW200849972A (en) Circuit and method for regulating image clock
US20240114255A1 (en) Signal processing device, signal processing method, and detection sensor
WO2019005051A1 (en) Camera communications system using high speed camera sensors
WO2018214838A1 (en) Surveillance image capture method, apparatus, and system
CN106303257B (en) Synchronous control method and device and image acquisition system
CN104184977A (en) Projection method and electronic equipment
CN110958361A (en) Image pickup apparatus capable of HDR composition, control method therefor, and storage medium
US20140043502A1 (en) Flicker noise detection apparatus, flicker noise detection method, and computer-readable storage device storing flicker noise detection program
CN112287805A (en) Moving object detection method and device, readable storage medium and electronic equipment
JP5383886B2 (en) Image processing apparatus, image processing method, program, and storage medium
CN103957361A (en) Exposure method and apparatus for monitoring camera
CN113301220A (en) Synchronization method for vehicle-mounted camera and vehicle lamp and FPGA chip
WO2013165377A1 (en) A system and method of modifying the dynamic range
JP3128467B2 (en) How to convert 2D video to 3D video
CN109328373B (en) Image processing method, related device and storage medium thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant