CN110060196A - Image processing method and device - Google Patents

Image processing method and device Download PDF

Info

Publication number
CN110060196A
CN110060196A CN201910194700.1A CN201910194700A CN110060196A CN 110060196 A CN110060196 A CN 110060196A CN 201910194700 A CN201910194700 A CN 201910194700A CN 110060196 A CN110060196 A CN 110060196A
Authority
CN
China
Prior art keywords
image
control instruction
processing
data
instruction
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
CN201910194700.1A
Other languages
Chinese (zh)
Other versions
CN110060196B (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.)
Aixin Yuanzhi Semiconductor Ningbo Co ltd
Original Assignee
Beijing Megvii Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Megvii Technology Co Ltd filed Critical Beijing Megvii Technology Co Ltd
Priority to CN201910194700.1A priority Critical patent/CN110060196B/en
Publication of CN110060196A publication Critical patent/CN110060196A/en
Application granted granted Critical
Publication of CN110060196B publication Critical patent/CN110060196B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/20Processor architectures; Processor configuration, e.g. pipelining
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T1/00General purpose image data processing
    • G06T1/60Memory management
    • G06T3/04
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformation in the plane of the image
    • G06T3/40Scaling the whole image or part thereof
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2200/00Indexing scheme for image data processing or generation, in general
    • G06T2200/28Indexing scheme for image data processing or generation, in general involving image processing hardware

Abstract

The present embodiments relate to field of image processing, a kind of image processing method and device are provided.Image processing method includes: to receive the process instruction for being directed to multiple batches of original image stored in memory, and wherein process instruction includes scalability information;Control instruction is generated according to the process instruction received, control instruction includes reading control instruction, handling control instruction and write back control instruction;The original image of the present lot in multiple batches of original image is read according to reading control instruction;The original image of present lot is handled according to processing control instruction, obtains processed image;Processed image is write back in memory according to control instruction is write back, wherein after the original image to present lot has executed image reading step, image reading step reads the original image of the next batch in multiple batches of original image.Through the embodiment of the present invention, image procossing delay can be reduced.

Description

