WO2022252877A1 - Image processing chip, and abnormality processing method applied to image processing chip - Google Patents

Image processing chip, and abnormality processing method applied to image processing chip Download PDF

Info

Publication number
WO2022252877A1
WO2022252877A1 PCT/CN2022/089014 CN2022089014W WO2022252877A1 WO 2022252877 A1 WO2022252877 A1 WO 2022252877A1 CN 2022089014 W CN2022089014 W CN 2022089014W WO 2022252877 A1 WO2022252877 A1 WO 2022252877A1
Authority
WO
WIPO (PCT)
Prior art keywords
exception
abnormal
abnormality
image
processing chip
Prior art date
Application number
PCT/CN2022/089014
Other languages
French (fr)
Chinese (zh)
Inventor
朱文波
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2022252877A1 publication Critical patent/WO2022252877A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N17/00Diagnosis, testing or measuring for television systems or their details

Definitions

  • the image processing chip includes a plurality of functional modules, and the abnormality information is obtained by self-testing of each functional module.
  • the embodiment of the third aspect of the present disclosure proposes an electronic device, including a memory, a processor, and an exception handling program that is stored in the memory and can be run on the processor and applied to the image processing chip.
  • the processor executes When applied to the exception handling program of the image processing chip, the aforementioned exception handling method applied to the image processing chip is implemented.
  • FIG. 4 is a schematic structural diagram of an image anomaly detection and processing module of an image processing chip according to an embodiment of the disclosure
  • the processing of the exception is mainly to directly return an error number to the hardware abstraction layer of the camera, so that the hardware abstraction layer of the camera handles the exception.
  • the image processing chip finds an abnormality, it will mark the corresponding functional module that has the abnormality, and directly shut down the functional module that has the abnormality.
  • the image processing chip directly shuts down and throws an exception, so that the hardware abstraction layer of the camera handles the exception.
  • the image processing chip cannot detect the image abnormality, and directly outputs the abnormal image, so that the user can see the abnormality. Therefore, whether the image processing chip feeds back the abnormal type to the calling function or directly crashes, it will make the upper hardware abstraction layer visible, thus affecting the use of the upper hardware abstraction layer and the user experience effect.
  • the electronic device includes an image collector, which is used to collect image data for preview or shooting.
  • the image collector sends the collected image data to the image processing chip.
  • the image processing chip is used to process the received image data and output it to the upper hardware abstraction layer after processing.
  • the image processing chip can use its own abnormal detection mechanism to detect the abnormality and obtain abnormal information.
  • the simulated current frame image can be sent to the hardware abstraction layer as the output frame image, so that the hardware abstraction layer controls the display to display the simulated current frame image, thereby avoiding the output image freeze, so that The user is not aware of the abnormality of the underlying image processing chip, which improves the user experience.
  • various parts of the present disclosure may be implemented in hardware, software, firmware or a combination thereof.
  • various steps or methods may be implemented by software or firmware stored in memory and executed by a suitable instruction execution system.
  • a suitable instruction execution system For example, if implemented in hardware, as in another embodiment, it can be implemented by any one or combination of the following techniques known in the art: Discrete logic circuits, ASICs with suitable combinational logic gates, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)
  • Image Processing (AREA)

Abstract

An image processing chip, and an abnormality processing method applied to an image processing chip. The method comprises: acquiring abnormality information in an image output process, and determining an abnormality type according to the abnormality information (S101); and before reporting the abnormality information, according to the abnormality type, controlling an abnormality function module in an image processing chip to retry and/or controlling the abnormality function module to switch to a bypass mode, so as to perform abnormality self-recovery processing on the image processing chip (S103).

Description

