CN114374798A - Scene recognition method and device, electronic equipment and computer-readable storage medium - Google Patents

Scene recognition method and device, electronic equipment and computer-readable storage medium Download PDF

Info

Publication number
CN114374798A
CN114374798A CN202210023587.2A CN202210023587A CN114374798A CN 114374798 A CN114374798 A CN 114374798A CN 202210023587 A CN202210023587 A CN 202210023587A CN 114374798 A CN114374798 A CN 114374798A
Authority
CN
China
Prior art keywords
pixels
scene
area
threshold value
sensitivity
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
CN202210023587.2A
Other languages
Chinese (zh)
Other versions
CN114374798B (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.)
TCL Communication Technology Chengdu Ltd
Original Assignee
TCL Communication Technology Chengdu 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 TCL Communication Technology Chengdu Ltd filed Critical TCL Communication Technology Chengdu Ltd
Priority to CN202210023587.2A priority Critical patent/CN114374798B/en
Publication of CN114374798A publication Critical patent/CN114374798A/en
Application granted granted Critical
Publication of CN114374798B publication Critical patent/CN114374798B/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/60Control of cameras or camera modules
    • H04N23/63Control of cameras or camera modules by using electronic viewfinders
    • H04N23/631Graphical user interfaces [GUI] specially adapted for controlling image capture or setting capture parameters
    • H04N23/632Graphical user interfaces [GUI] specially adapted for controlling image capture or setting capture parameters for displaying or modifying preview images prior to image capturing, e.g. variety of image resolutions or capturing parameters
    • 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/71Circuitry for evaluating the brightness variation

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Human Computer Interaction (AREA)
  • Studio Devices (AREA)

Abstract

The embodiment of the application discloses a scene recognition method, a scene recognition device, electronic equipment and a computer-readable storage medium; in the embodiment of the application, a preview image of a shooting scene is acquired, and the sensitivity of the preview image is acquired; performing brightness identification on the preview image to obtain a plurality of brightness areas of the preview image; and determining the recognition result of the shooting scene according to the plurality of bright areas and the sensitivity. The method and the device for recognizing the high-dynamic scene can improve the recognition accuracy rate of the high-dynamic scene.

Description

Scene recognition method and device, electronic equipment and computer-readable storage medium
Technical Field
The present application relates to the field of image processing technologies, and in particular, to a scene recognition method, an apparatus, an electronic device, and a computer-readable storage medium.
Background
In order to take a more real picture, a high dynamic range (hdr) algorithm is applied to a shooting scene, that is, during shooting, whether the shooting scene is a high dynamic scene is identified, and if the shooting scene is a high dynamic scene, a high dynamic range shooting mode is entered.
However, it is currently easier to identify some shot scenes that are not highly dynamic scenes as highly dynamic scenes, i.e., to identify pseudo-highly dynamic scenes as highly dynamic scenes, such as scenes shot of white paper on a black table. Therefore, the accuracy of the current identification method for high dynamic scenes is not high.
Disclosure of Invention
The embodiment of the application provides a scene identification method, a scene identification device, electronic equipment and a computer readable storage medium, and can solve the technical problem that the accuracy of the existing high-dynamic scene identification method is not high.
A method of scene recognition, comprising:
acquiring a preview image of a shooting scene and acquiring the sensitivity of the preview image;
performing brightness recognition on the preview image to obtain a plurality of brightness areas of the preview image;
and determining the recognition result of the shooting scene according to the plurality of bright areas and the sensitivity.
Optionally, the plurality of luminance areas include a very dark area, a middle luminance area, and a bright area of the preview image;
accordingly, the determining a recognition result of the shooting scene according to the plurality of luminance regions and the sensitivity includes:
and determining the recognition result of the shooting scene according to the sensitivity, the pixel of the very dark area, the pixel of the middle brightness area and the pixel of the bright area.
Optionally, the determining the recognition result of the shooting scene according to the sensitivity, the pixels in the very dark region, the pixels in the intermediate brightness region, and the pixels in the bright region includes:
if the sensitivity is equal to or greater than a first threshold value, identifying the shooting scene as a non-high dynamic scene;
and if the sensitivity is less than a first threshold value, determining the recognition result of the shooting scene according to at least one of the pixels of the very dark area, the pixels of the intermediate brightness area and the pixels of the bright area.
Alternatively, if the sensitivity is less than a first threshold, determining the recognition result of the shooting scene according to at least one of the pixels in the very dark region, the pixels in the intermediate luminance region, and the pixels in the bright region includes:
if the light sensitivity is less than a first threshold value, determining the number of pixels in the very dark area;
and if the number of the pixels in the dark area is equal to or larger than a second threshold value, identifying the shooting scene as a non-high dynamic scene.
Optionally, the intermediate brightness region includes a medium bright region and a medium dark region;
accordingly, after determining the number of pixels in the very dark region if the sensitivity is less than the first threshold, the method further includes:
if the number of the pixels in the dark area is smaller than a second threshold value, determining the number of the pixels in the dark area and the number of the pixels in the middle dark area;
and if the number of the pixels in the dark area is greater than a third threshold value and the number of the pixels in the middle dark area is less than a fourth threshold value, identifying the shooting scene as a high-dynamic scene.
Optionally, after determining the number of pixels in the dark region and the number of pixels in the medium dark region if the number of pixels in the very dark region is smaller than a second threshold, the method further includes:
if the number of the pixels in the dark area is smaller than or equal to a third threshold value and/or the number of the pixels in the medium dark area is equal to or larger than a fourth threshold value, determining the number of the pixels in the bright area and the number of the pixels in the medium bright area;
if the number of the pixels in the bright area is larger than a fifth threshold value and the number of the pixels in the medium bright area is smaller than a sixth threshold value, identifying the shooting scene as a high dynamic scene;
and if the number of the pixels of the bright area is less than or equal to a fifth threshold value and/or the number of the pixels of the medium bright area is equal to or greater than a sixth threshold value, identifying the shot scene as a non-high-dynamic scene.
Optionally, the recognizing the shooting scene as a non-high-dynamic scene if the number of pixels in the very dark area is equal to or greater than a second threshold includes:
and if the number of the pixels in the very dark area is equal to or larger than a first threshold value and the light sensitivity is smaller than a seventh threshold value, identifying the shooting scene as a single-frame shooting scene.
Accordingly, an embodiment of the present application provides a scene recognition apparatus, including:
the system comprises an acquisition module, a processing module and a display module, wherein the acquisition module is used for acquiring a preview image of a shooting scene and acquiring the light sensitivity of the preview image;
the identification module is used for carrying out brightness identification on the preview image to obtain a plurality of brightness areas of the preview image;
and the determining module is used for determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
In addition, an electronic device is further provided in an embodiment of the present application, and includes a processor and a memory, where the memory stores a computer program, and the processor is configured to run the computer program in the memory to implement the scene recognition method provided in the embodiment of the present application.
In addition, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored, and the computer program is suitable for being loaded by a processor to execute any one of the scene recognition methods provided in the embodiment of the present application.
In addition, a computer program product including a computer program is provided, where the computer program is executed by a processor to implement any of the scene recognition methods provided in the embodiments of the present application.
In the embodiment of the application, a preview image of a shooting scene is acquired, and the sensitivity of the preview image is acquired. And then, performing brightness recognition on the preview image to obtain a plurality of brightness areas of the preview image. And finally, determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
That is, in this embodiment, since the recognition result of the shooting scene can be determined simultaneously according to the plurality of luminance regions and the sensitivity of the preview image, the obtained recognition result of the shooting scene is more accurate, so that it is possible to avoid recognizing a pseudo high dynamic scene as a high dynamic scene.
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 are 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 based on these drawings without creative efforts.
Fig. 1 is a schematic flowchart of a scene recognition method according to an embodiment of the present application;
FIG. 2 is a diagram of a plurality of luminance regions provided by an embodiment of the present application;
fig. 3 is a schematic diagram of another scene recognition method provided in an embodiment of the present application;
fig. 4 is a schematic structural diagram of a scene recognition apparatus provided in an embodiment of the present application;
fig. 5 is a schematic structural diagram of an electronic device provided in an embodiment of 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 obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The embodiment of the application provides a scene recognition method, a scene recognition device, electronic equipment and a computer-readable storage medium. The scene recognition device may be integrated in an electronic device, and the electronic device may be a server or a terminal.
The server may be an independent physical server, a server cluster or a distributed system formed by a plurality of physical servers, or a cloud server providing basic cloud computing services such as cloud service, a cloud database, cloud computing, a cloud function, cloud storage, Network service, cloud communication, middleware service, domain name service, security service, Network acceleration service (CDN), big data and an artificial intelligence platform.
The terminal may be, but is not limited to, a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, and the like. The terminal and the server may be directly or indirectly connected through wired or wireless communication, and the application is not limited herein.
In addition, "a plurality" in the embodiments of the present application means two or more. "first" and "second" and the like in the embodiments of the present application are used for distinguishing the description, and are not to be construed as implying relative importance.
The following are detailed below. It should be noted that the following description of the embodiments is not intended to limit the preferred order of the embodiments.
In the present embodiment, a scene recognition device that can be specifically integrated in a device such as a server or a terminal will be described from the perspective of the scene recognition device, and for convenience of describing the scene recognition method of the present application, the following will describe in detail the scene recognition device integrated in the terminal, that is, the terminal as an execution subject.
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating a scene recognition method according to an embodiment of the present application. The scene recognition method may include:
s101, acquiring a preview image of a shooting scene, and acquiring the sensitivity of the preview image.
When a user wants to shoot a shooting scene, the user can start the camera on the terminal, and then the terminal receives a starting instruction. And then the terminal opens the camera based on the starting instruction, and finally the preview image of the shooting scene is obtained through the camera.
The photographing scene refers to an object that the user is about to photograph. The preview image refers to an image displayed on a display interface through the camera after the camera is started.
And after the terminal acquires the preview image, determining the sensitivity of the preview image. The sensitivity of the preview image refers to the sensitivity of the camera when the preview image is acquired by the camera, that is, the sensitivity at which the terminal can read the preview image from its own setting.
S102, brightness recognition is carried out on the preview image, and a plurality of brightness areas of the preview image are obtained.
After the terminal obtains the preview image, the terminal can perform brightness identification on the preview image to obtain the brightness of each pixel in the preview image, and then count each pixel according to the brightness of each pixel to obtain a plurality of brightness areas of the preview image.
For example, as shown in fig. 2, the plurality of luminance regions include a very dark region, a middle luminance region, and a bright region of the preview image, s1 indicates the number of pixels of the very dark region, s2 indicates the number of pixels of the dark region, and s3 indicates the number of pixels of the bright region.
And S103, determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
And after the terminal obtains the plurality of bright areas and the light sensitivity, determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
In some embodiments, the plurality of luminance regions includes a very dark region, a middle luminance region, and a bright region of the preview image. Correspondingly, according to the plurality of brightness areas and the sensitivity, the identification result of the shooting scene is determined, and the method comprises the following steps:
and determining the recognition result of the shooting scene according to the sensitivity, the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
The recognition result of the shooting scene can be determined according to the sensitivity, the brightness of the pixel in the dark area, the brightness of the pixel in the middle brightness area and the brightness of the pixel in the bright area.
Alternatively, the recognition result of the shooting scene may be determined based on the sensitivity, the number of pixels in the very dark region, the number of pixels in the intermediate luminance region, and the number of pixels in the bright region.
In some possible implementation manners, referring to fig. 3, determining the recognition result of the shooting scene according to the sensitivity, the pixel of the very dark region, the pixel of the intermediate brightness region and the pixel of the bright region includes:
if the light sensitivity is equal to or greater than a first threshold value, identifying the shooting scene as a non-high dynamic scene;
and if the sensitivity is less than the first threshold, determining the recognition result of the shooting scene according to at least one of the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
When the sensitivity is equal to or greater than the first threshold, the non-high-dynamic scene may be a Multi-Frame Noise Reduction (MFNR) shooting scene.
If the sensitivity is less than the first threshold, determining the recognition result of the shooting scene according to at least one of the pixels in the very dark region, the pixels in the intermediate brightness region and the pixels in the bright region, including:
if the light sensitivity is less than a first threshold value, determining the number of pixels in a very dark area;
and if the number of the pixels in the dark area is equal to or larger than a second threshold value, identifying the shooting scene as a non-high dynamic scene.
In other embodiments, if the number of pixels in the very dark region is equal to or greater than the second threshold, identifying the captured scene as a non-high-dynamic scene includes:
and if the number of the pixels in the dark area is equal to or larger than the first threshold and the light sensitivity is smaller than the seventh threshold, identifying the shooting scene as a single-frame shooting scene.
And if the number of the pixels in the dark area is equal to or greater than the first threshold and the light sensitivity is equal to or greater than the seventh threshold, identifying the shooting scene as a multi-frame shooting scene.
In other embodiments, the intermediate-luminance regions include a medium-luminance region and a medium-dark region. Correspondingly, after determining the number of pixels in the very dark region if the sensitivity is less than the first threshold, the method further includes:
if the number of the pixels in the dark area is smaller than a second threshold value, determining the number of the pixels in the dark area and the number of the pixels in the medium dark area;
and if the number of the pixels in the dark area is greater than the third threshold value and the number of the pixels in the middle dark area is less than the fourth threshold value, identifying the shooting scene as a high dynamic scene.
The medium bright region refers to a region from the minimum brightness in the bright region to the middle brightness of the preview image, and the medium dark region refers to a region from the maximum brightness in the dark region to the middle brightness of the preview image. Such as shown in fig. 2.
In this embodiment, when the number of pixels in a very dark region is smaller than the second threshold, only if the number of pixels in the dark region is greater than the third threshold and the number of pixels in a medium dark region is smaller than the fourth threshold, the shooting scene is identified as a high dynamic scene, so that the accuracy of shooting scene identification can be further improved, and further, the identification of a pseudo high dynamic scene as a high dynamic scene is avoided.
In other embodiments, after determining the number of pixels in the dark area and the number of pixels in the medium dark area if the number of pixels in the very dark area is less than the second threshold, the method further includes:
if the number of the pixels in the dark area is smaller than or equal to a third threshold value and/or the number of the pixels in the medium dark area is equal to or larger than a fourth threshold value, determining the number of the pixels in the bright area and the number of the pixels in the medium bright area;
if the number of the pixels in the bright area is larger than a fifth threshold value and the number of the pixels in the medium bright area is smaller than a sixth threshold value, identifying the shooting scene as a high dynamic scene;
and if the number of the pixels of the bright area is less than or equal to a fifth threshold value and/or the number of the pixels of the medium-bright area is equal to or greater than a sixth threshold value, identifying the shot scene as a non-high-dynamic scene.
In this embodiment, when the number of pixels in the dark region is less than or equal to the third threshold and/or the number of pixels in the medium-dark region is equal to or greater than the fourth threshold, the shot scene is identified as the high dynamic scene only if the number of pixels in the bright region is greater than the fifth threshold and the number of pixels in the medium-bright region is less than the sixth threshold, so that the accuracy of shot scene identification can be further improved, and the pseudo high dynamic scene is further prevented from being identified as the high dynamic scene.
And when the number of the pixels of the bright area is less than or equal to a fifth threshold value and/or the number of the pixels of the bright area is equal to or greater than a sixth threshold value, identifying the shooting scene as a single-frame shooting scene if the sensitivity is less than a seventh threshold value, and identifying the shooting scene as a multi-frame noise reduction shooting scene if the sensitivity is equal to or greater than the seventh threshold value.
As can be seen from the above, in the embodiment of the present application, a preview image of a captured scene is acquired, and the sensitivity of the preview image is acquired. And then, performing brightness recognition on the preview image to obtain a plurality of brightness areas of the preview image. And finally, determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
That is, in this embodiment, since the recognition result of the shooting scene can be determined simultaneously according to the plurality of luminance regions and the sensitivity of the preview image, the obtained recognition result of the shooting scene is more accurate, so that it is possible to avoid recognizing a pseudo high dynamic scene as a high dynamic scene.
In order to better implement the scene recognition method provided by the embodiment of the present application, the embodiment of the present application further provides a device based on the scene recognition method. The meaning of the noun is the same as that in the above-mentioned scene recognition method, and specific implementation details can refer to the description in the method embodiment.
For example, as shown in fig. 4, the scene recognition apparatus may include:
the acquiring module 401 is configured to acquire a preview image of a shooting scene and acquire sensitivity of the preview image.
The identifying module 402 is configured to perform brightness identification on the preview image to obtain a plurality of brightness regions of the preview image.
A determining module 403, configured to determine a recognition result of the shooting scene according to the plurality of bright regions and the sensitivity.
Optionally, the plurality of luminance areas includes a very dark area, a middle luminance area, and a bright area of the preview image.
Accordingly, the determining module 403 is specifically configured to perform:
and determining the recognition result of the shooting scene according to the sensitivity, the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
Optionally, the determining module 403 is specifically configured to perform:
if the light sensitivity is equal to or greater than a first threshold value, identifying the shooting scene as a non-high dynamic scene;
and if the sensitivity is less than the first threshold, determining the recognition result of the shooting scene according to at least one of the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
Optionally, the determining module 403 is specifically configured to perform:
if the light sensitivity is less than a first threshold value, determining the number of pixels in a very dark area;
and if the number of the pixels in the dark area is equal to or larger than a second threshold value, identifying the shooting scene as a non-high dynamic scene.
Optionally, the intermediate luminance region includes a medium bright region and a medium dark region.
Accordingly, the determining module 403 is specifically configured to perform:
if the number of the pixels in the dark area is smaller than a second threshold value, determining the number of the pixels in the dark area and the number of the pixels in the medium dark area;
and if the number of the pixels in the dark area is greater than the third threshold value and the number of the pixels in the middle dark area is less than the fourth threshold value, identifying the shooting scene as a high dynamic scene.
Optionally, the determining module 403 is specifically configured to perform:
if the number of the pixels in the dark area is smaller than or equal to a third threshold value and/or the number of the pixels in the medium dark area is equal to or larger than a fourth threshold value, determining the number of the pixels in the bright area and the number of the pixels in the medium bright area;
if the number of the pixels in the bright area is larger than a fifth threshold value and the number of the pixels in the medium bright area is smaller than a sixth threshold value, identifying the shooting scene as a high dynamic scene;
and if the number of the pixels of the bright area is less than or equal to a fifth threshold value and/or the number of the pixels of the medium-bright area is equal to or greater than a sixth threshold value, identifying the shot scene as a non-high-dynamic scene.
Optionally, the determining module 403 is specifically configured to perform:
and if the number of the pixels in the dark area is equal to or larger than the first threshold and the light sensitivity is smaller than the seventh threshold, identifying the shooting scene as a single-frame shooting scene.
In specific implementation, the above modules may be implemented as independent entities, or may be combined arbitrarily to be implemented as the same or several entities, and specific implementation manners and corresponding beneficial effects of the above modules may refer to the foregoing method embodiments, which are not described herein again.
An embodiment of the present application further provides an electronic device, where the electronic device may be a server or a terminal, and as shown in fig. 5, a schematic structural diagram of the electronic device according to the embodiment of the present application is shown, specifically:
the electronic device may include components such as a processor 501 of one or more processing cores, memory 502 of one or more computer-readable storage media, a power supply 503, and an input unit 504. Those skilled in the art will appreciate that the electronic device configuration shown in fig. 5 does not constitute a limitation of the electronic device and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components. Wherein:
the processor 501 is a control center of the electronic device, connects various parts of the whole electronic device by using various interfaces and lines, and performs various functions of the electronic device and processes data by operating or executing computer programs and/or modules stored in the memory 502 and calling data stored in the memory 502, thereby performing overall monitoring of the electronic device. Optionally, processor 501 may include one or more processing cores; preferably, the processor 501 may integrate an application processor, which mainly handles operating systems, user interfaces, application programs, etc., and a modem processor, which mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 501.
The memory 502 may be used to store computer programs and modules, and the processor 501 executes various functional applications and data processing by operating the computer programs and modules stored in the memory 502. The memory 502 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, a computer program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data created according to use of the electronic device, and the like. Further, the memory 502 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 502 may also include a memory controller to provide the processor 501 with access to the memory 502.
The electronic device further comprises a power supply 503 for supplying power to each component, and preferably, the power supply 503 may be logically connected to the processor 501 through a power management system, so that functions of managing charging, discharging, power consumption, and the like are realized through the power management system. The power supply 503 may also include any component of one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
The electronic device may also include an input unit 504, where the input unit 504 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.
Although not shown, the electronic device may further include a display unit and the like, which are not described in detail herein. Specifically, in this embodiment, the processor 501 in the electronic device loads the executable file corresponding to the process of one or more computer programs into the memory 502 according to the following instructions, and the processor 501 runs the computer program stored in the memory 502, so as to implement various functions, such as:
acquiring a preview image of a shooting scene, and acquiring the sensitivity of the preview image;
performing brightness identification on the preview image to obtain a plurality of brightness areas of the preview image;
and determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
The above detailed embodiments of the operations and the corresponding beneficial effects can be referred to the above detailed description of the scene recognition method, which is not repeated herein.
It will be understood by those skilled in the art that all or part of the steps of the methods of the above embodiments may be performed by a computer program, which may be stored in a computer-readable storage medium and loaded and executed by a processor, or by related hardware controlled by the computer program.
To this end, the present application provides a computer-readable storage medium, in which a computer program is stored, where the computer program can be loaded by a processor to execute the steps in any of the scene recognition methods provided in the embodiments of the present application. For example, the computer program may perform the steps of:
acquiring a preview image of a shooting scene, and acquiring the sensitivity of the preview image;
performing brightness identification on the preview image to obtain a plurality of brightness areas of the preview image;
and determining the recognition result of the shooting scene according to the plurality of bright areas and the light sensitivity.
The specific implementation of the above operations and the corresponding beneficial effects can be referred to the foregoing embodiments, and are not described herein again.
Wherein the computer-readable storage medium may include: read Only Memory (ROM), Random Access Memory (RAM), magnetic or optical disks, and the like.
Since the computer program stored in the computer-readable storage medium can execute the steps in any of the scene identification methods provided in the embodiments of the present application, beneficial effects that can be achieved by any of the scene identification methods provided in the embodiments of the present application can be achieved, which are detailed in the foregoing embodiments and will not be described herein again.
According to an aspect of the application, there is provided, among other things, a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the scene recognition method.
The above detailed description is given to a scene recognition method, a scene recognition device, an electronic device, and a computer-readable storage medium, which are provided by the embodiments of the present application, and a specific example is applied in the detailed description to explain the principles and embodiments of the present application, and the description of the above embodiments is only used to help understanding the method and the core ideas of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. A method for scene recognition, comprising:
acquiring a preview image of a shooting scene, and acquiring the sensitivity of the preview image;
performing brightness identification on the preview image to obtain a plurality of brightness areas of the preview image;
and determining the recognition result of the shooting scene according to the plurality of bright areas and the sensitivity.
2. The scene recognition method according to claim 1, wherein the plurality of luminance areas include a very dark area, a dark area, an intermediate luminance area, and a bright area of the preview image;
correspondingly, the determining the recognition result of the shooting scene according to the plurality of brightness regions and the sensitivity comprises:
and determining the recognition result of the shooting scene according to the sensitivity, the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
3. The scene recognition method according to claim 2, wherein determining the recognition result of the shooting scene according to the sensitivity, the pixels of the very dark region, the pixels of the intermediate luminance region, and the pixels of the bright region includes:
if the sensitivity is equal to or greater than a first threshold value, identifying the shooting scene as a non-high dynamic scene;
and if the sensitivity is less than a first threshold value, determining the recognition result of the shooting scene according to at least one of the pixels of the very dark area, the pixels of the middle brightness area and the pixels of the bright area.
4. The method according to claim 3, wherein determining the recognition result of the captured scene according to at least one of the pixels of the very dark region, the intermediate luminance region, and the bright region if the sensitivity is less than a first threshold value comprises:
if the sensitivity is less than a first threshold value, determining the number of pixels in the very dark area;
and if the number of the pixels in the dark area is equal to or larger than a second threshold value, identifying the shooting scene as a non-high dynamic scene.
5. The scene recognition method according to claim 4, wherein the intermediate luminance area includes a medium-bright area and a medium-dark area;
correspondingly, after determining the number of pixels in the very dark region if the sensitivity is less than the first threshold, the method further includes:
if the number of the pixels in the dark area is smaller than a second threshold value, determining the number of the pixels in the dark area and the number of the pixels in the middle dark area;
and if the number of the pixels in the dark area is greater than a third threshold value and the number of the pixels in the middle dark area is less than a fourth threshold value, identifying the shooting scene as a high dynamic scene.
6. The scene recognition method according to claim 5, wherein after determining the number of pixels in the dark region and the number of pixels in the medium-dark region if the number of pixels in the very dark region is smaller than a second threshold, the method further comprises:
if the number of the pixels in the dark area is smaller than or equal to a third threshold value and/or the number of the pixels in the medium dark area is equal to or larger than a fourth threshold value, determining the number of the pixels in the bright area and the number of the pixels in the medium bright area;
if the number of the pixels in the bright area is larger than a fifth threshold value and the number of the pixels in the medium bright area is smaller than a sixth threshold value, identifying the shooting scene as a high dynamic scene;
and if the number of the pixels of the bright area is less than or equal to a fifth threshold value and/or the number of the pixels of the medium bright area is equal to or greater than a sixth threshold value, identifying the shooting scene as a non-high dynamic scene.
7. The scene recognition method according to claim 4, wherein the recognizing the captured scene as a non-high-dynamic scene if the number of pixels of the very dark region is equal to or greater than a second threshold value comprises:
and if the number of the pixels in the dark area is equal to or larger than a first threshold value and the light sensitivity is smaller than a seventh threshold value, identifying the shooting scene as a single-frame shooting scene.
8. A scene recognition apparatus, comprising:
the system comprises an acquisition module, a processing module and a display module, wherein the acquisition module is used for acquiring a preview image of a shooting scene and acquiring the sensitivity of the preview image;
the identification module is used for carrying out brightness identification on the preview image to obtain a plurality of brightness areas of the preview image;
and the determining module is used for determining the recognition result of the shooting scene according to the plurality of bright areas and the sensitivity.
9. An electronic device, comprising a processor and a memory, wherein the memory stores a computer program, and the processor is configured to execute the computer program in the memory to perform the scene recognition method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that it stores a computer program adapted to be loaded by a processor for performing the scene recognition method of any one of claims 1 to 7.
CN202210023587.2A 2022-01-10 2022-01-10 Scene recognition method, device, electronic equipment and computer readable storage medium Active CN114374798B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210023587.2A CN114374798B (en) 2022-01-10 2022-01-10 Scene recognition method, device, electronic equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210023587.2A CN114374798B (en) 2022-01-10 2022-01-10 Scene recognition method, device, electronic equipment and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN114374798A true CN114374798A (en) 2022-04-19
CN114374798B CN114374798B (en) 2024-07-02

Family

ID=81144131

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210023587.2A Active CN114374798B (en) 2022-01-10 2022-01-10 Scene recognition method, device, electronic equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN114374798B (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004222134A (en) * 2003-01-17 2004-08-05 Fuji Photo Film Co Ltd Image pickup device
US20050099508A1 (en) * 2002-09-30 2005-05-12 Kazuya Oda Dynamic range broadening method for a solid-state image sensor including photosensitive cells each having a main and a subregion
JP2007251694A (en) * 2006-03-16 2007-09-27 Olympus Imaging Corp Camera, pixel adding area determining method of camera, program, and recording medium
CN102111560A (en) * 2009-12-26 2011-06-29 比亚迪股份有限公司 Automatic exposure device and method thereof
CN102917180A (en) * 2011-08-05 2013-02-06 佳能企业股份有限公司 Image picking-up method and image picking-up device
CN103973988A (en) * 2013-01-24 2014-08-06 华为终端有限公司 Scene recognition method and device
CN109005364A (en) * 2018-08-13 2018-12-14 Oppo广东移动通信有限公司 Image formation control method, device, electronic equipment and computer readable storage medium
CN110868533A (en) * 2019-10-15 2020-03-06 宇龙计算机通信科技(深圳)有限公司 HDR mode determination method, device, storage medium and terminal
CN112532857A (en) * 2019-09-18 2021-03-19 华为技术有限公司 Shooting method and equipment for delayed photography
CN113132644A (en) * 2019-12-31 2021-07-16 深圳市海思半导体有限公司 Method and equipment for generating high dynamic range image

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050099508A1 (en) * 2002-09-30 2005-05-12 Kazuya Oda Dynamic range broadening method for a solid-state image sensor including photosensitive cells each having a main and a subregion
JP2004222134A (en) * 2003-01-17 2004-08-05 Fuji Photo Film Co Ltd Image pickup device
JP2007251694A (en) * 2006-03-16 2007-09-27 Olympus Imaging Corp Camera, pixel adding area determining method of camera, program, and recording medium
CN102111560A (en) * 2009-12-26 2011-06-29 比亚迪股份有限公司 Automatic exposure device and method thereof
CN102917180A (en) * 2011-08-05 2013-02-06 佳能企业股份有限公司 Image picking-up method and image picking-up device
CN103973988A (en) * 2013-01-24 2014-08-06 华为终端有限公司 Scene recognition method and device
CN109005364A (en) * 2018-08-13 2018-12-14 Oppo广东移动通信有限公司 Image formation control method, device, electronic equipment and computer readable storage medium
CN112532857A (en) * 2019-09-18 2021-03-19 华为技术有限公司 Shooting method and equipment for delayed photography
CN110868533A (en) * 2019-10-15 2020-03-06 宇龙计算机通信科技(深圳)有限公司 HDR mode determination method, device, storage medium and terminal
CN113132644A (en) * 2019-12-31 2021-07-16 深圳市海思半导体有限公司 Method and equipment for generating high dynamic range image

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
俞文静;张明军;: "视频监控图像目标运动轨迹智能增强方法仿真", 计算机仿真, no. 12 *
贺理;陈果;郭宏;金伟其;: "一种基于双通道CMOS相机的低照度动态场景HDR融合方法", 红外技术, no. 04 *

Also Published As

Publication number Publication date
CN114374798B (en) 2024-07-02

Similar Documents

Publication Publication Date Title
CN109951627B (en) Image processing method, image processing device, storage medium and electronic equipment
CN111835982B (en) Image acquisition method, image acquisition device, electronic device, and storage medium
CN109040523B (en) Artifact eliminating method and device, storage medium and terminal
CN107690804B (en) Image processing method and user terminal
CN112732553B (en) Image testing method and device, electronic equipment and storage medium
CN105391940A (en) Image recommendation method and apparatus
CN113808066A (en) Image selection method and device, storage medium and electronic equipment
CN114187172A (en) Image fusion method and device, computer equipment and computer readable storage medium
CN113989387A (en) Camera shooting parameter adjusting method and device and electronic equipment
CN107180417B (en) Photo processing method and device, computer readable storage medium and electronic equipment
CN113132639A (en) Image processing method and device, electronic equipment and storage medium
CN113395599A (en) Video processing method and device, electronic equipment and medium
CN105163040B (en) A kind of image processing method and mobile terminal
CN114143429B (en) Image shooting method, device, electronic equipment and computer readable storage medium
CN114764821B (en) Moving object detection method, moving object detection device, electronic equipment and storage medium
CN114374798B (en) Scene recognition method, device, electronic equipment and computer readable storage medium
CN111263079B (en) Image processing method, image processing device, storage medium and electronic equipment
CN109672829A (en) Method of adjustment, device, storage medium and the terminal of brightness of image
CN113422893B (en) Image acquisition method and device, storage medium and mobile terminal
CN113938597B (en) Face recognition method, device, computer equipment and storage medium
CN114745537A (en) Sound and picture delay testing method and device, electronic equipment and storage medium
CN112104812A (en) Method and device for acquiring picture
CN113749614B (en) Skin detection method and apparatus
CN112843692B (en) Method and device for shooting image, electronic equipment and storage medium
CN117409220A (en) Skin color change detection method, device, electronic equipment and computer storage medium

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