Image processing method and device
Technical field
The present embodiments relate to field of image processing more particularly to a kind of image processing methods and device.
Background technique
Image scaling/mirror transformation is image procossing, the basic algorithm of field of image recognition.Low delay, efficient figure As scaling/mirror algorithm can be obviously improved video procession system performance.
Image Zooming Algorithm is generally realized by CPU at present, and processing speed is very slow.Especially batch scaling/mirror image The burden of the occasion of picture, CPU is very heavy.
Summary of the invention
A kind of image processing method and device provided in an embodiment of the present invention reduce image to improve image processing speed Processing delay.
In a first aspect, the image processing method includes: that processing refers to the embodiment of the invention provides a kind of image processing method Receiving step is enabled, receives the process instruction for the multiple batches of original image prestored, wherein process instruction includes scalability information;Control System instruction generation step generates control instruction according to the process instruction received, and control instruction includes reading control instruction, processing Control instruction and write back control instruction;Image reading step reads the multiple batches of original image prestored according to control instruction is read In present lot original image;Image processing step is carried out according to original image of the processing control instruction to present lot Processing, obtains processed image;Image writes back step, preset according to writing back control instruction for processed image and writing back to In memory, wherein after the original image to present lot has executed image reading step, image reading step reads pre- The next original image in multiple batches of original image deposited.
In one example, image reading step includes: and receives to read control instruction;According to control instruction is read, read current Scaled data relevant to scaling in the raw image data of batch.
In another example, image processing step includes image scaling step, and processing control instruction includes zoom control instruction, Image scaling step includes: to receive zoom control instruction;It is instructed according to zoom control, obtains the raw image data of present lot In scaled data relevant to scaling;According to the scaled data of acquisition, the original of scaling present lot is instructed according to zoom control Image obtains the image of scaled processing;Export the image of scaled processing.
In another example, image processing step further includes image mirrors step, and processing control instruction further includes mirror image control Instruction, image mirrors step include: according to mirror image control instruction, mirror image processing is carried out to the image of scaled processing and at the same time The image for caching scaled processing obtains the image after mirror image processing;Export the image after mirror image processing.
In one example, according to mirror image control instruction, mirror image processing is carried out to the image of scaled processing, is obtained through at mirror image Image after reason includes: to receive mirror image control instruction;According to mirror image control instruction, receive every in the image data of scaled processing The row data of every a line of a image;Mirror is carried out to the row data of every a line of each image in the image data of scaled processing As processing, mirror image row data are obtained.
In another example, exporting the image of the image and output of scaled processing after mirror image processing includes: to input and delay The row data for depositing every a line, according to preset output data quantity bit wide, export caching when Current Datarow is input to half Current Datarow;After the completion of Current Datarow output, enter the mirror image row data that the mode first gone out exports Current Datarow later.
In another example, preset output data quantity bit wide is 2 times of input data amount bit wide.
In one example, it includes: that reception writes back control instruction that image, which writes back step,;According to control instruction is write back, receive through contracting Put the image of processing;The image of scaled processing based on the received writes back to the image of scaled processing in memory.
In another example, image writes back step further include: reception writes back control instruction;According to control instruction is write back, receive The image of scaled processing and the image after mirror image processing;The image of scaled processing and after mirror image processing based on the received Image, the image of scaled processing and the image after mirror image processing are write back in memory.
Second aspect, the embodiment of the invention provides a kind of image processing apparatus, which includes: that processing refers to Receiving unit is enabled, receives the process instruction for the multiple batches of original image prestored, wherein process instruction includes scalability information;Control Instruction generation unit processed generates control instruction according to the process instruction received, and control instruction includes reading control instruction, processing Control instruction and write back control instruction;Image reading unit reads the multiple batches of original image prestored according to control instruction is read In present lot original image;Image processing unit is carried out according to original image of the processing control instruction to present lot Processing, obtains processed image;Processed image is write back to memory according to control instruction is write back by image writeback unit In, wherein after the original image to present lot has executed image reading unit, image reading unit is read from memory Next original image in multiple batches of original image, wherein image reading unit is executed in the original image to present lot After complete image reading, image reading unit reads the original image of the next batch in the multiple batches of original image prestored.
In one example, image reading unit is used for: being received and is read control instruction;According to control instruction is read, read current Scaled data relevant to scaling in the raw image data of batch.
In one example, image processing unit is used for image scaling, and processing control instruction includes that zoom control instructs, at image Reason unit is used for: receiving zoom control instruction;Instructed according to zoom control, obtain in the raw image data of present lot with contracting Put relevant scaled data;According to the scaled data of acquisition, the original image of scaling present lot is instructed according to zoom control, is obtained To the image of scaled processing;Export the image of scaled processing.
In one example, image processing unit is also used to image mirrors, and processing control instruction further includes mirror image control instruction, figure As processing unit is used for:
According to mirror image control instruction, mirror image processing is carried out and at the same time caching scaled processing to the image of scaled processing Image, obtain the image after mirror image processing;Export the image after mirror image processing.
In one example, image processing unit is according to the mirror image control instruction, in the following way to the scaled place The image of reason carries out mirror image processing, obtains the image after mirror image processing: receiving mirror image control instruction;Referred to according to mirror image control It enables, receives the row data of every a line of each image in the image data of scaled processing;To the image data of scaled processing In each image every a line row data carry out mirror image processing, obtain mirror image row data.
In one example, image processing unit exports in the following way obtains the image of scaled processing and through mirror image processing Image afterwards: inputting and caches the row data of every a line, when Current Datarow is input to half, according to preset output data Bit wide is measured, the Current Datarow of caching is exported;After the completion of Current Datarow output, enters the mode first gone out later and export current line The mirror image row data of data.
In one example, preset output data quantity bit wide is 2 times of input data amount bit wide.
In one example, image writeback unit is used for: reception writes back control instruction;According to control instruction is write back, receive through contracting Put the image of processing;The image of scaled processing is write back in memory.
In one example, image writeback unit is also used to: reception writes back control instruction;According to control instruction is write back, warp is received The image of scaling processing and the image after mirror image processing;The image of scaled processing and the image after mirror image processing are write back Into memory.
The third aspect, the embodiment of the present invention also provide a kind of electronic equipment, wherein electronic equipment includes: memory, is used for Store instruction;And processor, the figure in the current aspect of the instruction execution present invention and its each example for calling memory storage As processing method.
Fourth aspect, the embodiment of the present invention also provide a kind of computer readable storage medium, the computer-readable storage medium Matter is stored with computer executable instructions, when computer executable instructions are run on computers, executes the current aspect of the present invention And its image processing method in each example.
Image processing method and device provided in an embodiment of the present invention, it is raw by receiving the process instruction of multiple batches of image At control instruction, and according to control instruction, can flowing water control reading, processing and the write back step of each batch image, realize Image procossing height handles up, low delay, significant increase image processing speed.
Detailed description of the invention
Fig. 1 is a kind of electronic equipment schematic diagram provided in an embodiment of the present invention;
Fig. 2 is image processing method implementation flow chart provided in an embodiment of the present invention;
Fig. 3 is a kind of image processing apparatus schematic diagram provided in an embodiment of the present invention;
Fig. 4 is another image processing apparatus schematic diagram provided in an embodiment of the present invention.
Specific embodiment
The principle and spirit of the invention are described below with reference to several illustrative embodiments.It should be appreciated that providing this A little embodiments are used for the purpose of making those skilled in the art can better understand that realizing the present invention in turn, and be not with any Mode limits the scope of the invention.
The method and device of image procossing provided in an embodiment of the present invention can be applied to that image need to be zoomed in and out and/mirror The application scenarios of picture.In this scenario, be related to the electronic equipment of image procossing, the electronic equipment can be video camera, capture machine, The intelligent terminals such as smart phone, tablet computer, computer.
Fig. 1 show a kind of electronic equipment 100 provided by the embodiment of the present invention, wherein the electronic equipment 100 includes depositing Reservoir 101, processor 102, input/output (Input/Output, I/O) interface 103.Wherein, memory 101, for storing Instruction.Processor 102, the image processing method of the instruction execution embodiment of the present invention for calling memory 101 to store.Its In, processor 102 is connect with memory 101, I/O interface 101 respectively, such as can pass through bus system and/or other forms Bindiny mechanism's (not shown) is attached.Memory 101 can be used for storing program and data, including involved in the embodiment of the present invention Image real time transfer program and/or image data analyzing program, processor 102 by operation is stored in memory 101 Program thereby executing electronic equipment 100 various function application and data processing.
Processor 102 can for example use digital signal processor (Digital Signal in the embodiment of the present invention Processing, DSP), it is field programmable gate array (Field-Programmable Gate Array, FPGA), programmable At least one of logic array (Programmable Logic Array, PLA) example, in hardware realizes that processor 102 can To be central processing unit (Central Processing Unit, CPU) or there is data-handling capacity and/or instruction to hold The combination of one or more of the processing unit of other forms of row ability.
Possible embodiment, in the embodiment of the present invention, processor 102 can be the combination of CPU and FPGA.
Memory 101 in the embodiment of the present invention may include one or more computer program products, the computer Program product may include various forms of computer readable storage mediums, such as volatile memory and/or non-volatile deposit Reservoir.The volatile memory for example may include random access memory (Random Access Memory, RAM) and/ Or cache memory (cache) etc..The nonvolatile memory for example may include read-only memory (Read-Only Memory, ROM), flash memory (flash memory), hard disk (hard disk drive, HDD) or solid state hard disk (solid-state drive, SSD) etc..
In the embodiment of the present invention, I/O interface 101 can be used for receiving input instruction (such as number or character information, and Generate key signals input related with the user setting of electronic equipment 100 and function control etc.), it can also be output to the outside various Information (for example, image or sound etc.).In the embodiment of the present invention I/O interface 101 may include physical keyboard, function button (such as Volume control button, switch key etc.), mouse, operating stick, trace ball, microphone, one in loudspeaker and touch panel etc. It is a or multiple.
The embodiment of the present invention also provides a kind of computer readable storage medium, is stored with instruction, and the instruction is by processor When execution, it can be achieved that the present embodiments relate to image processing method.
Currently, electronic equipment 100 gets the process instruction of multiple batches of original image during carrying out picture processing Afterwards, it needing to the complete after treatment of every batch of original image, then carries out the processing of next group image, processing speed is very slow, and It is very heavy to handle load.
In view of this, the embodiment of the present invention provides a kind of image processing method, it in the method, can for multiple batches of image By control instruction, reading, processing and the write back step of flowing water control image can be promoted at image through the embodiment of the present invention Speed is managed, the number for calling processor is reduced, liberates the processing load of processor.
Fig. 2 show a kind of image processing method implementation flow chart provided in an embodiment of the present invention.Method shown in Fig. 2 is held Row main body can be electronic equipment 100, some component being also possible in electronic equipment 100, it is of course possible to be that other can be real The executing subject of existing corresponding function, the embodiment of the present invention is without limitation.As shown in fig.2, this method comprises:
S201: process instruction receiving step receives the process instruction for the multiple batches of original image prestored, wherein handling Instruction includes scalability information.
Original image involved in the embodiment of the present invention can be understood as the image for needing to carry out image procossing.Such as it can It is multiple batches of in the embodiment of the present invention to be that the image that zooms in and out is needed either to need to zoom in and out and the image of mirror image Memory, the image stored in memory can be for example written in original image by central processing unit.
As possible embodiment, in the embodiment of the present invention, processor can receive that central processing unit issues for more The process instruction of batch image, the process instruction of every a collection of image, can be identical process instruction in the process instruction, at this Reason instruction may include the processing information that each batch image needs to do, such as can be the scaling multiple letter of each batch image Breath, the mirror image processing information of each batch image.
S202: control instruction generation step generates control instruction according to the process instruction received, and control instruction includes reading Control instruction is taken, control instruction is handled and writes back control instruction.
In the embodiment of the present invention, control instruction can be generated, as a kind of possibility according to the process instruction to batch images Embodiment, in the embodiment of the present invention, the control instruction of generation can be multiple control instructions, pass through multiple controls of generation Instruction controls the processing step of each batch image.It as a kind of possible embodiment, can be according to connecing in the embodiment of the present invention The process instruction received, which generates, to be read control instruction, handles control instruction and write back control instruction.
Specifically, the processing information that may include in control instruction to original image stored in memory, example are read It such as can be the scaling information for original image stored in memory, handling, which may include in control instruction, is directed to The specific scaling of original image calculates or mirror image calculates, and writing back control instruction may include received that treated that image is defeated Out and it is written back to memory.
S203: image reading step reads currently criticizing in the multiple batches of original image prestored according to control instruction is read Secondary original image.
In the embodiment of the present invention, multiple batches of original image can store tabular form sequential storage in memory, needle Identical image processing operations can be carried out to every a batch of original image, such as all put for a batch of original image Big 2 times or all be reduce 3 times.The embodiment of the present invention for convenience of description, referred to as work as by the batch original image that will be currently read Preceding batch original image in the embodiment of the present invention, can read the original of present lot according to control instruction is read from memory The data information of image in the embodiment of the present invention, such as can be read in the original image of present lot according to control instruction is read Scaled data relevant to scaling, scaling information including image and the data row information for needing to do scaling processing, and Scaled data relevant to scaling in the raw image data of the present lot read is taken out from memory, and is cached. In the embodiment of the present invention, such as when the processor of executing subject 100 is the combination of CPU and FPGA, FPGA can read CPU write and enter Original image information in memory, by scaled data relevant to scaling in the raw image data of the present lot read It is cached in the storage unit inside FPGA.
Further, it such as when image needs to amplify, since each row of data of image requires to amplify, is controlled according to reading System instruction, can be read the magnification ratio information of image, and by the storage list inside the magnification ratio information cache to FPGA of image In member.When image needs to reduce, to accelerate reading efficiency to reduce the consumption to memory bandwidth simultaneously, can refer to according to control is read The data line for needing to reduce in the percent information and image that obtain image down is enabled, and according to the percent information of image down It with the data line for needing to reduce in image, slips a line reading to raw image data, only extracts the data line for needing to reduce, and will The diminution information data for the data line for needing to reduce is taken out from memory, is cached in the storage unit inside FPGA.
S204: image processing step, according to processing control instruction the original image of present lot is handled, obtain through The image of processing.
In the embodiment of the present invention, processing can be zoomed in and out to the original image of present lot according to processing control instruction, Or scaling processing and mirror image processing can be done to the original image of present lot.
When handling control instruction is that zoom control instructs, the raw image data for obtaining storage is instructed according to zoom control In scaled data relevant to scaling, and according to zoom control instruction and raw image data in scaling number relevant to scaling According to scaling the data line for needing to scale in the original image of present lot, obtain the image of scaled processing, and by scaled place The image of reason exports.
Specifically, if the magnification ratio of raw image data is got according to zoom control instruction, according to original image The magnification ratio of data amplifies each row of data of present lot original image, and exports amplified image.If root According to the data row information that zoom control instruction gets the diminution ratio of original image and needs to reduce, according to the original graph of acquisition The diminution ratio of picture and the data row information for needing to reduce, contract to the data line for needing to reduce in present lot original image It is small, and export the image after reducing.
When handling control instruction includes zoom control instruction and mirror image control instruction, is obtained and deposited according to zoom control instruction Scaled data relevant to scaling in the raw image data of storage, according to zoom control instruction and raw image data in scaling Relevant scaled data first scales the original image of present lot, the image by scaling processing is obtained, then according to mirror image control System instruction carries out mirror image processing to the image Jing Guo scaling processing, and caches the image Jing Guo scaling processing simultaneously, and then To the image after mirror image processing.
Specifically, according to mirror image control instruction, mirror image processing is carried out to the image of scaled processing, is obtained through mirror image processing Image afterwards can be used such as under type: when carrying out mirror image processing to the image of scaled processing, according to mirror image control instruction, connect The row data for receiving every a line of each image in the image data of scaled processing carry out mirror to the row data of received every a line As processing, mirror image row data are obtained.
Further, when exporting the image after mirror image processing of image and output of scaled processing, for example, can be used as Under type: input in the image data of scaled processing the row data of every a line of each image and to the row data of every a line into Row caching, when Current Datarow is input to half, according to preset output data quantity bit wide, exports the current line number of caching According to, and after the completion of Current Datarow output, enter the mirror image row data that the mode first gone out exports Current Datarow later.
Possible embodiment, in the embodiment of the present invention, to reduce output delay, and when hiding the output of mirror image row data Between, output data quantity bit wide can be set as to 2 times of input data amount bit wide.
Wherein, output data quantity refers to that the row data of output or mirror image row data, input data amount refer to the line number of input According to.
It is understood that realize the output time for hiding mirror image row data, output data quantity bit wide should be greater than inputting Data volume bit wide, the embodiment of the present invention is according to the actual demand of output data, such as output data quantity bit wide can be set as 3 times of input data amount bit wide, or output data quantity bit wide is set greater than to other multiples of input data amount bit wide, this Inventive embodiments are it is not limited here.
The data for inputting scaled processing and the data for exporting scaled processing and the example such as table 1 after mirror image processing It is shown.
Table 1
In table 1, the first row represents the data for inputting scaled processing, i.e. line of input data, and the second row represents output warp The data of scaling processing and the data after mirror image processing, i.e., the mirror image data of defeated trip data and defeated trip data.Wherein, defeated Data inward includes A line data, B line data and C line data, and A1, A2 ... An are indicated in the A line data of input Data, B1, B2 ... Bn indicate the data in the B line data of input, and C1, C2 ... Cn indicate the number in the C line data of input According to.The NA of second row represents A1 currently without output, in the second row and A2, An-1 and An ... B1 and B2 in table 1, Bn-2 and The data that Bn-3 ... is respectively represented while being exported.And the mirror image data of the row data and defeated trip data that are exported in the second row, It is according to after first defeated trip data, then the sequence of mirror image data of defeated trip data is exported.
Specifically, when inputting the A1 in A line data, the mirror image data An of A1 is obtained, input A2 obtains the mirror image number of A2 It is 2 times of input data amount bit wide according to preset output data quantity bit wide when A line data is input to half according to An-1, The A line data of output caching since An/2+1, i.e., export the A1 and A2 ... in A line data simultaneously, and so on, work as A When line data is input to An, the An-1 and An in A line data are exported, after the completion of the output of A line data, enters first to go out later Mode export the mirror image row data of A line data, i.e., as the B1 inputted in B line data, export A line data A1 and A2 Mirror image data An and An-1, thus as shown in table 1, can by export mirror image row data time be hidden in line of input data when Between in.
S205: image writes back step, writes back to processed image in memory according to control instruction is write back.
In the embodiment of the present invention, the image of the scaled image of input or the scaled and mirror image of input can be led to Output module is crossed, memory headroom is written back to.In possible embodiment, in order to realize that the image write back in memory can be successively Arrangement, to facilitate image detection, when identification, does the processing of batch, and the ground for exporting image can configure in writing back control instruction Location space is written back to the corresponding address space of memory according to the address space of configuration.
Image processing method provided in an embodiment of the present invention receives multiple batches of original image process instruction, and according to reception Process instruction generate control instruction can be reduced by the control instruction batch processing original image of generation to central processing unit Frequency of use, liberate the operational capability of central processing unit.And by generate control instruction can multiple processing steps it Between pipeline every batch of image data, mitigate the delay of processor image procossing, significant increase image processing speed.
Based on identical inventive concept, the embodiment of the present invention also provides a kind of image processing apparatus.
It is understood that image processing apparatus provided in an embodiment of the present invention is in order to realize the above functions, it comprises Execute the corresponding hardware configuration of each function and/or software module.Each exemplary list in conjunction with disclosed in the embodiment of the present invention Member and algorithm steps, the embodiment of the present invention can be realized with the combining form of hardware or hardware and computer software.Some function It can be executed in a manner of hardware or computer software driving hardware actually, the specific application and design depending on technical solution Constraint condition.Those skilled in the art can realize described function using different methods to each specific application Can, but this realization is it is not considered that exceed the range of the technical solution of the embodiment of the present invention.
The embodiment of the present invention can carry out the division of functional unit, example according to above method embodiment to image processing apparatus Such as, each functional unit of each function division can be corresponded to, two or more functions can also be integrated at one It manages in unit.Above-mentioned integrated unit both can take the form of hardware realization, can also be in the form of software functional units It realizes.It should be noted that being schematical, only a kind of logic function stroke to the division of unit in the embodiment of the present invention Point, there may be another division manner in actual implementation.
Using integrated unit, image processing apparatus provided in an embodiment of the present invention may include process instruction Receiving unit, control instruction generation unit, image reading unit, image processing unit and image writeback unit.Fig. 3 is the present invention A kind of structural schematic diagram for image processing apparatus 300 that embodiment provides, the image processing apparatus 300 can be applied to above-mentioned relate to And electronic equipment 100.As shown in fig.3, the image processing apparatus may include process instruction receiving unit 301, control instruction Generation unit 302, image reading unit 303, image processing unit 304 and image writeback unit 305.Wherein, process instruction connects Unit 301 is received, for receiving the process instruction for being directed to the multiple batches of original image prestored, wherein process instruction includes scaling letter Breath;Control instruction generation unit 302, for generating control instruction according to the process instruction received, control instruction includes reading Control instruction handles control instruction and writes back control instruction;Image reading unit 303, for being read according to reading control instruction The original image of the present lot in multiple batches of original image prestored;Image processing unit 304, for being referred to according to processing control Order handles the original image of present lot, obtains processed image;Image writeback unit 305 writes back for basis Control instruction writes back to processed image in memory, wherein image reading unit 303 is in the original graph to present lot As after having executed image reading step, image reading unit 303 reads next original in the multiple batches of original image prestored Beginning image.
In one embodiment, image reading unit 303 is used for: being received and is read control instruction;According to control instruction is read, read Take scaled data relevant to scaling in the raw image data of present lot.
In one embodiment, image processing unit 304 is used for image scaling, and processing control instruction includes that zoom control refers to It enables, image processing unit 304 is used for: receiving zoom control instruction;It is instructed according to zoom control, obtains the original graph of present lot As scaled data relevant to scaling in data;According to the scaled data of acquisition, scaling present lot is instructed according to zoom control Original image, obtain the image of scaled processing;Export the image of scaled processing.
In one embodiment, image processing unit 304 is also used to image mirrors, and processing control instruction further includes mirror image control Instruction, image processing unit 304 is used for: according to mirror image control instruction, to the image of scaled processing carry out mirror image processing and The image for caching scaled processing simultaneously, obtains the image after mirror image processing;Export the obtained image after mirror image processing.
In one embodiment, image processing unit 304 is according to mirror image control instruction, in the following way to scaled processing Image carry out mirror image processing, obtain the image after mirror image processing: receiving mirror image control instruction;According to mirror image control instruction, Receive the row data of every a line of each image in the image data of scaled processing;To every in the image data of scaled processing The row data of every a line of a image carry out mirror image processing, obtain mirror image row data.
In one embodiment, image processing unit 304 exports obtain the image and warp of scaled processing in the following way Image after mirror image processing: inputting and caches the row data of every a line, when Current Datarow is input to half, according to preset Output data quantity bit wide exports the Current Datarow of caching;After the completion of Current Datarow output, it is defeated to enter the mode first gone out later The mirror image row data of Current Datarow out.
In one embodiment, preset output data quantity bit wide is 2 times of input data amount bit wide.
In one embodiment, image writeback unit 305 is used for: reception writes back control instruction;According to control instruction is write back, connect Receive the image of scaled processing;The image of scaled processing is write back in memory.
In one embodiment, image writeback unit 305 is also used to: reception writes back control instruction;According to writing back control instruction, Receive the image of scaled processing and the image after mirror image processing;By the image of scaled processing and the figure after mirror image processing As writing back in memory.
Based on identical inventive concept, the embodiment of the invention also provides another image processing apparatus.The image procossing On the basis of device image processing apparatus shown in Fig. 3, central processing unit and internal storage location are increased.Fig. 4 is that the present invention is real A kind of structural schematic diagram of image processing apparatus 400 of example offer is applied, which can be applied to above-mentioned be related to Electronic equipment 100.As shown in fig.4, the image processing apparatus may include central processing unit 401, process instruction receives single Member 402, image reading unit 404, image processing unit 405, image writeback unit 406 and is deposited at control instruction generation unit 403 Storage unit 407.
At process instruction receiving unit 402, control instruction generation unit 403, image reading unit 404, image in Fig. 4 Manage unit 405, image writeback unit 406 respectively with the process instruction receiving unit 301 in Fig. 3, control instruction generation unit 302, image reading unit 303, image processing unit 304 is identical with the function of being realized of image writeback unit 305, specific The function of realization refers to the description of corresponding unit in Fig. 3, and details are not described herein.
Wherein, the central processing unit 401 in Fig. 4 is used to issue the process instruction of the multiple batches of original image prestored everywhere Instruction receiving unit 402 is managed, and by multiple batches of original image write storage unit 407;Storage unit 407, for storing more batches The processed image of secondary original image and storage through 406 write-back of image write back unit.
In one embodiment, the embodiment of the present invention also provides a kind of electronic equipment, wherein and electronic equipment includes: memory, For storing instruction;And processor, for calling in the instruction execution of memory storage currently aspect of the invention and its each example Image processing method.
In one embodiment, the embodiment of the present invention also provides a kind of computer readable storage medium, this is computer-readable to deposit Storage media is stored with computer executable instructions, and when computer executable instructions are run on computers, it is current to execute the present invention Image processing method in aspect and its each example.
Although, should not be by it is understood that described in a particular order in the accompanying drawings in the embodiment of the present invention Particular order or serial order shown in are understood as require that execute these, or is required to execute shown in whole to obtain To desired result.In specific environment, multitask and parallel processing may be advantageous.
The present embodiments relate to method and apparatus can be completed using standard programming technology, utilization is rule-based Logic or other logics realize various method and steps.It should also be noted that herein and used in claims Word " device " and " module " are intended to include using the realization of a line or multirow software code and/or hardware realization and/or use In the equipment for receiving input.
It is hard that the one or more combined individually or with other equipment can be used in any step or program described herein Part or software module are executed or are realized.In one embodiment, software module use includes comprising computer program code Computer-readable medium computer program product realize, can by computer processor execute it is any or complete for executing The described step or program in portion.
For the purpose of example and description, the preceding description that the present invention is implemented is had been presented for.Preceding description is not poor Also not the really wanting of act property limits the invention to exact form disclosed, according to the above instruction there is likely to be various modifications and Modification, or various changes and modifications may be obtained from the practice of the present invention.Select and describe these embodiments and be in order to Illustrate the principle of the present invention and its practical application, so that those skilled in the art can be to be suitable for the special-purpose conceived Come in a variety of embodiments with various modifications and utilize the present invention.

Claims (12)

1. a kind of image processing method, which comprises
Process instruction receiving step receives the process instruction for the multiple batches of original image prestored, wherein the process instruction Including scalability information;
Control instruction generation step generates control instruction according to the process instruction received, and the control instruction includes reading Control instruction is taken, control instruction is handled and writes back control instruction;
Image reading step, the present lot in multiple batches of original image prestored according to the reading control instruction reading Original image;
Image processing step is handled the original image of the present lot according to the processing control instruction, obtain through The image of processing;
Image writes back step, writes back control instruction according to described and writes back to the processed image in memory,
Wherein, after the original image to the present lot has executed described image read step, described image reads step The original image of the next batch in multiple batches of original image prestored described in rapid reading.
2. according to the method described in claim 1, wherein, described image read step includes:
Receive the reading control instruction;
According to the reading control instruction, scaling number relevant to scaling in the raw image data of the present lot is read According to.
3. according to the method described in claim 2, wherein, described image processing step includes image scaling step, the processing Control instruction includes zoom control instruction, and image scaling step includes:
Receive the zoom control instruction;
It is instructed according to the zoom control, obtains scaling number relevant to scaling in the raw image data of the present lot According to;
According to the scaled data of acquisition, the original image of the present lot is scaled according to zoom control instruction, is obtained To the image of scaled processing;
Export the image of the scaled processing.
4. according to the method described in claim 3, wherein, described image processing step further includes image mirrors step, the place Managing control instruction further includes mirror image control instruction, and described image mirror step includes:
According to the mirror image control instruction, mirror image processing is carried out and at the same time caching the warp to the image of the scaled processing The image of scaling processing obtains the image after mirror image processing;
Export the image after mirror image processing.
5. it is described according to the mirror image control instruction according to the method described in claim 4, wherein, to the scaled processing Image carry out mirror image processing, obtaining the image after mirror image processing includes:
Receive the mirror image control instruction;
According to the mirror image control instruction, the line number of every a line of each image in the image data of the scaled processing is received According to;
Mirror image processing is carried out to the row data of every a line of each image in the image data of the scaled processing, obtains mirror image Row data.
6. according to the method described in claim 5, wherein, export the image of the scaled processing and export it is described through mirror image at Image after reason, comprising:
The row data for inputting and caching every a line, when Current Datarow is input to half, according to preset output data quantity position Width exports the Current Datarow of caching;
After the completion of Current Datarow output, enter the mirror image row data that the mode first gone out exports Current Datarow later.
7. according to the method described in claim 6, wherein, the preset output data quantity bit wide is input data amount bit wide 2 times.
8. according to the method described in claim 3, wherein, described image writes back step and includes:
Control instruction is write back described in reception;
Control instruction is write back according to described, receives the image of the scaled processing;
The image of the scaled processing is write back in memory.
9. according to the method described in claim 4, wherein, described image writes back step further include:
Control instruction is write back described in reception;
Control instruction is write back according to described, receives the image of the scaled processing and through the image after mirror image processing;
The image of the scaled processing and the image after mirror image processing are write back in the memory.
10. a kind of image processing apparatus, wherein described device includes:
Process instruction receiving unit receives the process instruction for being directed to preset multiple batches of original image, wherein the process instruction Including scalability information;
Control instruction generation unit generates control instruction according to the process instruction received, and the control instruction includes reading Control instruction is taken, control instruction is handled and writes back control instruction;
Image reading unit reads the preset multiple batches of original image from the memory according to the reading control instruction In present lot original image;
Image processing unit is handled the original image of the present lot according to the processing control instruction, obtain through The image of processing;
Image writeback unit writes back control instruction and writes back to the processed image in the memory according to described,
Wherein, image reading unit is after the original image to the present lot has executed described image reading, the figure The original image of the next batch in multiple batches of original image prestored as described in reading unit reading.
11. a kind of electronic equipment, wherein the electronic equipment includes:
Memory, for storing instruction;And
Processor, for calling image procossing described in instruction execution any one of claims 1 to 9 of the memory storage Method.
12. a kind of computer readable storage medium, wherein the computer-readable recording medium storage has computer is executable to refer to It enables, when the computer executable instructions are run on computers, at image described in any one of perform claim requirement 1 to 9 Reason method.
CN201910194700.1A 2019-03-14 2019-03-14 Image processing method and device Active CN110060196B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910194700.1A CN110060196B (en) 2019-03-14 2019-03-14 Image processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910194700.1A CN110060196B (en) 2019-03-14 2019-03-14 Image processing method and device

Publications (2)

Publication Number Publication Date
CN110060196A true CN110060196A (en) 2019-07-26
CN110060196B CN110060196B (en) 2023-09-19

Family

ID=67317007

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910194700.1A Active CN110060196B (en) 2019-03-14 2019-03-14 Image processing method and device

Country Status (1)

Country Link
CN (1) CN110060196B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112346681A (en) * 2019-08-09 2021-02-09 西安诺瓦星云科技股份有限公司 Image display control method, device and system and computer readable medium
CN112950456A (en) * 2021-02-25 2021-06-11 合肥宏晶微电子科技股份有限公司 Image processing method and device, electronic equipment and computer readable medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5251297A (en) * 1990-10-10 1993-10-05 Fuji Xerox Co., Ltd. Picture image processing system for entering batches of original documents to provide corresponding picture image datafiles
CN102263880A (en) * 2010-05-25 2011-11-30 安凯(广州)微电子技术有限公司 Image scaling method and apparatus thereof
CN102567949A (en) * 2011-12-14 2012-07-11 深圳市海泰康微电子有限公司 Method and device for scaling images
CN106910162A (en) * 2017-02-07 2017-06-30 深圳市爱协生科技有限公司 Image zoom processing method and device based on FPGA

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5251297A (en) * 1990-10-10 1993-10-05 Fuji Xerox Co., Ltd. Picture image processing system for entering batches of original documents to provide corresponding picture image datafiles
CN102263880A (en) * 2010-05-25 2011-11-30 安凯(广州)微电子技术有限公司 Image scaling method and apparatus thereof
CN102567949A (en) * 2011-12-14 2012-07-11 深圳市海泰康微电子有限公司 Method and device for scaling images
CN106910162A (en) * 2017-02-07 2017-06-30 深圳市爱协生科技有限公司 Image zoom processing method and device based on FPGA

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
邹庆华等: "基于FPGA的视频图像处理系统研究", 《信息通信》 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112346681A (en) * 2019-08-09 2021-02-09 西安诺瓦星云科技股份有限公司 Image display control method, device and system and computer readable medium
CN112346681B (en) * 2019-08-09 2023-01-10 西安诺瓦星云科技股份有限公司 Image display control method, device and system and computer readable medium
CN112950456A (en) * 2021-02-25 2021-06-11 合肥宏晶微电子科技股份有限公司 Image processing method and device, electronic equipment and computer readable medium