图像处理芯片及应用于图像处理芯片的异常处理方法Image processing chip and exception handling method applied to image processing chip
相关申请的交叉引用Cross References to Related Applications
本公开要求于2021年06月01日提交的申请号为202110610683.2,名称为“图像处理芯片及应用于图像处理芯片的异常处理方法”的中国专利申请的优先权,其全部内容通过引用结合在本公开中。This disclosure claims the priority of the Chinese patent application with the application number 202110610683.2 filed on June 1, 2021, entitled "Image Processing Chip and Abnormal Handling Method Applied to Image Processing Chip", the entire contents of which are incorporated herein by reference. In public.
技术领域technical field
本公开涉及异常处理技术领域,尤其涉及一种图像处理芯片及应用于图像处理芯片的异常处理方法。The present disclosure relates to the technical field of exception processing, and in particular to an image processing chip and an exception processing method applied to the image processing chip.
背景技术Background technique
目前,底层的图像处理芯片在对图像数据进行处理过程中出现异常时,将出现异常的信息直接上传至上层的硬件抽象层,进而会使得用户直接感受到底层出现的异常情况,影响用户的体验效果。At present, when the underlying image processing chip is abnormal in the process of processing image data, the abnormal information will be directly uploaded to the upper hardware abstraction layer, which will make the user directly feel the abnormal situation in the underlying layer and affect the user experience. Effect.
公开内容public content
本公开旨在至少在一定程度上解决相关技术中的技术问题之一。为此,本公开的第一个目的在于提出一种应用于图像处理芯片的异常处理方法。The present disclosure aims to solve one of the technical problems in the related art at least to a certain extent. Therefore, the first purpose of the present disclosure is to propose an exception handling method applied to an image processing chip.
本公开的第二个目的在于提出一种图像处理芯片。The second objective of the present disclosure is to provide an image processing chip.
本公开的第三个目的在于提出一种电子设备。The third object of the present disclosure is to provide an electronic device.
本公开的第四个目的在于提出一种计算机可读存储介质。A fourth object of the present disclosure is to provide a computer-readable storage medium.
为达到上述目的,本公开第一方面实施例提出了一种应用于图像处理芯片的异常处理方法,包括:获取图像输出过程中的异常信息,并根据异常信息确定异常类型;在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理。In order to achieve the above purpose, the embodiment of the first aspect of the present disclosure proposes an exception handling method applied to an image processing chip, including: obtaining abnormal information during the image output process, and determining the abnormal type according to the abnormal information; reporting the abnormal information Before, control the abnormal function module in the image processing chip to retry according to the abnormal type and/or control the abnormal function module to switch to the bypass mode, so as to perform abnormal self-recovery processing on the image processing chip.
根据本公开实施例的应用于图像处理芯片的异常处理方法,通过获取图像输出过程中的异常信息,根据异常信息确定异常类型,在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理,进而在不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报 至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。According to the abnormality handling method applied to the image processing chip of the embodiment of the present disclosure, the abnormality type is determined according to the abnormality information by acquiring the abnormality information in the image output process, and the abnormality in the image processing chip is controlled according to the abnormality type before reporting the abnormality information The function module retries and/or controls the exception function module to switch to the bypass mode to perform abnormal self-recovery processing on the image processing chip, and then calls the corresponding exception handling strategy to quickly respond without affecting the upper hardware abstraction layer Abnormal adaptive recovery processing, after abnormal processing, the processing results and abnormal information are reported to the hardware abstraction layer, so that the upper hardware abstraction layer has the ability to further judge and process according to the adaptive processing results and abnormal information, so as to better Improve the robustness of the system, reduce the impact of abnormalities in the underlying image processing chip on the user experience, and improve user satisfaction.
在一个实施例中,图像处理芯片包括多个功能模块,异常信息由各个功能模块自检得到。In one embodiment, the image processing chip includes a plurality of functional modules, and the abnormality information is obtained by self-testing of each functional module.
在一个实施例中,异常类型包括可恢复异常和不可恢复异常,其中,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,包括:在异常类型为可恢复异常时,控制异常功能模块重试,以重新执行异常功能模块的功能;在异常类型为不可恢复异常时,控制异常功能模块切换为旁路模式,以使异常功能模块将接收到的信号直接输出。In one embodiment, the exception types include recoverable exceptions and non-recoverable exceptions, wherein, according to the exception type, controlling the abnormal function module in the image processing chip to retry and/or controlling the abnormal function module to switch to the bypass mode includes: When the exception type is a recoverable exception, control the exception function module to retry to re-execute the function of the exception function module; when the exception type is an unrecoverable exception, control the exception function module to switch to bypass mode so that the exception function module will receive The received signal is output directly.
在一个实施例中,在控制异常功能模块重试之后,如果重试失败,则控制异常功能更模块切换为旁路模式后重试。In one embodiment, after the retry of the control abnormal function module, if the retry fails, the control abnormal function module switches to the bypass mode and then tries again.
在一个实施例中,异常类型包括图像卡顿异常,其中,在确定图像输出过程中出现图像卡顿异常时,还对输出图像数据进行预判,以模拟出当前帧图像,以便在对异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层,以使硬件抽象层显示模拟的当期帧图像。In one embodiment, the abnormality type includes image freezing abnormality, wherein, when it is determined that image freezing abnormality occurs during the image output process, the output image data is also predicted to simulate the current frame image, so that the abnormal information When performing recovery processing, the simulated current frame image is sent to the hardware abstraction layer as an output frame image, so that the hardware abstraction layer displays the simulated current frame image.
在一个实施例中,异常类型包括内容异常,其中,在确定图像输出过程中出现内容异常时,还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使硬件抽象层显示模拟的当期帧图像。In one embodiment, the abnormality type includes content abnormality, wherein, when it is determined that content abnormality occurs during the image output process, the current frame image data is also simulated according to the historical frame image data, and the simulated current frame image data is replaced with the content abnormality. The current frame image data, so that when the exception information is restored, the simulated current frame image data is sent to the hardware abstraction layer as an output frame image, so that the hardware abstraction layer displays the simulated current frame image.
在一个实施例中,对采集到的当前帧图像数据进行图像预处理,其中,图像预处理包括自动曝光控制、自动增益控制、自动白平衡控制、镜头校正、色彩校正、伽马校正、色彩空间转换中的至少一种或多种;确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的图像参数的差异信息;根据差异信息确定异常类型是内容异常。In one embodiment, image preprocessing is performed on the collected current frame image data, wherein the image preprocessing includes automatic exposure control, automatic gain control, automatic white balance control, lens correction, color correction, gamma correction, color space At least one or more of the transformations; determining the difference information of the image parameters between the processed current frame image data and the unprocessed current frame image data; determining the abnormal type is content abnormal according to the difference information.
为达到上述目的,本公开第二方面实施例提出了一种图像处理芯片,包括:异常检测模块,用于获取图像输出过程中的异常信息,并根据异常信息确定异常类型;异常处理模块,用于在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理。In order to achieve the above purpose, the embodiment of the second aspect of the present disclosure proposes an image processing chip, including: an abnormality detection module, which is used to obtain abnormality information during the image output process, and determine the abnormality type according to the abnormality information; an abnormality processing module, which uses Before reporting the abnormal information, control the abnormal function module in the image processing chip to retry according to the abnormal type and/or control the abnormal function module to switch to the bypass mode, so as to perform abnormal self-recovery processing on the image processing chip.
根据本公开实施例的图像处理芯片,通过异常检测模块获取图像输出过程中的异常信息,并根据异常信息确定异常类型,并通过异常处理模块并在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理,进而在不影响上层的硬件抽象层情况下, 图像处理芯片可以调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。According to the image processing chip of the embodiment of the present disclosure, the abnormal information in the image output process is obtained through the abnormal detection module, and the abnormal type is determined according to the abnormal information, and the image processing is controlled according to the abnormal type through the abnormal processing module and before reporting the abnormal information The abnormal function module in the chip retries and/or controls the abnormal function module to switch to bypass mode to perform abnormal self-recovery processing on the image processing chip, and then the image processing chip can call The corresponding exception handling strategy quickly performs adaptive recovery processing corresponding to the exception, and reports the processing results and exception information to the hardware abstraction layer after exception handling, so that the upper hardware abstraction layer can make further judgments and decisions based on the adaptive processing results and exception information. The ability of processing can better improve the robustness of the system, and at the same time reduce the impact of abnormalities in the underlying image processing chip on the user experience and improve user satisfaction.
在一个实施例中,图像处理芯片包括多个功能模块,异常信息由各个功能模块自检得到。In one embodiment, the image processing chip includes a plurality of functional modules, and the abnormality information is obtained by self-testing of each functional module.
在一个实施例中,异常类型包括可恢复异常和不可恢复异常;在异常类型为可恢复异常时,异常处理模块具体用于控制异常功能模块重试,以重新执行异常功能模块的功能;在异常类型为不可恢复异常时,异常处理模块具体用于控制异常功能模块切换为旁路模式,以使异常功能模块将接收到的信号直接输出。In one embodiment, the exception type includes a recoverable exception and an unrecoverable exception; when the exception type is a recoverable exception, the exception handling module is specifically used to control the retry of the exception function module to re-execute the function of the exception function module; When the type is an unrecoverable exception, the exception handling module is specifically used to control the exception function module to switch to a bypass mode, so that the exception function module directly outputs the received signal.
在一个实施例中,异常处理模块还用于在控制异常功能模块重试之后,如果重试失败,则控制异常功能模块切换为旁路模式后重试。In one embodiment, the exception handling module is further configured to control the exception function module to switch to bypass mode and then retry if the retry fails after controlling the exception function module to retry.
在一个实施例中,异常类型包括图像卡顿异常;异常检测模块在确定图像输出过程中出现图像卡顿异常时,异常处理模块还对输出图像数据进行预判,以模拟出当前帧图像,以便在对异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层。In one embodiment, the abnormality type includes an image freezing exception; when the abnormality detection module determines that an image freezing abnormality occurs during the image output process, the abnormality processing module also predicts the output image data to simulate the current frame image, so that When recovering the abnormal information, the simulated current frame image is sent to the hardware abstraction layer as an output frame image.
在一个实施例中,异常类型包括内容异常;异常检测模块在确定图像输出过程中出现内容异常时,异常处理模块还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使硬件抽检层显示模拟的当期帧图像。In one embodiment, the abnormal type includes content abnormality; when the abnormality detection module determines that the content is abnormal during the image output process, the abnormality processing module also simulates the current frame image data according to the historical frame image data, and replaces the simulated current frame image data The current frame image data with abnormal content, so that when the abnormal information is restored, the simulated current frame image data is sent to the hardware abstraction layer as an output frame image, so that the hardware sampling layer displays the simulated current frame image.
在一个实施例中,异常检测模块具体用于:对采集到的当前帧图像数据进行图像预处理,其中,图像预处理包括自动曝光控制、自动增益控制、自动白平衡控制、镜头校正、色彩校正、伽马校正、色彩空间转换中的至少一种或多种;确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的图像参数的差异信息;根据差异信息确定异常类型是内容异常。In one embodiment, the abnormality detection module is specifically used to: perform image preprocessing on the collected image data of the current frame, wherein the image preprocessing includes automatic exposure control, automatic gain control, automatic white balance control, lens correction, color correction At least one or more of , gamma correction, and color space conversion; determine the difference information of image parameters between the current frame image data after processing and the current frame image data before processing; determine the abnormal type according to the difference information abnormal.
为达到上述目的,本公开第三方面实施例提出了一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的应用于图像处理芯片的异常处理程序,处理器执行应用于图像处理芯片的异常处理程序时,实现前述应用于图像处理芯片的异常处理方法。In order to achieve the above purpose, the embodiment of the third aspect of the present disclosure proposes an electronic device, including a memory, a processor, and an exception handling program that is stored in the memory and can be run on the processor and applied to the image processing chip. The processor executes When applied to the exception handling program of the image processing chip, the aforementioned exception handling method applied to the image processing chip is implemented.
根据本公开实施例的电子设备,通过前述应用于图像处理芯片的异常处理方法,可以在检测到异常信息后,不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力, 从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。According to the electronic device in the embodiment of the present disclosure, through the above-mentioned exception handling method applied to the image processing chip, after detecting the abnormal information, without affecting the upper hardware abstraction layer, the corresponding exception handling strategy can be called to quickly process the corresponding exception. Adaptive recovery processing, after exception processing, the processing results and abnormal information are reported to the hardware abstraction layer, so that the upper hardware abstraction layer has the ability to further judge and process according to the adaptive processing results and abnormal information, so as to better improve The robustness of the system, while reducing the impact of abnormalities in the underlying image processing chip on the user experience, and improving user satisfaction.
为达到上述目的,本公开第四方面实施例提出了一种计算机可读存储介质,其上存储有应用于图像处理芯片的异常处理程序,该应用于图像处理芯片的异常处理程序被处理器执行时,实现前述应用于图像处理芯片的异常处理方法。To achieve the above purpose, the embodiment of the fourth aspect of the present disclosure proposes a computer-readable storage medium on which is stored an exception handling program applied to an image processing chip, and the exception handling program applied to the image processing chip is executed by a processor , implement the aforementioned exception handling method applied to the image processing chip.
根据本公开实施例的计算机可读存储介质,通过前述应用于图像处理芯片的异常处理方法,可以在检测到异常信息后,不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。According to the computer-readable storage medium of the embodiment of the present disclosure, through the above-mentioned exception handling method applied to the image processing chip, after abnormal information is detected, the corresponding exception handling strategy can be called quickly without affecting the upper hardware abstraction layer. Corresponding to the adaptive recovery processing of abnormalities, the processing results and abnormal information are reported to the hardware abstraction layer after the abnormality processing, so that the upper hardware abstraction layer has the ability to make further judgments and processing based on the adaptive processing results and abnormal information, so that more Improve the robustness of the system, reduce the impact of abnormalities in the underlying image processing chip on the user experience, and improve user satisfaction.
本公开附加的方面和优点将在下面的描述中部分给出,部分将从下面的描述中变得明显,或通过本公开的实践了解到。Additional aspects and advantages of the disclosure will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the disclosure.
附图说明Description of drawings
图1为根据本公开实施例的电子设备的结构示意图;FIG. 1 is a schematic structural diagram of an electronic device according to an embodiment of the disclosure;
图2为根据本公开实施例的应用于图像处理芯片的异常处理方法的流程图;FIG. 2 is a flowchart of an exception handling method applied to an image processing chip according to an embodiment of the present disclosure;
图3为根据本公开实施例的不同异常类型对应的异常处理策略流程图;FIG. 3 is a flow chart of exception handling strategies corresponding to different exception types according to an embodiment of the present disclosure;
图4为根据本公开实施例的图像处理芯片的图像异常检测及处理模块的结构示意图;4 is a schematic structural diagram of an image anomaly detection and processing module of an image processing chip according to an embodiment of the disclosure;
图5为根据本公开实施例的图像处理芯片的结构示意图。FIG. 5 is a schematic structural diagram of an image processing chip according to an embodiment of the disclosure.
具体实施方式Detailed ways
下面详细描述本公开的实施例,所述实施例的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,旨在用于解释本公开,而不能理解为对本公开的限制。Embodiments of the present disclosure are described in detail below, examples of which are illustrated in the drawings, in which the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the figures are exemplary and are intended to explain the present disclosure and should not be construed as limiting the present disclosure.
下面详细描述本公开的实施例,所述实施例的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,旨在用于解释本公开,而不能理解为对本公开的限制。Embodiments of the present disclosure are described in detail below, examples of which are illustrated in the drawings, in which the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the figures are exemplary and are intended to explain the present disclosure and should not be construed as limiting the present disclosure.
正如背景技术所述,目前相机的图像处理芯片在发生异常时,对异常的处理主要是直接返回错误号至相机的硬件抽象层,使相机的硬件抽象层处理异常。或者图像处理芯片在发现异常时,将对应发生异常的功能模块进行标注,直接关闭发生异常的功能模块。或者, 图像处理芯片直接宕机,抛出异常,以使相机的硬件抽象层处理异常。当图像处理芯片处理的图像数据发生异常时,图像处理芯片无法检测图像异常,直接将异常的图像进行输出,使得用户对异常可见。因此,图像处理芯片无论是将异常类型反馈给调用函数或是直接宕机,都会使得上层的硬件抽象层可见,从而影响了上层的硬件抽象层的使用和用户的体验效果。As mentioned in the background art, when an exception occurs in the image processing chip of the current camera, the processing of the exception is mainly to directly return an error number to the hardware abstraction layer of the camera, so that the hardware abstraction layer of the camera handles the exception. Alternatively, when the image processing chip finds an abnormality, it will mark the corresponding functional module that has the abnormality, and directly shut down the functional module that has the abnormality. Alternatively, the image processing chip directly shuts down and throws an exception, so that the hardware abstraction layer of the camera handles the exception. When the image data processed by the image processing chip is abnormal, the image processing chip cannot detect the image abnormality, and directly outputs the abnormal image, so that the user can see the abnormality. Therefore, whether the image processing chip feeds back the abnormal type to the calling function or directly crashes, it will make the upper hardware abstraction layer visible, thus affecting the use of the upper hardware abstraction layer and the user experience effect.
针对上述技术问题,本公开提供一种应用于图像处理芯片的异常处理方法、图像处理芯片、电子设备和计算机可读存储介质,可以对图像处理芯片的异常和图像内容的异常主动发起检测,当异常出现时可以提前检测到异常并获取相关异常信息,进而在不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,提高用户体验。In view of the above technical problems, the present disclosure provides an abnormality processing method applied to an image processing chip, an image processing chip, an electronic device, and a computer-readable storage medium, which can actively initiate detection of abnormalities in the image processing chip and abnormalities in image content. When an exception occurs, it can detect the exception in advance and obtain relevant abnormal information, and then call the corresponding exception handling strategy to quickly perform adaptive recovery processing of the corresponding exception without affecting the upper hardware abstraction layer, improving user experience.
下参考附图描述本公开实施例的应用于图像处理芯片的异常处理方法、图像处理芯片、电子设备和计算机可读存储介质。An exception handling method applied to an image processing chip, an image processing chip, an electronic device, and a computer-readable storage medium according to embodiments of the present disclosure will be described below with reference to the accompanying drawings.
如图1所示,本公开提供一种电子装置,包括图像处理芯片10和硬件抽象层20。其中,图像处理芯片10用于接收原始图像数据,并对原始图像数据进行处理。本公开中,图像处理芯片10实时检测图像输出过程中是否发生异常,并在发生异常时获取异常信息,根据异常信息确定异常类型,以及根据异常类型确定相应的异常处理策略。图像处理芯片10在根据异常处理策略完成异常自适应处理后,将异常信息和处理结果上报给硬件抽象层20,从而使得底层的异常对上层的硬件抽象层20不可见,避免底层的异常情况影响上层的硬件抽象层20的使用,提高了用户体验。需要说明的是,本公开中电子装置可以为手机、平板电脑、个人计算机、智能相机以及车载图像采集设备等具有拍照或摄像功能的设备。As shown in FIG. 1 , the present disclosure provides an electronic device including an image processing chip 10 and a hardware abstraction layer 20 . Wherein, the image processing chip 10 is used for receiving original image data and processing the original image data. In the present disclosure, the image processing chip 10 detects in real time whether an abnormality occurs during the image output process, obtains abnormality information when an abnormality occurs, determines the abnormality type according to the abnormality information, and determines a corresponding abnormality handling strategy according to the abnormality type. After the image processing chip 10 completes the abnormal adaptive processing according to the abnormal processing strategy, it reports the abnormal information and processing results to the hardware abstraction layer 20, so that the underlying abnormalities are invisible to the upper hardware abstraction layer 20, avoiding the impact of the underlying abnormal conditions The use of the upper hardware abstraction layer 20 improves user experience. It should be noted that the electronic device in the present disclosure may be a mobile phone, a tablet computer, a personal computer, a smart camera, and a vehicle-mounted image acquisition device, etc., which have a camera or camera function.
图2为根据本公开实施例的应用于图像处理芯片的异常处理方法的流程图。参考图2所示,该方法可包括以下步骤:FIG. 2 is a flowchart of an exception handling method applied to an image processing chip according to an embodiment of the disclosure. Referring to Figure 2, the method may include the following steps:
步骤S101,获取图像输出过程中的异常信息,并根据异常信息确定异常类型。Step S101, acquiring abnormality information during the image output process, and determining the abnormality type according to the abnormality information.
电子装置包括图像采集器,图像采集器用于采集图像数据以进行预览或拍摄。图像采集器将采集到的图像数据发送至图像处理芯片。图像处理芯片用于对接收到的图像数据进行处理并在处理后输出至上层的硬件抽象层。图像处理芯片在处理图像数据的过程中发生异常情况时,例如图像处理芯片中的功能模块发生异常或图像内容发生异常等,图像处理芯片可以利用自身的异常检测机制检测异常并获取异常信息。The electronic device includes an image collector, which is used to collect image data for preview or shooting. The image collector sends the collected image data to the image processing chip. The image processing chip is used to process the received image data and output it to the upper hardware abstraction layer after processing. When the image processing chip is abnormal in the process of processing image data, for example, the functional modules in the image processing chip are abnormal or the image content is abnormal, etc., the image processing chip can use its own abnormal detection mechanism to detect the abnormality and obtain abnormal information.
在其中一个实施例中,图像处理芯片包括多个功能模块,异常信息由各个功能模块对自身进行检测得到。In one embodiment, the image processing chip includes multiple functional modules, and the abnormality information is obtained by each functional module detecting itself.
具体来说,图像处理芯片的功能模块包括图像前处理模块,图像前处理模块用于对图像 采集器采集到的图像数据进行处理,例如进行镜头阴影校正处理、局部色调映射处理等。图像处理芯片还包括初始化子模块、通信子模块、电源管理子模块、温度检测子模块、场景切换子模块、资源公开子模块等。当各个功能模块在工作过程中发生异常情况时,由各个功能模块检测异常并获取自身的异常信息。各个功能模块还将模块标识和异常信息打包发送至图像处理芯片的异常检测模块,异常检测模块对异常信息进行检测,并将检测结果发送至异常处理模块,以便异常处理模块根据异常信息进行异常处理。Specifically, the functional modules of the image processing chip include an image pre-processing module, which is used to process the image data collected by the image collector, such as lens shading correction processing, local tone mapping processing, etc. The image processing chip also includes an initialization sub-module, a communication sub-module, a power management sub-module, a temperature detection sub-module, a scene switching sub-module, a resource disclosure sub-module, etc. When abnormal situations occur in the working process of each functional module, each functional module detects the abnormality and obtains its own abnormality information. Each functional module also packs the module identification and abnormal information and sends them to the abnormal detection module of the image processing chip. The abnormal detection module detects the abnormal information and sends the detection results to the abnormal processing module, so that the abnormal processing module can perform abnormal processing according to the abnormal information .
异常检测模块还可以对处理前后的图像数据或者功能模块的参数进行检测,根据处理前后的图像数据判断是否发生异常,或者判断各功能模块的参数是否超出预设范围以判断是否发生异常,并在检测出发生异常时获取异常信息发送至异常处理模块,以便异常处理模块进行异常处理。The abnormality detection module can also detect the image data before and after processing or the parameters of the functional modules, judge whether an abnormality occurs according to the image data before and after processing, or judge whether the parameters of each functional module exceed the preset range to determine whether an abnormality occurs, and When an exception is detected, the abnormal information is obtained and sent to the exception handling module, so that the exception handling module can handle the exception.
本实施例中,图像处理芯片预先根据各个功能模块的功能和场景将常见的异常情况定义不同的异常类型,进而基于不同的异常类型制定相应的异常处理策略,并将异常类型及其对应的异常处理策略预存于异常处理模块中。当异常发生时,异常处理模块通过结合相关不同异常功能模块的异常信息,综合判断得到所属的异常类型,再进一步根据不同异常类型的异常处理策略进行自适应的异常处理,最终实现用户无感知的异常恢复。In this embodiment, the image processing chip defines different exception types for common abnormal situations in advance according to the functions and scenarios of each functional module, and then formulates corresponding exception handling strategies based on different exception types, and lists the exception types and their corresponding exceptions The handling strategy is pre-stored in the exception handling module. When an exception occurs, the exception handling module comprehensively judges the exception type by combining the exception information of different exception function modules, and then performs adaptive exception handling according to the exception handling strategies of different exception types, and finally realizes the user-unaware Abnormal recovery.
步骤S103,在对异常信息上报前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理。Step S103, before reporting the abnormal information, control the abnormal function module in the image processing chip to retry according to the abnormal type and/or control the abnormal function module to switch to the bypass mode, so as to perform abnormal self-recovery processing on the image processing chip.
异常处理模块获取异常功能模块的异常类型后,控制异常功能模块进行自恢复处理,自恢复处理完成后,异常处理模块再将异常信息上报至相机硬件抽象层。在控制异常功能模块进行自恢复处理时,可以控制异常功能模块进行重试,也即重新执行异常功能模块的功能,例如,控制异常功能模块恢复默认设置后重试,或控制异常功能模块恢复出厂设置后重试等。或者,在控制异常功能模块进行自恢复处理时,可以控制异常功能模块切换为旁路模式(Bypass),也即控制异常功能模块对接收到的信号不作处理,并直接将信号输出至下一级功能模块。从而,上层的相机硬件抽象层无需对异常信息进行处理,底层的图像处理芯片在发现异常时根据异常处理策略进行异常自恢复处理,处理完成后再将异常信息上报至上层的硬件抽象层,从而实现用户无感知的异常恢复。After the exception processing module obtains the exception type of the abnormal function module, it controls the abnormal function module to perform self-recovery processing. After the self-recovery processing is completed, the abnormal processing module reports the abnormal information to the camera hardware abstraction layer. When controlling the abnormal function module to perform self-recovery processing, it can control the abnormal function module to retry, that is, re-execute the function of the abnormal function module, for example, control the abnormal function module to restore the default settings and then retry, or control the abnormal function module to restore the factory Try again after setting etc. Or, when controlling the abnormal function module to perform self-recovery processing, the abnormal function module can be controlled to switch to the bypass mode (Bypass), that is, the abnormal function module is controlled not to process the received signal, and directly outputs the signal to the next level functional module. Therefore, the upper camera hardware abstraction layer does not need to process abnormal information, and the underlying image processing chip performs abnormal self-recovery processing according to the abnormal handling strategy when an abnormality is found, and then reports the abnormal information to the upper hardware abstraction layer after the processing is completed, thereby Realize abnormal recovery without user perception.
在其中一个实施例中,异常类型包括可恢复异常和不可恢复异常,其中,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,包括:在异常类型为可恢复异常时,控制异常功能模块重试,以重新执行所述异常功能模块的功能;在异常类型为不可恢复异常时,控制异常功能模块切换为旁路模式,以使异常功 能模块将接收到的信号直接输出。In one embodiment, the exception types include recoverable exceptions and non-recoverable exceptions, wherein, according to the exception type, the abnormal function module in the image processing chip is controlled to retry and/or the abnormal function module is controlled to switch to the bypass mode, including: When the abnormal type is a recoverable exception, control the abnormal function module to retry to re-execute the function of the abnormal function module; The module outputs the received signal directly.
具体来说,可恢复异常为图像处理芯片可自行处理并恢复的异常,不可恢复异常为图像处理模块无法自行处理恢复的异常。当发生异常类型为可恢复异常时,则异常处理模块控制异常功能模块进行重试,例如直接重试、重启后重试、恢复前一次设置后重试或使用默认设置后重试等。Specifically, a recoverable exception is an exception that the image processing chip can process and recover by itself, and an unrecoverable exception is an exception that the image processing module cannot process and recover by itself. When the exception type is a recoverable exception, the exception handling module controls the exception function module to retry, such as direct retry, retry after restart, retry after restoring the previous setting, or retry after using the default setting.
进一步地,当控制异常功能模块重试后,若异常仍未恢复,则异常处理模块控制异常功能模块切换为旁路模式后重试。具体来说,异常处理模块可以控制异常功能模块连续多次重试,若连续多次重试后均重试失败,则异常处理模块控制异常功能模块切换为旁路模式,也即将接收到的信号直接输出,从而可以避免影响图像数据的输出,以防上层的硬件抽象层感应到底层发生异常。在控制异常功能模块切换为旁路模式后,可继续控制异常功能模块重试。若重试后异常恢复,则控制异常功能模块切换为正常工作模式;若仍然重试失败,则可以将异常信息上报至上层的硬件抽象层,以便上层的硬件抽象层对异常信息进行处理。Further, after controlling the abnormal function module to retry, if the abnormality has not been recovered, the abnormal processing module controls the abnormal function module to switch to the bypass mode and then retry. Specifically, the exception handling module can control the exception function module to retry multiple times in a row. If the retry fails after multiple consecutive retries, the exception handling module controls the exception function module to switch to the bypass mode, which means that the received signal Direct output, so as to avoid affecting the output of image data, in case the upper hardware abstraction layer senses that the bottom layer is abnormal. After controlling the abnormal function module to switch to the bypass mode, the abnormal function module can continue to be controlled to retry. If the abnormality recovers after retrying, the control abnormality function module is switched to the normal working mode; if the retrying still fails, the abnormality information can be reported to the upper hardware abstraction layer, so that the upper layer hardware abstraction layer can process the abnormality information.
当发生的异常为不可恢复异常时,异常处理模块控制异常功能模块直接切换为旁路模式,以避免影响图像数据的输出,防止上层感应到底层发生的异常情况。When the abnormality that occurs is an unrecoverable abnormality, the abnormality processing module controls the abnormality function module to directly switch to the bypass mode, so as to avoid affecting the output of image data and prevent the upper layer from sensing the abnormality that occurs at the bottom layer.
本实施例中,图像处理芯片中常见的的异常类型及其对应的异常处理策略统计如下表所示:In this embodiment, the common exception types in image processing chips and their corresponding exception handling strategies are summarized in the following table:
Figure PCTCN2022089014-appb-000001
Figure PCTCN2022089014-appb-000001
Figure PCTCN2022089014-appb-000002
Figure PCTCN2022089014-appb-000002
具体来说,上述表格主要是以图像处理芯片的内部和外部两大类异常进行异常状态的分类,当然对于异常还可以根据处理方式进行分类,例如是否为可恢复异常或不可恢复异常,举例来说,对于场景切换和向相机硬件抽象层公开资源失败可以先通过重试的方式进行再次尝试,如果仍然不成功再切换为旁路模式处理;对于温升异常一类可以归为业务场景异常,为不可自恢复异常,可以相关的异常信息反馈给对应的功能模块,由对应的功能模块根据自身的处理策略进行处理。Specifically, the above table mainly classifies the abnormal state based on the internal and external abnormalities of the image processing chip. Of course, the abnormality can also be classified according to the processing method, such as whether it is a recoverable exception or an unrecoverable exception. For example, That is to say, for scene switching and failure to disclose resources to the camera hardware abstraction layer, you can try again by retrying first, and if it is still unsuccessful, then switch to bypass mode for processing; for temperature rise exceptions, it can be classified as business scene exceptions, For non-self-recoverable exceptions, relevant abnormal information can be fed back to the corresponding functional modules, and the corresponding functional modules will handle them according to their own processing strategies.
图3为常见的异常类型及其异常处理策略的异常处理流程,如图3所示,当图像处理芯片初始化失败、场景切换失败、通信失败、图像参数信息传输异常或电源控制异常时,先控制相应的异常功能模块重试。若重试后异常恢复,则上报异常信息至上层的硬件抽象层,且系统恢复正常运行;若重试后异常仍未恢复,则控制异常功能模块恢复前次设置。若恢复前次设置后异常恢复,则上报异常信息至上层的硬件抽象层,且系统恢复正常运行;若恢复前次设置后仍未成功,则控制异常功能模块使用默认设置。若使用默认设置后异常恢复,则上报异常信息至上层的硬件抽象层,且系统恢复正常运行;若使用默认设置后异常仍未恢复,则重置相应的异常功能模块。若重置异常功能模块后异常恢复,则上报异常信息至上层的硬件抽象层,且系统恢复正常运行;若重置后异常仍未恢复,则控制相应的异常功能模块切换到旁路模式,并上报异常信息。若图像处理芯片根据温度参数检测到温升异常,则将温升异常信息发送至电源管理模块,以便电源管理模块根据温升异常信息进行处理。当图像处理芯片中的子线程处于闭锁状态时,控制对应的子线程重启,若重启成功,则上报异常信息至上层的硬件抽象层;若重启失败,则控制相应的子线程切换至旁路模式,并上报异常信息至上层的硬件抽象层。若外接处理器下发参数异常,则向上层的硬件抽象层返回错误码,以便上层的硬件抽象层根据错误码进行异常处理。若图像处理芯片向上层的硬件抽象层公开资源失败,或与上层的硬件抽象层通信失败,则先控制相应的异常功能模块重试。若重试后异常恢复,则导出调试设置信息,并将异常信息和调试设置信息上报 给上层的硬件抽象层,系统恢复正常运行;若重试后异常仍未恢复,则控制异常功能模块恢复前次设置。若恢复前次设置后异常恢复,则上报异常信息至上层的硬件抽象层,且系统恢复正常运行;若恢复前次设置后仍未成功,则控制异常功能模块切换到旁路模式。若电源管理芯片上电失败,则控制系统重启,若重启后异常恢复,则导出调试设置信息,并将异常信息和调试设置信息上报给上层的硬件抽象层,系统恢复正常运行;若重启后异常仍未恢复,则控制电源管理芯片切换到旁路模式。若发生唤醒失败、进程间通信失败或模块宕机,则检测异常信息,并控制异常功能模块切换到旁路模式后,将异常信息上报至上层的硬件抽象层。Figure 3 shows the exception handling process of common exception types and their exception handling strategies. The corresponding exception function module retries. If the abnormality is recovered after retrying, the abnormality information is reported to the upper hardware abstraction layer, and the system returns to normal operation; if the abnormality is not recovered after retrying, the abnormal function module is controlled to restore the previous settings. If the abnormality is recovered after restoring the previous setting, the abnormality information will be reported to the upper hardware abstraction layer, and the system will resume normal operation; if the previous setting is still unsuccessful, the control abnormality function module will use the default setting. If the abnormality is recovered after using the default settings, the abnormal information will be reported to the upper hardware abstraction layer, and the system will resume normal operation; if the abnormality has not been recovered after using the default settings, the corresponding abnormal function module will be reset. If the abnormality recovers after resetting the abnormal function module, the abnormal information is reported to the upper hardware abstraction layer, and the system returns to normal operation; if the abnormality has not recovered after reset, the corresponding abnormal function module is controlled to switch to the bypass mode, and Report exception information. If the image processing chip detects an abnormal temperature rise according to the temperature parameter, it will send the abnormal temperature rise information to the power management module, so that the power management module can process it according to the abnormal temperature rise information. When the sub-thread in the image processing chip is in the locked state, control the corresponding sub-thread to restart, if the restart is successful, report the abnormal information to the upper hardware abstraction layer; if the restart fails, control the corresponding sub-thread to switch to the bypass mode , and report the exception information to the upper hardware abstraction layer. If the parameter delivered by the external processor is abnormal, an error code is returned to the upper-layer hardware abstraction layer, so that the upper-layer hardware abstraction layer performs exception handling according to the error code. If the image processing chip fails to disclose resources to the upper hardware abstraction layer, or fails to communicate with the upper hardware abstraction layer, it first controls the corresponding abnormal function module to retry. If the abnormality is recovered after retrying, the debugging setting information will be exported, and the abnormality information and debugging setting information will be reported to the upper hardware abstraction layer, and the system will resume normal operation; settings. If the abnormality is restored after restoring the previous setting, the abnormality information will be reported to the upper hardware abstraction layer, and the system will resume normal operation; if the restoration of the previous setting is still unsuccessful, the control abnormality function module will switch to the bypass mode. If the power management chip fails to be powered on, the control system will restart, and if it recovers abnormally after restarting, the debugging setting information will be exported, and the abnormal information and debugging setting information will be reported to the upper hardware abstraction layer, and the system will resume normal operation; Still not restored, control the power management chip to switch to the bypass mode. If wake-up failure, inter-process communication failure or module downtime occurs, the abnormal information will be detected, and after the abnormal function module is controlled to switch to bypass mode, the abnormal information will be reported to the upper hardware abstraction layer.
在其中一个实施例中,异常类型还包括图像卡顿异常,其中,在确定图像输出过程中出现图像卡顿异常时,还对输出图像数据进行预判,以模拟出当前帧图像,以便在对异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层,以使硬件抽象层显示模拟的当前帧图像。In one of the embodiments, the abnormality type also includes image freeze abnormality, wherein, when it is determined that image freeze abnormality occurs during the image output process, the output image data is also predicted to simulate the current frame image, so as to When the exception information is restored, the simulated current frame image is sent to the hardware abstraction layer as an output frame image, so that the hardware abstraction layer displays the simulated current frame image.
具体来说,当异常功能模块进行自适应的异常恢复时,会导致图像数据暂停处理,进而导致短时间的图像卡顿异常。因此,在确定图像输出过程中出现图像卡顿异常时,可以通过图像处理芯片对图像数据进行预判以输出模拟的当前帧图像。举例来说,当前帧图像包括运动物体,则可以提取当前帧图像的运动目标作为图像主体,运动目标以外的区域作为图像背景,在进行预判时,根据预设的运动模型预判运动目标的变化趋势,再结合图像背景生成模拟的当前帧图像。在异常功能模块进行自适应的异常恢复时,可以将模拟的当前帧图像作为输出帧图像发送到硬件抽象层,以便硬件抽象层控制显示器显示模拟的当前帧图像,从而避免输出图像卡顿,使得用户对底层的图像处理芯片发生的异常无感知,提高用户体验。Specifically, when the abnormal function module performs adaptive abnormal recovery, it will cause the processing of image data to be suspended, which in turn will cause a short-term image freeze abnormality. Therefore, when it is determined that an abnormal image freeze occurs during the image output process, the image data may be pre-judged by the image processing chip to output a simulated current frame image. For example, if the current frame image includes a moving object, the moving object of the current frame image can be extracted as the image subject, and the area other than the moving object is used as the image background. Change trend, combined with the image background to generate a simulated current frame image. When the abnormal function module performs adaptive abnormal recovery, the simulated current frame image can be sent to the hardware abstraction layer as the output frame image, so that the hardware abstraction layer controls the display to display the simulated current frame image, thereby avoiding the output image freeze, so that The user is not aware of the abnormality of the underlying image processing chip, which improves the user experience.
在其中一个实施例中,异常类型还包括内容异常,在判断图像输出过程中出现内容异常时,还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使硬件抽象层显示模拟的当期帧图像。In one of the embodiments, the abnormality type also includes content abnormality. When it is judged that content abnormality occurs during the image output process, the current frame image data is also simulated according to the historical frame image data, and the simulated current frame image data is replaced with the content abnormality. The current frame image data, so that when the exception information is restored, the simulated current frame image data is sent to the hardware abstraction layer as an output frame image, so that the hardware abstraction layer displays the simulated current frame image.
进一步地,根据异常信息确定异常类型,包括:对采集到的当前帧图像数据进行图像预处理,其中,图像预处理包括自动曝光控制、自动增益控制、自动白平衡控制、镜头校正、色彩校正、伽马校正、色彩空间转换中的至少一种或多种;确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的图像参数的差异信息;根据差异信息确定异常类型是内容异常。Further, determining the abnormal type according to the abnormal information includes: performing image preprocessing on the collected current frame image data, wherein the image preprocessing includes automatic exposure control, automatic gain control, automatic white balance control, lens correction, color correction, At least one or more of gamma correction and color space conversion; determine the difference information of image parameters between the processed current frame image data and the pre-processed current frame image data; determine that the abnormal type is content abnormal according to the difference information .
具体来说,图像处理芯片对获取的当前帧图像数据进行图像预处理后,会将处理后的当 前帧图像数据与处理前的当前帧图像数据进行比较,比较时,可以逐一比较每个处理项目处理前后的图像参数,例如图像白平衡参数、曝光参数、增益参数、镜头校正参数、色彩校正参数、伽马校正参数和色彩空间转换参数等,确定处理后的当前帧图像数据和处理前的当前帧图像数据的图像参数的差异信息,并根据差异信息确定是否发生内容异常,其中,内容异常包括图像黑帧、图像撕裂等等。当处理前后图像参数的差异大于预设范围,则可以判定图像内容发生异常。Specifically, after the image processing chip performs image preprocessing on the acquired current frame image data, it will compare the processed current frame image data with the pre-processed current frame image data. When comparing, each processing item can be compared one by one. Image parameters before and after processing, such as image white balance parameters, exposure parameters, gain parameters, lens correction parameters, color correction parameters, gamma correction parameters and color space conversion parameters, etc., determine the current frame image data after processing and the current frame before processing The difference information of the image parameters of the frame image data, and determine whether content abnormality occurs according to the difference information, wherein the content abnormality includes image black frame, image tearing and so on. When the difference of image parameters before and after processing is greater than a preset range, it can be determined that the image content is abnormal.
如图4所示,图像处理芯片包括图像前处理模块11、异常检测模块12、图像检测模块13和异常处理及插帧模块14。其中,图像前处理模块11用于对接收到的原始图像数据进行处理,并将处理后的图像数据发送至图像检测模块12。在实际对图片异常进行识别判断时,图像处理芯片可以先将处理之前的原始图像数据进行缓存。在对图像处理完之后,图像检测模块12将输出的处理后的当前帧图像数据和缓存的原始图像数据做对比,分析处理前后两个图像之间像素点或子区域之间的差异,其中,像素点或子区域的选取可以根据拍摄内容和场景确定。通常,图像前处理的目的是为了提升图像的质量,因此对于图像数据的处理是在预设范围内进行的,如果处理前后图像数据的差异超出预设范围,则可以判定为图像处理过程出现的图像异常,则图像检测模块12将图像异常信息发送至异常处理及插帧模块14。异常处理及插帧模块14需要将该当前帧图像数据进行截留,并根据历史帧图像数据模拟出一帧当前帧图像,并临时送给上层的硬件抽象层做显示,避免影响用户的体验。同时,异常处理及插帧模块14还根据图像的异常信息确定图像前处理模块11中的异常功能模块,并控制异常功能模块进行异常自适应恢复处理。As shown in FIG. 4 , the image processing chip includes an image pre-processing module 11 , an abnormality detection module 12 , an image detection module 13 and an abnormality processing and frame insertion module 14 . Wherein, the image pre-processing module 11 is used to process the received original image data, and send the processed image data to the image detection module 12 . When actually identifying and judging an abnormal picture, the image processing chip can first cache the original image data before processing. After the image is processed, the image detection module 12 compares the output processed current frame image data with the buffered original image data, and analyzes the difference between the pixels or sub-regions between the two images before and after processing, wherein, The selection of pixels or sub-regions can be determined according to the shooting content and scene. Usually, the purpose of image pre-processing is to improve the quality of the image, so the processing of image data is carried out within the preset range. If the difference between the image data before and after processing exceeds the preset range, it can be judged as an error in the image processing process. If the image is abnormal, the image detection module 12 sends the image abnormality information to the abnormality processing and frame insertion module 14 . The exception processing and frame interpolation module 14 needs to intercept the current frame image data, simulate a current frame image according to the historical frame image data, and temporarily send it to the upper hardware abstraction layer for display, so as to avoid affecting the user experience. At the same time, the abnormality processing and frame interpolation module 14 also determines the abnormal function module in the image pre-processing module 11 according to the abnormal information of the image, and controls the abnormal function module to perform abnormal adaptive recovery processing.
当图像前处理模块11发生异常时,异常检测模块12用于获取图像前处理模块11的异常信息,并对异常信息进行识别获取异常类型,将异常类型发送至图像检测模块12。图像检测模块12将图像前处理模块11的异常信息发送至异常处理及插帧模块14,异常处理及插帧模块14还根据图像前处理模块11的异常信息启动自身的异常恢复机制,例如对模块进行重启或重新初始化等,以进行异常自适应恢复处理。When an abnormality occurs in the image pre-processing module 11 , the abnormality detection module 12 is used to obtain the abnormality information of the image pre-processing module 11 , identify the abnormality information to obtain the abnormality type, and send the abnormality type to the image detection module 12 . The image detection module 12 sends the abnormal information of the image pre-processing module 11 to the abnormal processing and frame interpolation module 14, and the abnormal processing and frame interpolation module 14 also starts its own abnormal recovery mechanism according to the abnormal information of the image pre-processing module 11, for example, for the module Restart or reinitialize, etc., for exception adaptive recovery processing.
上述实施例提供的应用于图像处理芯片的异常处理方法,通过对系统的异常和图像的异常主动发起检测,当异常出现时可以提前检测到异常并获取相关异常信息,进而在不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。The abnormality handling method applied to the image processing chip provided by the above embodiment actively initiates the detection of the abnormality of the system and the abnormality of the image. In the case of the abstraction layer, call the corresponding exception handling strategy to quickly perform adaptive recovery processing of the corresponding exception, and report the processing result and exception information to the hardware abstraction layer after the exception handling, so that the upper hardware abstraction layer has the basis for adaptive processing results and The ability to further judge and process abnormal information can better improve the robustness of the system, reduce the impact of abnormalities in the underlying image processing chip on the user experience, and improve user satisfaction.
如图5所示,本公开的又一实施例提供一种图像处理芯片,包括异常检测模块51和异 常处理模块52。其中,异常检测模块51用于获取图像输出过程中的异常信息,并根据异常信息确定异常类型。异常处理模块52用于在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理。As shown in FIG. 5 , another embodiment of the present disclosure provides an image processing chip, including an abnormality detection module 51 and an abnormality processing module 52 . Wherein, the abnormality detection module 51 is used for obtaining abnormality information during the image output process, and determining the type of abnormality according to the abnormality information. The exception processing module 52 is used to control the abnormal function module in the image processing chip to retry according to the abnormal type and/or control the abnormal function module to switch to the bypass mode before reporting the abnormal information, so as to perform abnormal self-recovery on the image processing chip deal with.
在其中一个实施例中,图像处理芯片包括多个功能模块,异常信息由各个功能模块对自身进行检测得到。各个功能模块在检测到自身的异常信息后,将异常信息发送至异常检测模块51,进而异常检测模块51将异常信息发送至异常处理模块52,异常处理模块52根据异常信息调用相应的异常处理策略以及行异常自适应恢复处理。In one embodiment, the image processing chip includes multiple functional modules, and the abnormality information is obtained by each functional module detecting itself. After each functional module detects its own abnormal information, it sends the abnormal information to the abnormal detection module 51, and then the abnormal detection module 51 sends the abnormal information to the abnormal processing module 52, and the abnormal processing module 52 invokes the corresponding abnormal processing strategy according to the abnormal information And row exception adaptive recovery processing.
在其中一个实施例中,异常类型包括可恢复异常和不可恢复异常。异常处理模块52具体用于在异常类型为可恢复异常时,控制异常功能模块重试,以重新执行所述异常功能模块的功能;在异常类型为不可恢复异常时,控制异常功能模块切换为旁路模式,以使异常功能模块将接收到的信号直接输出。In one embodiment, the exception types include recoverable exceptions and unrecoverable exceptions. The exception handling module 52 is specifically used to control the retry of the exception function module when the exception type is a recoverable exception, so as to re-execute the function of the exception function module; channel mode, so that the abnormal function module outputs the received signal directly.
在其中一个实施例中,异常处理模块52在控制异常功能模块重试之后,如果重试失败,则控制异常功能模块切换为旁路模式后重试。In one of the embodiments, after the abnormality processing module 52 controls the abnormal function module to retry, if the retry fails, it controls the abnormal function module to switch to the bypass mode and then retry.
在其中一个实施例中,异常类型包括图像卡顿异常。在确定图像输出过程中出现图像卡顿异常时,异常处理模块52还对输出的图像数据进行预判,以模拟出当前帧图像,以便在对异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层。In one of the embodiments, the abnormality type includes image freeze abnormality. When it is determined that an image freeze abnormality occurs during the image output process, the abnormal processing module 52 also predicts the output image data to simulate the current frame image, so that the simulated current frame image can be used as the The output frame image is sent to the hardware abstraction layer.
在其中一个实施例中,异常类型包括内容异常,在判断图像输出过程中出现内容异常时,异常处理模块52还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使所述硬件抽检层显示所述模拟的当期帧图像。In one of the embodiments, the abnormality type includes content abnormality. When it is judged that content abnormality occurs during the image output process, the abnormality processing module 52 also simulates the current frame image data according to the historical frame image data, and replaces the simulated current frame image data. The current frame image data with abnormal content, so that when the abnormal information is restored, the simulated current frame image data is sent to the hardware abstraction layer as an output frame image, so that the hardware sampling layer displays the simulated current frame image.
在其中一个实施例中,异常检测模块51具体用于对采集到的当前帧图像数据进行图像预处理,确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的差异信息,根据差异信息确定异常类型是内容异常。In one of the embodiments, the abnormality detection module 51 is specifically configured to perform image preprocessing on the collected current frame image data, determine the difference information between the processed current frame image data and the pre-processed current frame image data, according to The difference information determines that the exception type is a content exception.
需要说明的是,关于本公开中图像处理芯片的描述,请参考本公开中关于应用于图像处理芯片的异常处理方法的描述,具体这里不再赘述。It should be noted that, for the description of the image processing chip in the present disclosure, please refer to the description of the exception handling method applied to the image processing chip in the present disclosure, and details will not be repeated here.
上述实施例提供的图像处理芯片,通过异常检测模块获取图像输出过程中的异常信息,并根据异常信息确定异常类型,并通过异常处理模块在对异常信息上报之前,根据异常类型控制图像处理芯片中的异常功能模块进行重试和/或控制异常功能模块切换为旁路模式,以对图像处理芯片进行异常自恢复处理,进而在不影响上层的硬件抽象层情况下,图像处 理芯片可以调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。In the image processing chip provided by the above embodiments, the abnormal information in the image output process is obtained through the abnormal detection module, and the abnormal type is determined according to the abnormal information, and the abnormal information is controlled by the abnormal processing module before reporting the abnormal information. The abnormal function module retries and/or controls the abnormal function module to switch to the bypass mode to perform abnormal self-recovery processing on the image processing chip, and then the image processing chip can call the corresponding The exception handling strategy quickly performs adaptive recovery processing corresponding to the exception, and reports the processing result and exception information to the hardware abstraction layer after exception handling, so that the upper hardware abstraction layer can make further judgment and processing based on the adaptive processing result and exception information ability, so as to better improve the robustness of the system, and at the same time reduce the impact of abnormalities in the underlying image processing chip on the user experience and improve user satisfaction.
本公开的又一实施例提供一种电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的应用于图像处理芯片的异常处理程序,处理器执行应用于图像处理芯片的异常处理程序时,实现前述应用于图像处理芯片的异常处理方法。Another embodiment of the present disclosure provides an electronic device, including a memory, a processor, and an exception handling program applied to an image processing chip stored on the memory and operable on the processor, and the processor executes the program applied to the image processing chip When the exception handling program is used, the aforementioned exception handling method applied to the image processing chip is implemented.
上述电子设备,通过前述应用于图像处理芯片的异常处理方法,可以在检测到异常信息后,不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。The above-mentioned electronic device, through the above-mentioned exception handling method applied to the image processing chip, can call the corresponding exception handling strategy to quickly perform adaptive recovery processing corresponding to the exception after detecting the abnormal information without affecting the upper hardware abstraction layer. After exception handling, the processing results and abnormal information are reported to the hardware abstraction layer, so that the upper hardware abstraction layer has the ability to further judge and process according to the adaptive processing results and abnormal information, so as to better improve the robustness of the system , and at the same time reduce the impact of the abnormality of the underlying image processing chip on the user experience, and improve user satisfaction.
本公开的又一实施例提供一种计算机可读存储介质,其上存储有应用于图像处理芯片的异常处理程序,该应用于图像处理芯片的异常处理程序被处理器执行时,实现前述应用于图像处理芯片的异常处理方法。Yet another embodiment of the present disclosure provides a computer-readable storage medium, on which is stored an exception handling program applied to an image processing chip. When the exception handling program applied to an image processing chip is executed by a processor, the aforementioned application to An exception handling method of an image processing chip.
上述计算机可读存储介质,通过前述应用于图像处理芯片的异常处理方法,可以在检测到异常信息后,不影响上层的硬件抽象层情况下,调用相应的异常处理策略快速进行对应异常的自适应恢复处理,在异常处理后将处理结果以及异常信息上报至硬件抽象层,使得上层的硬件抽象层有根据自适应处理结果以及异常信息做进一步判断和处理的能力,从而可以更好的提升系统的鲁棒性,同时减少底层的图像处理芯片发生的异常对用户使用体验的影响,提高用户满意度。The above-mentioned computer-readable storage medium, through the above-mentioned exception handling method applied to the image processing chip, can call the corresponding exception handling strategy to quickly perform adaptive adaptation to the corresponding exception after the abnormal information is detected without affecting the upper hardware abstraction layer Resume processing, and report the processing results and abnormal information to the hardware abstraction layer after exception processing, so that the upper hardware abstraction layer has the ability to make further judgments and processing according to the adaptive processing results and abnormal information, so as to better improve the performance of the system Robustness, while reducing the impact of abnormalities in the underlying image processing chip on user experience and improving user satisfaction.
需要说明的是,在流程图中表示或在此以其他方式描述的逻辑和/或步骤,例如,可以被认为是用于实现逻辑功能的可执行指令的定序列表,可以具体实现在任何计算机可读介质中,以供指令执行系统、装置或设备(如基于计算机的系统、包括处理器的系统或其他可以从指令执行系统、装置或设备取指令并执行指令的系统)使用,或结合这些指令执行系统、装置或设备而使用。就本说明书而言,"计算机可读介质"可以是任何可以包含、存储、通信、传播或传输程序以供指令执行系统、装置或设备或结合这些指令执行系统、装置或设备而使用的装置。计算机可读介质的更具体的示例(非穷尽性列表)包括以下:具有一个或多个布线的电连接部(电子装置),便携式计算机盘盒(磁装置),随机存取存储器(RAM),只读存储器(ROM),可擦除可编辑只读存储器(EPROM或闪速存储器),光纤装 置,以及便携式光盘只读存储器(CDROM)。另外,计算机可读介质甚至可以是可在其上打印所述程序的纸或其他合适的介质,因为可以例如通过对纸或其他介质进行光学扫描,接着进行编辑、解译或必要时以其他合适方式进行处理来以电子方式获得所述程序,然后将其存储在计算机存储器中。It should be noted that the logic and/or steps shown in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer readable medium for use by an instruction execution system, apparatus, or device (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, apparatus, or device and execute instructions), or in combination with these Instructions are used to execute systems, devices, or equipment. For the purposes of this specification, a "computer-readable medium" may be any device that can contain, store, communicate, propagate or transmit a program for use in or in conjunction with an instruction execution system, device or device. More specific examples (non-exhaustive list) of computer-readable media include the following: electrical connection with one or more wires (electronic device), portable computer disk case (magnetic device), random access memory (RAM), Read Only Memory (ROM), Erasable and Editable Read Only Memory (EPROM or Flash Memory), Fiber Optic Devices, and Portable Compact Disc Read Only Memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program can be printed, since the program can be read, for example, by optically scanning the paper or other medium, followed by editing, interpretation or other suitable processing if necessary. The program is processed electronically and stored in computer memory.
应当理解,本公开的各部分可以用硬件、软件、固件或它们的组合来实现。在上述实施方式中,多个步骤或方法可以用存储在存储器中且由合适的指令执行系统执行的软件或固件来实现。例如,如果用硬件来实现,和在另一实施方式中一样,可用本领域公知的下列技术中的任一项或他们的组合来实现:具有用于对数据信号实现逻辑功能的逻辑门电路的离散逻辑电路,具有合适的组合逻辑门电路的专用集成电路,可编程门阵列(PGA),现场可编程门阵列(FPGA)等。It should be understood that various parts of the present disclosure may be implemented in hardware, software, firmware or a combination thereof. In the embodiments described above, various steps or methods may be implemented by software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented by any one or combination of the following techniques known in the art: Discrete logic circuits, ASICs with suitable combinational logic gates, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本公开的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不一定指的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任何的一个或多个实施例或示例中以合适的方式结合。In the description of this specification, descriptions referring to the terms "one embodiment", "some embodiments", "example", "specific examples", or "some examples" mean that specific features described in connection with the embodiment or example , structure, material or characteristic is included in at least one embodiment or example of the present disclosure. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
此外,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。在本公开的描述中,“多个”的含义是至少两个,例如两个,三个等,除非另有明确具体的限定。In addition, the terms "first" and "second" are used for descriptive purposes only, and cannot be interpreted as indicating or implying relative importance or implicitly specifying the quantity of indicated technical features. Thus, the features defined as "first" and "second" may explicitly or implicitly include at least one of these features. In the description of the present disclosure, "plurality" means at least two, such as two, three, etc., unless otherwise specifically defined.
在本公开中,除非另有明确的规定和限定,术语“安装”、“相连”、“连接”、“固定”等术语应做广义理解,例如,可以是固定连接,也可以是可拆卸连接,或成一体;可以是机械连接,也可以是电连接;可以是直接相连,也可以通过中间媒介间接相连,可以是两个元件内部的连通或两个元件的相互作用关系,除非另有明确的限定。对于本领域的普通技术人员而言,可以根据具体情况理解上述术语在本公开中的具体含义。In this disclosure, terms such as "installation", "connection", "connection" and "fixation" should be interpreted in a broad sense, for example, it can be a fixed connection or a detachable connection unless otherwise clearly defined and limited. , or integrated; it may be mechanically connected or electrically connected; it may be directly connected or indirectly connected through an intermediary, and it may be the internal communication of two components or the interaction relationship between two components, unless otherwise specified limit. Those of ordinary skill in the art can understand the specific meanings of the above terms in the present disclosure according to specific situations.
尽管上面已经示出和描述了本公开的实施例,可以理解的是,上述实施例是示例性的,不能理解为对本公开的限制,本领域的普通技术人员在本公开的范围内可以对上述实施例进行变化、修改、替换和变型。Although the embodiments of the present disclosure have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limitations on the present disclosure, and those skilled in the art can understand the above-mentioned embodiments within the scope of the present disclosure. The embodiments are subject to changes, modifications, substitutions and variations.

Claims (16)

  1. 应用于图像处理芯片的异常处理方法,包括:An exception handling method applied to an image processing chip, including:
    获取图像输出过程中的异常信息,并根据所述异常信息确定异常类型;Obtaining abnormal information during the image output process, and determining the abnormal type according to the abnormal information;
    在对所述异常信息上报之前,根据所述异常类型控制所述图像处理芯片中的异常功能模块进行重试和/或控制所述异常功能模块切换为旁路模式,以对所述图像处理芯片进行异常自恢复处理。Before reporting the abnormal information, control the abnormal function module in the image processing chip to retry according to the abnormal type and/or control the abnormal function module to switch to a bypass mode, so as to control the image processing chip Perform exception self-recovery processing.
  2. 根据权利要求1所述的异常处理方法,其中,所述图像处理芯片包括多个功能模块,所述异常信息由各个所述功能模块自检得到。The abnormality handling method according to claim 1, wherein the image processing chip includes a plurality of functional modules, and the abnormality information is obtained by self-testing of each functional module.
  3. 根据权利要求1或2所述的异常处理方法,其中,所述异常类型包括可恢复异常和不可恢复异常,其中,根据所述异常类型控制所述图像处理芯片中的异常功能模块进行重试和/或控制所述异常功能模块切换为旁路模式,包括:The exception handling method according to claim 1 or 2, wherein the exception types include recoverable exceptions and unrecoverable exceptions, wherein the abnormal function modules in the image processing chip are controlled according to the exception types to perform retry and /or control the abnormal function module to switch to bypass mode, including:
    在所述异常类型为可恢复异常时,控制所述异常功能模块重试,以重新执行所述异常功能模块的功能;When the exception type is a recoverable exception, control the abnormal function module to retry, so as to re-execute the function of the abnormal function module;
    在所述异常类型为不可恢复异常时,控制所述异常功能模块切换为旁路模式,以使所述异常功能模块将接收到的信号直接输出。When the abnormality type is an unrecoverable abnormality, the abnormal function module is controlled to switch to a bypass mode, so that the abnormal function module directly outputs the received signal.
  4. 根据权利要求3所述的异常处理方法,其中,在控制所述异常功能模块重试之后,如果重试失败,则控制所述异常功能更模块切换为旁路模式后重试。The exception handling method according to claim 3, wherein after controlling the abnormal function module to retry, if the retry fails, then control the abnormal function module to switch to a bypass mode and then retry.
  5. 根据权利要求1所述的异常处理方法,其中,所述异常类型包括图像卡顿异常,其中,在确定所述图像输出过程中出现图像卡顿异常时,还对输出图像数据进行预判,以模拟出当前帧图像,以便在对所述异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层,以使所述硬件抽象层显示所述模拟的当期帧图像。The abnormality handling method according to claim 1, wherein the abnormality type includes an image freeze abnormality, wherein when it is determined that an image freeze abnormality occurs during the image output process, the output image data is also predicted, so as to Simulating the current frame image, so that when the exception information is restored, the simulated current frame image is sent to the hardware abstraction layer as an output frame image, so that the hardware abstraction layer displays the simulated current frame image.
  6. 根据权利要求1所述的异常处理方法,其中,所述异常类型包括内容异常,其中,在确定所述图像输出过程中出现内容异常时,还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对所述异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使所述硬件抽象层显示所述模拟的当期帧图像。The exception handling method according to claim 1, wherein the exception type includes content exception, wherein, when it is determined that a content exception occurs during the image output process, the current frame image data is also simulated according to the historical frame image data, and the The simulated current frame image data replaces the current frame image data whose content is abnormal, so that the simulated current frame image data is sent to the hardware abstraction layer as an output frame image when the abnormal information is restored, so that the hardware abstraction layer displays the current frame image of the simulation.
  7. 根据权利要求6所述的异常处理方法,其中,根据所述异常信息确定异常类型,包括:The exception handling method according to claim 6, wherein determining the exception type according to the exception information includes:
    对采集到的当前帧图像数据进行图像预处理,其中,图像预处理包括自动曝光控制、自动增益控制、自动白平衡控制、镜头校正、色彩校正、伽马校正、色彩空间转换中的至少 一种或多种;Perform image preprocessing on the collected current frame image data, wherein the image preprocessing includes at least one of automatic exposure control, automatic gain control, automatic white balance control, lens correction, color correction, gamma correction, and color space conversion or more;
    确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的图像参数的差异信息;Determine the difference information of image parameters between the processed current frame image data and the pre-processed current frame image data;
    根据所述差异信息确定所述异常类型是内容异常。It is determined according to the difference information that the exception type is content exception.
  8. 图像处理芯片,包括:Image processing chips, including:
    异常检测模块,用于获取图像输出过程中的异常信息,并根据所述异常信息确定异常类型;An abnormality detection module, configured to obtain abnormality information during the image output process, and determine an abnormality type according to the abnormality information;
    异常处理模块,在对所述异常信息上报之前,根据所述异常类型控制所述图像处理芯片中的异常功能模块进行重试和/或控制所述异常功能模块切换为旁路模式,以对所述图像处理芯片进行异常自恢复处理。The exception processing module, before reporting the exception information, controls the abnormal function module in the image processing chip to retry according to the exception type and/or controls the abnormal function module to switch to a bypass mode, so as to The above image processing chip performs abnormal self-recovery processing.
  9. 根据权利要求8所述的图像处理芯片,其中,所述图像处理芯片包括多个功能模块,所述异常信息由各个所述功能模块自检得到。The image processing chip according to claim 8, wherein the image processing chip includes a plurality of functional modules, and the abnormality information is obtained by self-testing of each of the functional modules.
  10. 根据权利要求8或9所述的图像处理芯片,其中,所述异常类型包括可恢复异常和不可恢复异常;The image processing chip according to claim 8 or 9, wherein the exception types include recoverable exceptions and unrecoverable exceptions;
    在所述异常类型为可恢复异常时,所述异常处理模块具体用于控制所述异常功能模块重试,以重新执行所述异常功能模块的功能;When the exception type is a recoverable exception, the exception handling module is specifically used to control the retry of the exception function module to re-execute the function of the exception function module;
    在所述异常类型为不可恢复异常时,所述异常处理模块具体用于控制所述异常功能模块切换为旁路模式,以使所述异常功能模块将接收到的信号直接输出。When the exception type is an unrecoverable exception, the exception handling module is specifically configured to control the exception function module to switch to a bypass mode, so that the exception function module directly outputs the received signal.
  11. 根据权利要求10所述的图像处理芯片,其中,所述异常处理模块还用于在控制所述异常功能模块重试之后,如果重试失败,则控制所述异常功能模块切换为旁路模式后重试。The image processing chip according to claim 10, wherein the abnormality processing module is further configured to, after controlling the abnormal function module to retry, if the retry fails, control the abnormal function module to switch to the bypass mode Retry.
  12. 根据权利要求8所述的图像处理芯片,其中,所述异常类型包括图像卡顿异常;The image processing chip according to claim 8, wherein the abnormal type includes an abnormal image freeze;
    所述异常检测模块在确定图像输出过程中出现图像卡顿异常时,所述异常处理模块还对输出图像数据进行预判,以模拟出当前帧图像,以便在对所述异常信息进行恢复处理时将模拟的当前帧图像作为输出帧图像发送到硬件抽象层。When the abnormality detection module determines that the image freezes abnormally during the image output process, the abnormality processing module also predicts the output image data to simulate the current frame image, so that when the abnormal information is restored Send the simulated current frame image to the hardware abstraction layer as the output frame image.
  13. 根据权利要求8所述的图像处理芯片,其中,所述异常类型包括内容异常;The image processing chip according to claim 8, wherein the exception type includes content exception;
    所述异常检测模块在确定所述图像输出过程中出现内容异常时,所述异常处理模块还根据历史帧图像数据模拟出当前帧图像数据,将模拟的当前帧图像数据替换发生内容异常的当前帧图像数据,以便在对所述异常信息进行恢复处理时将模拟的当前帧图像数据作为输出帧图像发送到硬件抽象层,以使所述硬件抽检层显示所述模拟的当期帧图像。When the abnormality detection module determines that the content is abnormal during the image output process, the abnormality processing module also simulates the current frame image data according to the historical frame image data, and replaces the current frame with the abnormal content by the simulated current frame image data Image data, so that the simulated current frame image data is sent to the hardware abstraction layer as an output frame image when restoring the abnormal information, so that the hardware sampling layer displays the simulated current frame image.
  14. 根据权利要求13所述的图像处理芯片,其中,所述异常检测模块具体用于:The image processing chip according to claim 13, wherein the abnormality detection module is specifically used for:
    对采集到的当前帧图像数据进行图像预处理,其中,图像预处理包括自动曝光控制、自 动增益控制、自动白平衡控制、镜头校正、色彩校正、伽马校正、色彩空间转换中的至少一种或多种;Perform image preprocessing on the collected current frame image data, wherein the image preprocessing includes at least one of automatic exposure control, automatic gain control, automatic white balance control, lens correction, color correction, gamma correction, and color space conversion or more;
    确定处理后的当前帧图像数据和处理前的当前帧图像数据之间的图像参数的差异信息;Determine the difference information of image parameters between the processed current frame image data and the pre-processed current frame image data;
    根据所述差异信息确定所述异常类型是内容异常。It is determined according to the difference information that the exception type is content exception.
  15. 电子设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的应用于图像处理芯片的异常处理程序,所述处理器执行所述应用于图像处理芯片的异常处理程序时,实现如权利要求1-7中任一项所述的应用于图像处理芯片的异常处理方法。The electronic equipment includes a memory, a processor, and an exception handling program applied to an image processing chip stored on the memory and operable on the processor. When the processor executes the exception handling program applied to the image processing chip, the The exception handling method applied to an image processing chip according to any one of claims 1-7.
  16. 计算机可读存储介质,其上存储有应用于图像处理芯片的异常处理程序,该应用于图像处理芯片的异常处理程序被处理器执行时,实现如权利要求1-7中任一项所述的应用于图像处理芯片的异常处理方法。A computer-readable storage medium, on which an exception handling program applied to an image processing chip is stored, and when the exception handling program applied to an image processing chip is executed by a processor, the method described in any one of claims 1-7 is realized. An exception handling method applied to an image processing chip.
PCT/CN2022/089014 2021-06-01 2022-04-25 Image processing chip, and abnormality processing method applied to image processing chip WO2022252877A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110610683.2A CN115442586A (en) 2021-06-01 2021-06-01 Image processing chip and exception handling method applied to image processing chip
CN202110610683.2 2021-06-01

Publications (1)

Publication Number Publication Date
WO2022252877A1 true WO2022252877A1 (en) 2022-12-08

Family

ID=84272054

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/089014 WO2022252877A1 (en) 2021-06-01 2022-04-25 Image processing chip, and abnormality processing method applied to image processing chip

Country Status (2)

Country Link
CN (1) CN115442586A (en)
WO (1) WO2022252877A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11954913B2 (en) * 2022-08-01 2024-04-09 GM Global Technology Operations LLC System and method for vision-based vehicle fluid leak detection
CN115665714B (en) * 2022-11-18 2023-04-07 深圳市汇顶科技股份有限公司 Near field communication method and device, master control equipment, NFC chip and NFC equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050213118A1 (en) * 2004-03-25 2005-09-29 Fuji Photo Film Co., Ltd. Image data converter, image data conversion program storage medium, and image output system
CN101563914A (en) * 2006-11-28 2009-10-21 日本电气株式会社 Moving image pickup apparatus with zooming function, image processing, displaying method and program
CN106231204A (en) * 2016-08-30 2016-12-14 宇龙计算机通信科技(深圳)有限公司 Stabilization photographic method based on dual camera and device, terminal
CN107155012A (en) * 2016-03-02 2017-09-12 富士施乐株式会社 Image forming apparatus, image formation system and image forming method
CN111629122A (en) * 2020-04-24 2020-09-04 广州视源电子科技股份有限公司 Video data abnormity recovery method and device, storage medium and camera
CN112135081A (en) * 2020-09-11 2020-12-25 Oppo广东移动通信有限公司 Mode control method and device, frame insertion chip and electronic equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050213118A1 (en) * 2004-03-25 2005-09-29 Fuji Photo Film Co., Ltd. Image data converter, image data conversion program storage medium, and image output system
CN101563914A (en) * 2006-11-28 2009-10-21 日本电气株式会社 Moving image pickup apparatus with zooming function, image processing, displaying method and program
CN107155012A (en) * 2016-03-02 2017-09-12 富士施乐株式会社 Image forming apparatus, image formation system and image forming method
CN106231204A (en) * 2016-08-30 2016-12-14 宇龙计算机通信科技(深圳)有限公司 Stabilization photographic method based on dual camera and device, terminal
CN111629122A (en) * 2020-04-24 2020-09-04 广州视源电子科技股份有限公司 Video data abnormity recovery method and device, storage medium and camera
CN112135081A (en) * 2020-09-11 2020-12-25 Oppo广东移动通信有限公司 Mode control method and device, frame insertion chip and electronic equipment

Also Published As

Publication number Publication date
CN115442586A (en) 2022-12-06

Similar Documents

Publication Publication Date Title
WO2022252877A1 (en) Image processing chip, and abnormality processing method applied to image processing chip
WO2021042816A1 (en) Method and device for detecting fault in monitoring apparatus
EP2273450B1 (en) Target tracking and detecting in images
US20060245643A1 (en) Method and apparatus for incorporating iris color in red-eye correction
JP5201203B2 (en) Image processing apparatus, image processing method, and program
JP2009171318A (en) Image processor, image processing method, and imaging device
US20190230269A1 (en) Monitoring camera, method of controlling monitoring camera, and non-transitory computer-readable storage medium
CN103716535A (en) Method for switching photographing mode, and electronic device
CN108933903B (en) Camera fault processing method, intelligent terminal and device with storage function
CN101277385A (en) Method and apparatus to detect a dead pixel of an image sensor and method and apparatus to capture an image from an image sensor
US20200355627A1 (en) Method for detecting display screen peripheral circuit, apparatus, electronic device and storage medium
CN110264473B (en) Image processing method and device based on multi-frame image and electronic equipment
KR20200080402A (en) System and method for detecting abnormal situation
JP2004157979A (en) Image motion detection apparatus and computer program
CN112217999B (en) Wide dynamic mode adjusting method and device, electronic equipment and storage medium
JP2008015860A (en) Image recognition camera
JP2008017259A (en) Image recognition camera
US20220159166A1 (en) Method to dynamically adjust display to enhance ambient lighting in a video conference and system therefor
US20140211979A1 (en) Image processing apparatus and method thereof
CN111080544B (en) Face distortion correction method and device based on image and electronic equipment
US10972676B2 (en) Image processing method and electronic device capable of optimizing hdr image by using depth information
US10965858B2 (en) Image processing apparatus, control method thereof, and non-transitory computer-readable storage medium for detecting moving object in captured image
CN112181760B (en) Abnormality detection method and device
US10853685B2 (en) Method and apparatus for detecting fog from image
JP2002152432A (en) Picture processor and control thereof

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22814924

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE