Image acquisition method and device, electronic equipment and storage medium

By determining the combined frame number and the scanning start time offset, the problem of difficult to suppress image light and dark fringes and prevent image overexposure in the prior art is solved, and the purpose of improving image acquisition quality is achieved.

CN120201327APending Publication Date: 2025-06-24ZHEJIANG UNIVIEW TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311787952.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-22
Publication Date
2025-06-24

AI Technical Summary

Technical Problem

The prior art is difficult to improve image quality while both suppressing light and dark stripes in the image and preventing image overexposure.

Method used

By determining the combined frame number of the target image and determining the scan start time offset based on the combined frame number, the time difference value at the scan start time of the scan start time of the adjacent two frames is characterized. Scans based on this time difference value to obtain a scanned image corresponding to the number of merged frames and merge them to obtain a target image.

Benefits of technology

It realizes the image quality of image acquisition while suppressing light and dark stripes while preventing images from passing through, and improves the image quality of image acquisition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120201327A_ABST
    Figure CN120201327A_ABST
Patent Text Reader

Abstract

The invention provides an image acquisition method and device, electronic equipment and a storage medium, and relates to the technical field of image processing. The method comprises the following steps: determining a combined frame number of a target image; determining a scanning starting time offset based on the combined frame number; the scanning starting time offset is used for representing a time difference value of scanning starting moments of two adjacent frames of scanning images; the time difference value is obtained based on an energy period and the combined frame number; scanning based on the scanning starting time offset to obtain a scanning image corresponding to the combined frame number; and combining the scanned images to obtain the target image. After the scanning images corresponding to the merging frame number are merged, the target image with the energy being a fixed value, namely the target image with the brightness being a fixed value, can be obtained, and the brightness of each target image is the same, so that the stripe-free target image can be obtained under the condition of no overexposure, and the quality of the collected image is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of image processing, and in particular, to an image acquisition method, apparatus, electronic device, and storage medium. Background Art

[0002] When generating an image through an image sensor, a global scan or a line-by-line scan can be used to scan each pixel to generate an image. When a CMOS (Complementary Metal Oxide Semiconductor) line-by-line scan image sensor generates an image by line-by-line scanning, bright and dark stripes may be generated in the generated image due to changes in light energy or strobing of an electronic screen, and the stripes will result in a low quality of the image.

[0003] Specifically, the frequency of light energy change or the refresh frequency of the electronic screen will cause bright and dark stripes to be generated in each generated image. If the shutter time of the image sensor is adjusted to suppress the obviousness of the bright and dark stripes in the generated image, the generated image may be overexposed, resulting in a low quality of the image.

[0004] Therefore, how to balance suppressing stripes and preventing image overexposure to improve the quality of the image has become an urgent problem to be solved. Summary of the Invention

[0005] The present invention provides an image acquisition method, apparatus, electronic device, and storage medium, which are used to solve the defect in the prior art that the image quality cannot be improved while balancing stripe suppression and preventing image overexposure, and achieve the purpose of improving the quality of the acquired image.

[0006] The present invention provides an image acquisition method, including:

[0007] Determine the merging frame number of the target image;

[0008] Based on the merging frame number, determine a scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on an energy period and the merging frame number;

[0009] Perform scanning based on the scanning start time offset to obtain a scanned image corresponding to the merging frame number;

[0010] Merge the scanned images to obtain the target image.

[0011] According to an image acquisition method provided by the present invention, the time difference is the ratio of the energy period to the merging frame number.

[0012] An image acquisition method provided by the present invention, wherein determining the number of frames to be merged for the target image includes:

[0013] Receiving a frame number configuration instruction input by the user;

[0014] In response to the frame number configuration instruction, outputting a frame number configuration interface, where the frame number configuration interface includes a target selection control, and the target selection control includes a frame number selection control and / or a frame rate selection control;

[0015] Receiving a frame number selection instruction triggered by the user based on the target selection control;

[0016] In response to the frame number selection instruction, determining the number of frames to be merged.

[0017] An image acquisition method provided by the present invention, wherein scanning based on the scanning start time offset to obtain the scanning images corresponding to the number of frames to be merged includes:

[0018] Obtaining the second scanning start moment of the current frame scanning image, and scanning the current frame scanning image based on the second scanning start moment;

[0019] Based on the second scanning start moment and the scanning start time offset, determining the first scanning start moment of the next frame scanning image;

[0020] Scanning the next frame scanning image based on the first scanning start moment until the scanning images corresponding to the number of frames to be merged are obtained.

[0021] The present invention further provides an image acquisition method, including:

[0022] Performing at least one image acquisition process to obtain the target image output by the at least one image acquisition process;

[0023] Wherein, the image acquisition process includes:

[0024] Determining the number of frames to be merged for the target image;

[0025] Based on the number of frames to be merged, determining a scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start moments of two adjacent frame scanning images; the time difference is obtained based on the energy period and the number of frames to be merged;

[0026] Scanning based on the scanning start time offset to obtain the scanning images corresponding to the number of frames to be merged;

[0027] Merging the scanning images to obtain the target image.

[0028] The present invention further provides an image acquisition device, including:

[0029] A determination module, configured to determine the number of merged frames of a target image;

[0030] The determination module is further configured to determine a scanning start time offset based on the number of merged frames; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames;

[0031] A scanning module, configured to perform scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames;

[0032] A merging module, configured to merge the scanned images to obtain the target image.

[0033] The present invention further provides an image acquisition device, including:

[0034] An acquisition module, configured to execute at least one image acquisition process to obtain a target image output by the at least one image acquisition process;

[0035] Wherein, the image acquisition process includes:

[0036] Determine the number of merged frames of the target image;

[0037] Determine a scanning start time offset based on the number of merged frames; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames;

[0038] Perform scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames;

[0039] Merge the scanned images to obtain the target image.

[0040] The present invention further provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where when the processor executes the computer program, the image acquisition method as described in any one of the above is implemented.

[0041] The present invention further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the image acquisition method as described in any one of the above is implemented.

[0042] The present invention further provides a computer program product, including a computer program, and when the computer program is executed by a processor, the image acquisition method as described in any one of the above is implemented.

[0043] The image acquisition method, device, electronic device and storage medium provided by the present invention determine the number of merged frames of a target image; based on the number of merged frames, determine the scanning start time offset, where the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images, and the time difference is obtained based on the energy period and the number of merged frames; perform scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames; and merge the scanned images to obtain the target image. In this way, based on the scanning start time offset representing the time difference between the scanning start times of two adjacent scanned images, scanned images corresponding to the number of merged frames can be scanned, and the target image obtained by merging the scanned images is an image with a constant energy, that is, the brightness of the target image is constant. When the brightness of each target image is the same, the bright and dark stripes of the image are suppressed, thus achieving the purpose of improving the image quality while taking into account stripe suppression and preventing overexposure. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0045] Figure 1 is one of the schematic flowcharts of the image acquisition method provided by the embodiment of the present invention;

[0046] Figure 2 is a schematic diagram of the energy period provided by the embodiment of the present invention;

[0047] Figure 3 is a schematic diagram of the energy of the target image provided by the embodiment of the present invention;

[0048] Figure 4 is the second schematic flowchart of the image acquisition method provided by the embodiment of the present invention;

[0049] Figure 5 is one of the schematic structural diagrams of the image acquisition device provided by the embodiment of the present invention;

[0050] Figure 6 is the second schematic structural diagram of the image acquisition device provided by the embodiment of the present invention;

[0051] Figure 7 is the schematic physical structure diagram of the electronic device provided by the embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0052] To make the objectives, technical solutions and advantages of the present invention more clear, the technical solutions in the present invention will be clearly and completely described below with reference to the accompanying drawings in the present invention. Apparently, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present invention without making creative efforts fall within the scope of protection of the present invention.

[0053] It should be noted that the serial numbers assigned to the objects described in the present invention itself, such as "first", "second", etc., are only used to distinguish the described objects and do not have any sequential or technical meanings.

[0054] In practical applications, when there is light energy with periodic energy changes in the environment where images are collected, there will be bright and dark stripes in each collected image, resulting in low quality of the collected images. The present invention determines the scanning start time offset based on the merged frame number of the target image, performs scanning based on the scanning start time offset, can obtain the scanning images corresponding to the merged frame number, and then merges the scanning images to obtain a target image with a constant energy value. Therefore, the merged target image is a target image with a constant brightness value, so the bright and dark stripes in each target image are suppressed, and the shutter time is not increased, and image overexposure does not occur. Therefore, it is possible to suppress bright and dark stripes while preventing image overexposure, and improve the quality of the collected images.

[0055] The execution subject of the image acquisition method provided by the embodiments of the present invention can be an electronic device such as a camera, a video camera, a mobile phone, a computer, a server or a server cluster, or a specially designed intelligent device, or an image acquisition device provided in the electronic device or the intelligent device. The image acquisition device can be implemented by software, hardware or a combination of both.

[0056] The method of the present invention is applicable to various application scenarios of image acquisition. The execution subjects in each application scenario include image sensors that can precisely adjust the inter-frame scanning time. For example, a scenario of video shooting based on a mobile phone with an image sensor that can precisely adjust the inter-frame scanning time, or a scenario of video surveillance based on a camera with an image sensor that can precisely adjust the inter-frame scanning time, etc. The following Figures 1 to 3 describes the image acquisition method provided by the embodiments of the present invention. Figure 1 is one of the flow diagrams of the image acquisition method provided by the embodiments of the present invention. As Figure 1 shown, the image acquisition method includes steps 110 to 140.

[0057] Step 110, determine the merged frame number of the target image.

[0058] Specifically, the target image can be the finally obtained processed image. The number of merged frames of the target image can be n, where n is any positive integer greater than or equal to 2. For example, the number of merged frames n can be 2, 3, 4, etc.

[0059] Exemplarily, when determining the number of merged frames of the target image, one of them can be selected based on a preset frame number range value. For example, if the preset frame number range values are 2, 3, 4, 5, then one of them can be selected as the number of merged frames. Determining the number of merged frames can also be based on the historical data of the number of merged frames. For example, if the number of merged frames determined last time is 3, then the number of merged frames this time can be determined as 3; or for another example, among the number of merged frames determined in the last K times, the number of times the number of merged frames is 3 is the most, then the number of merged frames this time can be determined as 3, where K can be any positive integer.

[0060] Exemplarily, when determining the number of merged frames of the target image, the number of merged frame values input by the user can be determined as the number of merged frames. For example, if the number of merged frame values input by the user is 2 frames, then the number of merged frames can be determined as 2. It should be understood that the larger the number of merged frames, the more image frames are merged, and the relatively longer the time required to obtain one frame of the target image or the higher the computing power of the device required.

[0061] Step 120: Determine the scanning start time offset based on the number of merged frames; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy cycle and the number of merged frames.

[0062] Specifically, after determining the number of merged frames of the target image, the scanning start time offset can be determined based on the number of merged frames. Among them, the scanning start time offset can be understood as the time difference between the scanning start times of two adjacent scanned images, and this time difference can be a parameter obtained based on the energy cycle and the number of merged frames. The energy cycle can be the cycle of the change in light energy in the environment corresponding to the scanned image.

[0063] Exemplarily, when determining the scanning start time offset based on the merged frame number, the energy period T can be first determined based on the period of the light energy change in the environment. For example, if the frequency of the alternating current is 60HZ, then 1 / 60 second is the period of an alternating current sine wave. In an alternating current sine wave, there are two energy periods in opposite directions, that is, there are two energy periods in an alternating current sine wave, so one energy period is half of the period of an alternating current sine wave, that is, one energy period is 1 / 120 second. Therefore, in the light energy environment of 60HZ alternating current, the energy period T is 1 / 120 second. Similarly, it can be known that if the frequency of the alternating current is 50HZ, then in the light energy environment of 50HZ alternating current, one energy period is 1 / 100 second. After determining the energy period and the merged frame number of the target image, the time difference can be obtained based on the energy period and the merged frame number, and this time difference can be used to represent the scanning start time offset.

[0064] Taking the camera monitoring scenario as an example again, if the screen refresh rate in the camera monitoring screen is 60HZ, then the image sensor included in the camera needs to support at least 60 frames per second (fps), and support adjusting the scanning start moment of each frame of image. For example, the scanning time of each frame can be 1 / 60 - 1 / 240 second. Since the screen refresh rate in the monitoring screen is 60HZ, the refresh duration of the screen once is 1 / 60 second, and its energy period is half of the refresh duration, that is, 1 / 120 second; 1 / 240 second is half of the energy period, which can be understood as 1 / 240 second is half of an energy period.

[0065] Figure 2 It is a schematic diagram of the energy period provided by an embodiment of the present invention. As Figure 2 shown, the horizontal axis represents the time axis, and the vertical axis represents the amplitude value. There are two energy periods within a duration of 1 / 60 second, and the duration of each energy period is 1 / 120 second. Figure 2 The area of the region shown as C in

[0066] Step 130, perform scanning based on the scanning start time offset to obtain a scanned image corresponding to the merged frame number.

[0067] Specifically, after determining the scanning start time offset, image scanning can be performed based on the determined scanning start time offset to obtain each scanned image with the same number as the merged frame number. When obtaining the scanned image by scanning, the scanning start moments between two adjacent scanned images differ by the duration of the scanning start time offset.

[0068] For example, if the number of merged frames of the target image is 3 and the determined scanning start time offset is 1 / 360 second, then the scanning start time of the second frame of the scanned image is delayed by 1 / 360 second based on the scanning start time of the first frame of the scanned image, and the scanning start time of the third frame of the scanned image is delayed by 1 / 360 second based on the scanning start time of the second frame of the scanned image. That is, assuming that the scanning start time of the first frame of the scanned image is the moment of the 0th second, then the first frame of the scanned image starts to be scanned at the moment of the 0th second, and is delayed by 1 / 360 second from the moment of the 0th second, that is, the second frame of the scanned image starts to be scanned at the moment of the 1 / 360th second; based on the scanning start time of the second frame of the scanned image at the 1 / 360th second, it is delayed by 1 / 360 second, that is, 1 / 360 second plus 1 / 360 second, then the scanning start time of the third frame of the scanned image is the moment of the 2 / 360th second, and the third frame of the scanned image can be obtained by scanning at the moment of the 2 / 360th second. Based on this, the scanned images corresponding to the number of merged frames can be obtained.

[0069] Step 140, merge the scanned images to obtain the target image.

[0070] Specifically, merging the scanned images to obtain the target image may be to perform image superposition on the obtained frames of the scanned images to obtain the superimposed image, and the superimposed image may be determined as the target image. When performing image superposition on the frames of the scanned images, it may be to perform superposition processing on the brightness values of the corresponding pixel points in each scanned image.

[0071] Exemplarily, when performing superposition processing, it may be to add the brightness values of the corresponding pixel points in each scanned image to obtain the brightness values of the pixel points in the target image. For example, when the number of merged frames is two, the brightness values of the corresponding pixel points in the first frame of the scanned image are respectively summed with the brightness values of the corresponding pixel points in the second frame of the scanned image, and the sum value is determined as the brightness value of the corresponding pixel point in the target image, then the two frames of the scanned images can be merged into one frame of the target image.

[0072] Exemplarily, when performing superposition on each scanned image, the position coordinates of each pixel point in each scanned image may be first determined, and the brightness value of each pixel point may be determined; in each scanned image, the pixel points corresponding to the same position coordinates may be determined as a group of target pixel points, and for each pixel point in the group of target pixel points, the average brightness value of each pixel point is calculated, and the average brightness value is determined as the target brightness value of the group of target pixel points; in the target image, the brightness value of the pixel point at the same position coordinate as the group of target pixel points is adjusted to the target brightness value, that is, the superposition of one pixel point in the target image is achieved, and the operation of adjusting the brightness value of all pixel points in the target image to the corresponding target brightness value is performed, then the merging of each scanned image and the obtaining of the target image can be achieved.

[0073] The image acquisition method provided by the embodiment of the present invention determines the number of merged frames of the target image; based on the number of merged frames, determines the scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; performs scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames; and merges the scanned images to obtain the target image. In this way, based on the scanning start time offset that represents the time difference between the scanning start times of two adjacent scanned images, scanned images corresponding to the number of merged frames can be scanned, and the target image obtained by merging the scanned images is an image with a constant energy, that is, the brightness of the target image is constant. When the brightness of each target image is the same, the light and dark stripes of the image are suppressed, so the purpose of improving the image quality while taking into account stripe suppression and preventing overexposure is achieved.

[0074] In practical applications, to make the energy of the obtained target image a constant value, the ratio of the energy period to the number of merged frames can be determined as the time difference.

[0075] In one embodiment, the time difference is the ratio of the energy period to the number of merged frames.

[0076] Specifically, if the energy period is represented by T and the number of merged frames is represented by n, the time difference can be expressed as T / n. This time difference is the time value of the scanning start time of two adjacent scanned images, that is, the scanning start time offset.

[0077] Exemplarily, after determining the energy period and the number of merged frames of the target image, the time difference can be obtained based on their ratio, that is, the scanning start time offset can be obtained. For example, if the energy period is 1 / 120 second and the number of merged frames of the target image is n, the time difference is 1 / 120 second divided by n, that is, 1 / 120n second, and the scanning start time offset can be determined as 1 / 120n second.

[0078] Taking the number of merged frames as 2 and the energy period as 1 / 120 second as an example, since the ratio of the energy period to the number of merged frames is 1 / 240 second, the scanning start time offset is determined as 1 / 240 second. When scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames, if the scanning start time of the first scanned image is the moment of the 0th second, then the second scanned image starts to be scanned at the moment of 1 / 240 second. Based on this, 2 scanned images corresponding to the number of merged frames can be obtained.

[0079] Taking the merged frame number as 3 and the energy period as 1 / 120 second as an example, since the ratio of the energy period to the merged frame number is 1 / 360 second, the scanning start time offset is determined to be 1 / 360 second. When scanning based on the scanning start time offset to obtain the scanning images corresponding to the merged frame number, if the scanning start moment of the first frame of scanning image is the moment at the 0th second, then the second frame of scanning image starts to be scanned at the moment of 1 / 360 second, and the third frame of scanning image starts to be scanned at the moment of 2 / 360 second. Based on this, 3 frames of scanning images corresponding to the merged frame number can be obtained.

[0080] Exemplarily, when collecting images, if the light energy is the light energy generated by alternating current, since the power of the alternating current changes in a sine-squared manner, when the scanning images obtained by scanning based on the scanning start time offset are merged to obtain the target image, the energy of the target image is a fixed value.

[0081] Taking the merged frame number of the target image as 2 frames and the energy period as 1 / 120 second as an example. The ratio of the energy period to the merged frame number is 1 / 240 second, that is, the scanning start time offset is 1 / 240 second. Since the power of the alternating current changes in a sine-squared manner, the energy change function of the first frame of scanning image in the two frames of scanning images can be expressed by formula (1), and the energy change function of the second frame of scanning image in the two frames of scanning images can be expressed by formula (2).

[0082] E t1 =U m Imsin 2 (120πt) (1)

[0083]

[0084] Among them, t represents the scanning start moment of the first frame of scanning image; E t1 represents the energy value of the first frame of scanning image; E t2 represents the energy value of the second frame of scanning image; U m represents the maximum value of the alternating current voltage; I m represents the maximum value of the alternating current current.

[0085] When the two frames of scanning images are merged, the energy change function of the obtained target image can be expressed by the following formula (3).

[0086] E t1 +E t2 =U m I m [sin 2 (120πt)+cos 2 (120πt)]=U m I m (3)

[0087] It can be seen that when the number of merged frames is two, the energy value of the obtained target image is a fixed value U m I m , then the brightness value of the target image is also a fixed value, that is, the target image is a high-quality image without stripes.

[0088] Figure 3 is the energy schematic diagram of the target image provided by the embodiment of the present invention. As Figure 3 shown, the horizontal axis represents the time value, and the vertical axis represents the amplitude value. There are two energy cycles within a time period of 1 / 60 second, and the duration of each energy cycle is 1 / 120 second. Figure 3 The total area of each rectangular box in

[0089] represents the energy value of the target image obtained by merging each scanned image, and the energy value of the target image is a fixed value. Taking the number of merged frames of the target image as 3 frames and the energy cycle as 1 / 120 second as an example. The ratio of the energy cycle to the number of merged frames is 1 / 360 second, that is, the scanning start time offset is 1 / 360 second. Since the power of alternating current changes in the form of the square of a sine wave, the energy change function of the second scanned image in the three scanned images can be expressed by formula (4), the energy change function of the first scanned image in the three scanned images can be expressed by formula (5), and the energy change function of the third scanned image in the three scanned images can be expressed by formula (6).

[0090] E t3 =U m I m sin 2 (120πt) (4)

[0091]

[0092]

[0093] Among them, t represents the scanning start time of the second scanned image; E t3 represents the energy value of the second scanned image; E t4 represents the energy value of the first scanned image; E t5 represents the energy value of the third scanned image.

[0094] When the three scanned images are merged, the energy change function of the obtained target image can be expressed by the following formula (7).

[0095]

[0096]

[0097] Among them, E t6Represents the energy value of the target image obtained by merging three-frame scanned images. It can be seen that the energy value of the target image obtained by merging three-frame scanned images is a fixed value. Then the brightness value of the target image is also a fixed value, that is, the target image is a high-quality image without stripes.

[0098] Similarly, from the above derivation process, if the number of merged frames of the target image is n and the energy period is T, then the scanning start time offset is T / n, which is 1 / n times the energy period, and the energy of the target image obtained by merging each scanned image is a fixed value.

[0099] In this embodiment, the time difference is the ratio of the energy period to the number of merged frames, and based on this time difference, the corresponding scanning start time offset can be obtained. By merging the scanned images obtained based on this scanning start time offset, a target image with a fixed energy value can be obtained. This target image is a stripe-free image, thus improving the image quality.

[0100] In practical applications, in order to meet the requirements for image acquisition in different application scenarios, when determining the number of merged frames of the target image, it can be determined based on the user's frame configuration instruction, which can improve the applicability of this method.

[0101] In one embodiment, when determining the number of merged frames of the target image, it can be specifically implemented in the following manner:

[0102] Receive the frame configuration instruction input by the user; in response to the frame configuration instruction, output a frame configuration interface, where the frame configuration interface includes a target selection control, and the target selection control includes a frame number selection control and / or a frame rate selection control; receive the frame number selection instruction triggered by the user based on the target selection control; in response to the frame number selection instruction, determine the number of merged frames.

[0103] Specifically, the frame configuration instruction can be used to start the program for determining the number of merged frames, and the frame configuration instruction can be in any form, such as a touch form instruction, or a text input form instruction, or a voice input form instruction, etc.

[0104] In response to a frame number configuration instruction input by a user, an electronic device can output a frame number configuration interface. For example, the frame number configuration interface is displayed on a display device of the electronic device. The frame number configuration interface may include a target selection control, which may be, for example, a text, an icon, or a control combining text and graphics. The target selection control may include a frame number selection control and / or a frame rate selection control. Among them, the frame number selection control may be a selection control including at least one frame number. For example, in the frame number configuration interface, frame number selection boxes corresponding to 2 frames, 3 frames, 4 frames, and 5 frames respectively may be displayed, and each selection box is a frame number selection control. The frame rate selection control may be a selection control including at least one frame rate. For example, in the frame number configuration interface, frame rate selection boxes corresponding to 2 frames per 1 / 120 second, 3 frames per 1 / 120 second, and 4 frames per 1 / 120 second respectively may be displayed, and each frame rate selection box is a frame rate selection control.

[0105] Exemplarily, upon receiving a frame number selection instruction triggered by a user based on the target selection control; in response to the frame number selection instruction, the merged frame number is determined. The frame number selection instruction is an instruction for confirming the triggering of the target selection control, and may be, for example, an operation instruction in the form of a single click, a double click, or character input. After the user inputs a frame number selection instruction for triggering the target selection control, the merged frame number is determined based on the selected frame number or frame rate. For example, when the user clicks on the "2 frames" frame number selection box in the frame number configuration interface with a finger, the frame number selection instruction is input, and in response to this frame number selection instruction, the merged frame number can be determined to be 2 frames.

[0106] In this embodiment, when determining the merged frame number of the target image, it may be to receive a frame number configuration instruction input by the user, and in response to the frame number configuration instruction, output a frame number configuration interface including a target selection control; receive a frame number selection instruction triggered by the user based on the target selection control, and in response to the frame number selection instruction, the merged frame number can be determined. Based on this, the merged frame number can be determined according to the user's needs to obtain the target image expected by the user, thereby enhancing the user's favorable impression, expanding the application scenario range of this method, and improving the applicability.

[0107] Next, a specific description will be given on how to perform scanning based on the scanning start time offset to obtain a scanning image corresponding to the merged frame number.

[0108] In one embodiment, performing scanning based on the scanning start time offset to obtain a scanning image corresponding to the merged frame number can be specifically implemented in the following manner:

[0109] Obtain the second scanning start time of the current frame scanned image, and scan the current frame scanned image based on the second scanning start time; determine the first scanning start time of the next frame scanned image based on the second scanning start time and the scanning start time offset; scan the next frame scanned image based on the first scanning start time until the scanned images corresponding to the merged number of frames are obtained.

[0110] Specifically, the second scanning start time is the scanning start time of the current frame scanned image. By performing image scanning based on the second scanning start time, the current frame scanned image can be obtained. For example, the moment at 0 seconds is the scanning start time of the current frame scanned image, that is, the second scanning start time. By performing image scanning at the moment of 0 seconds, the first frame scanned image, that is, the current frame scanned image, can be obtained.

[0111] Determining the first scanning start time of the next frame scanned image based on the second scanning start time and the scanning start time offset can be understood as delaying the scanning start time offset based on the second scanning start time to obtain the scanning start time for scanning the second frame scanned image, that is, the first scanning start time of the next frame scanned image. After determining the first scanning start time, performing image scanning at the first scanning start time can obtain the next frame scanned image. By analogy, if the merged number of frames is n, then delaying the scanning start time offset based on the second scanning start time of the (n - 1)th frame scanned image can obtain the scanning start time for scanning the nth frame scanned image, and performing image scanning at this moment can obtain the nth frame scanned image.

[0112] In this embodiment, it is possible to obtain the second scanning start time of the current frame scanned image, and scan the current frame scanned image based on the second scanning start time; determine the first scanning start time of the next frame scanned image based on the second scanning start time and the scanning start time offset; scan the next frame scanned image based on the first scanning start time until the scanned images corresponding to the merged number of frames are obtained. Based on this, scanned images with a scanning start time offset between adjacent two scanned images can be obtained, and by merging the scanned images, a target image without stripes with a fixed energy can be obtained, improving the image quality during image acquisition.

[0113] The embodiment of the present invention also provides an image acquisition method. Figure 4 It is the second flow diagram of the image acquisition method provided by the embodiment of the present invention. As Figure 4 shown, this image acquisition method includes step 400.

[0114] Step 400, perform at least one image acquisition process to obtain the target image output by at least one image acquisition process;

[0115] Among them, the image acquisition process includes: determining the number of merged frames of the target image; determining the scanning start time offset based on the number of merged frames; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0116] Specifically, the specific implementation and technical effects of the image acquisition process in this method are similar to those of the image acquisition method in the above embodiments. For details, reference can be made to the detailed descriptions in the respective embodiments of the above image acquisition method, which will not be elaborated here.

[0117] Exemplarily, this method can perform at least one image acquisition process, and each image acquisition process will obtain a corresponding target image. This method is applicable to image acquisition scenarios where target images are continuously obtained, such as image acquisition in a video surveillance scenario, or image acquisition in a video shooting scenario, etc.

[0118] The image acquisition method provided by the embodiments of the present invention can, during the image acquisition process, based on the scanning start time offset representing the time difference between the scanning start times of two adjacent scanned images, scan to obtain the scanned images corresponding to the number of merged frames. The target image obtained by merging the scanned images is a stripe-free image with a fixed energy value, and thus the image quality of the target image is relatively high. When performing at least one image acquisition process, at least one target image with relatively high image quality can be obtained, which can improve the quality of image acquisition.

[0119] Next, the image acquisition device provided by the embodiments of the present invention will be described. The image acquisition device described below can be correspondingly referred to the image acquisition method described above.

[0120] Figure 5 is one of the structural schematic diagrams of the image acquisition device provided by the embodiments of the present invention. As Figure 5 shown, the image acquisition device 500 includes:

[0121] A determination module 510, configured to determine the number of merged frames of the target image;

[0122] The determination module 510 is further configured to determine the scanning start time offset based on the number of merged frames; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames;

[0123] A scanning module 520, configured to perform scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames;

[0124] A merging module 530, configured to merge scanned images to obtain a target image.

[0125] In one exemplary embodiment, the time difference is the ratio of the energy cycle to the number of merged frames.

[0126] In one exemplary embodiment, the determining module 510 is specifically configured to:

[0127] Receive a frame number configuration instruction input by a user;

[0128] In response to the frame number configuration instruction, output a frame number configuration interface, where the frame number configuration interface includes a target selection control, and the target selection control includes a frame number selection control and / or a frame rate selection control;

[0129] Receive a frame number selection instruction triggered by the user based on the target selection control;

[0130] In response to the frame number selection instruction, determine the number of merged frames.

[0131] In one exemplary embodiment, the scanning module 520 is specifically configured to:

[0132] Obtain a second scanning start time of the current frame scanned image, and scan the current frame scanned image based on the second scanning start time;

[0133] Based on the second scanning start time and the scanning start time offset, determine a first scanning start time of the next frame scanned image;

[0134] Scan the next frame scanned image based on the first scanning start time until the scanned images corresponding to the number of merged frames are obtained.

[0135] The device in this embodiment can be used to execute the method in any of the method embodiments on the image acquisition method side. Its specific implementation process and technical effects are similar to those in the method embodiments on the image acquisition method side. For specific details, reference can be made to the detailed introduction in the method embodiments on the image acquisition method side, which will not be elaborated here.

[0136] An embodiment of the present invention further provides an image acquisition device. Figure 6 It is the second structural schematic diagram of the image acquisition device provided by the embodiment of the present invention. As Figure 6 shown, the image generation device 600 includes:

[0137] An acquisition module 610, configured to perform at least one image acquisition process and obtain a target image output by the at least one image acquisition process;

[0138] Among them, the image acquisition process includes: determining the number of merged frames of the target image; determining the scanning start time offset based on the number of merged frames, where the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images, and the time difference is obtained based on the energy cycle and the number of merged frames; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0139] The device in this embodiment can be used to execute the method in any one of the method embodiments of the image acquisition method. The specific implementation process and technical effects are similar to those in the method embodiments of the image acquisition method. For details, please refer to the detailed introduction in the method embodiments of the image acquisition method, which will not be elaborated here.

[0140] Figure 7 It is a schematic physical structure diagram of an electronic device provided by an embodiment of the present invention. As Figure 7 shown, the electronic device may include: a processor 710, a communication interface 720, a memory 730, and a communication bus 740. Among them, the processor 710, the communication interface 720, and the memory 730 communicate with each other through the communication bus 740. The processor 710 can call the logical instructions in the memory 730 to execute the above-mentioned image acquisition method, which includes: determining the number of merged frames of the target image; determining the scanning start time offset based on the number of merged frames, where the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images, and the time difference is obtained based on the energy cycle and the number of merged frames; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0141] Alternatively, the processor 710 can call the logical instructions in the memory 730 to execute the above-mentioned image acquisition method, which includes: performing at least one image acquisition process to obtain the target image output by the at least one image acquisition process. Among them, the image acquisition process includes: determining the number of merged frames of the target image; determining the scanning start time offset based on the number of merged frames, where the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images, and the time difference is obtained based on the energy cycle and the number of merged frames; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0142] In addition, when the logical instructions in the above-mentioned memory 730 are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs that can store program codes.

[0143] On the other hand, the present invention also provides a computer program product. The computer program product includes a computer program that can be stored on a computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the above-mentioned image acquisition method, and the method includes: determining the number of merged frames of the target image; based on the number of merged frames, determining the scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; performing scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0144] Alternatively, when the computer program is executed by a processor, the computer can execute the above-mentioned image acquisition method, and the method includes: performing at least one image acquisition process to obtain a target image output by the at least one image acquisition process; wherein, the image acquisition process includes: determining the number of merged frames of the target image; based on the number of merged frames, determining the scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; performing scanning based on the scanning start time offset to obtain scanned images corresponding to the number of merged frames; and merging the scanned images to obtain the target image.

[0145] In another aspect, the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements the image acquisition method provided by the above-mentioned various methods. The method includes: determining the number of frames to be merged for the target image; determining the scanning start time offset based on the number of frames to be merged. The scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images. The time difference is obtained based on the energy cycle and the number of frames to be merged; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of frames to be merged; and merging the scanned images to obtain the target image.

[0146] Alternatively, when the computer program is executed by a processor, the computer can execute the above-mentioned image acquisition method. The method includes: performing at least one image acquisition process to obtain the target image output by the at least one image acquisition process. Wherein, the image acquisition process includes: determining the number of frames to be merged for the target image; determining the scanning start time offset based on the number of frames to be merged. The scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images. The time difference is obtained based on the energy cycle and the number of frames to be merged; performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of frames to be merged; and merging the scanned images to obtain the target image.

[0147] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated. The components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art can understand and implement it without creative effort.

[0148] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, also by hardware. Based on such an understanding, the essence of the above technical solution, or the part that contributes to the prior art, can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disc, etc., and includes several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0149] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. An image acquisition method, characterized in that, including: Determine the number of merged frames of the target image; Based on the number of merged frames, determine the scanning start time offset; The scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; The time difference is obtained based on the energy period and the number of merged frames; Perform scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; Merge the scanned images to obtain the target image.

2. The image acquisition method according to claim 1, wherein The time difference is the ratio of the energy period to the number of merged frames.

3. The image acquisition method according to claim 1 or 2, characterized in that, The determining the number of merged frames of the target image includes: Receive a frame number configuration instruction input by the user; In response to the frame number configuration instruction, output a frame number configuration interface, where the frame number configuration interface includes a target selection control, and the target selection control includes a frame number selection control and / or a frame rate selection control; Receive a frame number selection instruction triggered by the user based on the target selection control; In response to the frame number selection instruction, determine the number of merged frames.

4. The image acquisition method according to claim 1 or 2, characterized in that The performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames includes: Obtain the second scanning start time of the current frame scanned image, and scan the current frame scanned image based on the second scanning start time; Based on the second scanning start time and the scanning start time offset, determine the first scanning start time of the next frame scanned image; Scan the next frame scanned image based on the first scanning start time until the scanned images corresponding to the number of merged frames are obtained.

5. An image acquisition method, characterized in that, including: Execute at least one image acquisition process to obtain the target image output by the at least one image acquisition process; Wherein, the image acquisition process includes: Determine the number of merged frames of the target image; Based on the number of merged frames, determine the scanning start time offset; the scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; Perform scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; Merge the scanned images to obtain the target image.

6. An image acquisition device, characterized in that, including: A determination module for determining the number of merged frames of the target image; The determination module is further configured to determine the scanning start time offset based on the number of merged frames; The scanning start time offset is used to represent the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the number of merged frames; A scanning module for performing scanning based on the scanning start time offset to obtain the scanned images corresponding to the number of merged frames; A merging module for merging the scanned images to obtain the target image.

7. An image acquisition device, characterized in that, including: An acquisition module for executing at least one image acquisition process to obtain the target image output by the at least one image acquisition process; Wherein, the image acquisition process includes: Determine the number of merged frames of the target image; Determine a scanning start time offset based on the merged frame number; the scanning start time offset is used to characterize the time difference between the scanning start times of two adjacent scanned images; the time difference is obtained based on the energy period and the merged frame number; Perform scanning based on the scanning start time offset to obtain a scanned image corresponding to the merged frame number; Merge the scanned images to obtain the target image.

8. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the image acquisition method according to any one of claims 1 to 4, or when the processor executes the computer program, it implements the image acquisition method according to claim 5.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the image acquisition method according to any one of claims 1 to 4, or when the computer program is executed by the processor, it implements the image acquisition method according to claim 5.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the image acquisition method according to any one of claims 1 to 4, or when the computer program is executed by the processor, it implements the image acquisition method according to claim 5.