Also Published As

Publication number Publication date
CN110060196B (en) 2023-09-19

Similar Documents

Publication Publication Date Title
US10789182B2 (en) System and method for individual addressing
JP7216781B2 (en) Data storage method, data storage device, data reading method and data reading device
CN107315718A (en) A kind of apparatus and method for performing inner product of vectors computing
CN103348320A (en) Computational resource pipelining in general purpose graphics processing unit
CN110060196A (en) Image processing method and device
US20090238478A1 (en) Image processing apparatus
US11487342B2 (en) Reducing power consumption in a neural network environment using data management
CN107315575A (en) A kind of apparatus and method for performing vectorial union operation
CN107315563A (en) A kind of apparatus and method for performing vectorial comparison operation
CN107315716A (en) A kind of apparatus and method for performing Outer Product of Vectors computing
CN110275840A (en) Distributed process on memory interface executes and file system
CN108615074A (en) Processing with Neural Network system and method based on compressed sensing
CN103647937A (en) An image tracking system and an image data processing method thereof
CN107315568A (en) A kind of device for being used to perform vector logic computing
CN111984189A (en) Neural network computing device, data reading method, data storage method and related equipment
CN107957977A (en) A kind of computational methods and Related product
CN107315565B (en) Device and method for generating random vectors obeying certain distribution
CN110018847B (en) Configurable register and data access method based on same
CN115049885A (en) Storage and calculation integrated convolutional neural network image classification device and method
CN107391440A (en) A kind of processing unit and method of fast fourier transform algorithm output data
CN108920097B (en) Three-dimensional data processing method based on interleaving storage
CN111078589B (en) Data reading system, method and chip applied to deep learning calculation
CN109685209B (en) Device and method for accelerating operation speed of neural network
CN102622318B (en) Storage controlling circuit and vector data addressing method controlled by same
JP5982148B2 (en) Semiconductor memory device

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
TA01 Transfer of patent application right

Effective date of registration: 20230817

Address after: Room 59, 17th Floor, Science and Technology Innovation Building, No. 777 Zhongguan West Road, Zhuangshi Street, Zhenhai District, Ningbo City, Zhejiang Province, 315201

Applicant after: Aixin Yuanzhi Semiconductor (Ningbo) Co.,Ltd.

Address before: 100190 A block 2, South Road, Haidian District Academy of Sciences, Beijing 313

Applicant before: BEIJING KUANGSHI TECHNOLOGY Co.,Ltd.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant