CN1235411C - Flow-line-based frame predictive mode coding acceleration method - Google Patents
Flow-line-based frame predictive mode coding acceleration method Download PDFInfo
- Publication number
- CN1235411C CN1235411C CN 200310101445 CN200310101445A CN1235411C CN 1235411 C CN1235411 C CN 1235411C CN 200310101445 CN200310101445 CN 200310101445 CN 200310101445 A CN200310101445 A CN 200310101445A CN 1235411 C CN1235411 C CN 1235411C
- Authority
- CN
- China
- Prior art keywords
- block
- sub
- subprocess
- intra
- piece
- 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.)
- Expired - Fee Related
Links
- 238000000034 method Methods 0.000 title claims abstract description 26
- 230000001133 acceleration Effects 0.000 title abstract description 6
- 238000013139 quantization Methods 0.000 claims description 13
- 238000011002 quantification Methods 0.000 claims 3
- 238000004891 communication Methods 0.000 abstract description 2
- 230000009466 transformation Effects 0.000 description 10
- 238000010586 diagram Methods 0.000 description 6
- 238000004364 calculation method Methods 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 108091026890 Coding region Proteins 0.000 description 2
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 239000002699 waste material Substances 0.000 description 1
Images
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
本发明涉及网络媒体传播技术领域,特别是一种基于流水线的帧内预测模式块编码加速方法。步骤如下:将视频帧划分为的宏块(如16*16),再将宏块划分为子块(如4*4),在帧内预测模式中对每一子块分别预测编码。它能在不增加资源消耗的前提下极大地加速帧内编码速度,从而提高视频编码速度。本发明的特征是:基于流水线结构,不增加资源消耗;适用于任何基于分块的帧内预测编码,适用性强;按照流水线要求调整子块编码顺序;提高编码速度。本发明适用于视频编码设计。
The invention relates to the technical field of network media communication, in particular to a pipeline-based intra-frame prediction mode block coding acceleration method. The steps are as follows: divide the video frame into macroblocks (such as 16*16), then divide the macroblock into subblocks (such as 4*4), and predictively encode each subblock in intra-frame prediction mode. It can greatly accelerate the speed of intra-frame coding without increasing resource consumption, thereby increasing the speed of video coding. The characteristics of the present invention are: based on the assembly line structure, without increasing resource consumption; suitable for any block-based intra-frame predictive encoding, with strong applicability; adjusting sub-block encoding order according to the assembly line requirements; and improving encoding speed. The invention is suitable for video coding design.
Description
技术领域technical field
本发明涉及网络媒体传播技术领域,特别是一种基于流水线的帧内预测模式块编码加速方法。The invention relates to the technical field of network media communication, in particular to a pipeline-based intra-frame prediction mode block coding acceleration method.
技术背景technical background
随着多媒体技术和网络技术的飞速发展和广泛应用,通过网络来传播各种视频数据得到越来越广泛的应用。由于原始视频数据所需带宽极大,同时又具有很大的冗余性,因此通常通过编码压缩再传输。在某些实时或近实时的环境下(如视频会议等),要求编码器达到足够高的编码速度。而视频编码计算量的庞大,就要求对编码过程采用加速算法。With the rapid development and wide application of multimedia technology and network technology, the dissemination of various video data through the network has become more and more widely used. Because the original video data requires a huge bandwidth and has great redundancy, it is usually compressed and then transmitted through encoding. In some real-time or near-real-time environments (such as video conferencing, etc.), the encoder is required to achieve a sufficiently high encoding speed. The huge amount of video encoding calculations requires the use of accelerated algorithms for the encoding process.
视频编码从80年代末开始,从MPEG-1、H.261到现在的MPEG-4、H.264已经有很长的研究历史,提出了很多国际标准,但是基本思想仍然是分块压缩和运动预测。H.264在以前标准中的帧内宏块预测方式的基础上,提出了一种新的帧内预测模式——4*4帧内预测,它将一个16*16的宏块分为16个4*4的子块,每一子块分别进行帧内预测,各自有独立的预测模式。这种模式提高了编码的效率,也带来了计算复杂度的提高和编码速度的减慢,通过采用本发明提出的基于流水线的加速方法可以极大地加速帧内编码速度。Video coding began in the late 1980s. From MPEG-1, H.261 to the current MPEG-4, H.264, there has been a long research history, and many international standards have been proposed, but the basic idea is still block compression and motion predict. Based on the intra-frame macroblock prediction method in the previous standard, H.264 proposes a new intra-frame prediction mode - 4*4 intra-frame prediction, which divides a 16*16 macroblock into 16 For 4*4 sub-blocks, intra-frame prediction is performed on each sub-block, and each has an independent prediction mode. This mode improves the coding efficiency, but also brings about the increase of computational complexity and the slowdown of coding speed, and the speed of intra-frame coding can be greatly accelerated by adopting the pipeline-based acceleration method proposed by the present invention.
发明内容Contents of the invention
本发明的目的在于提供一种基于流水线的帧内预测模式块编码加速方法。本发明包括以下特征:The purpose of the present invention is to provide a pipeline-based method for accelerating block coding in intra-frame prediction mode. The present invention includes the following features:
发明的技术方案Invented technical solution
一种基于流水线的帧内预测模式块编码加速方法,将帧内编码过程分为预测、DCT变换及量化、反量化及反DCT变换和重建四个子过程,根据宏块中子块帧内编码的数据相关性,将从左至右、从上至下的子块帧内编码顺序进行调整,使得编码顺序中子块和后续子块间不存在数据相关性,从而使子块帧内编码的子过程之间形成流水线操作,不需要等待前一子块的全部子过程结束才能进行后续子块的子过程,在不增加资源消耗的情况下,前一子块的DCT变换及量化子过程可以与后续子块的预测子过程同时进行,反量化及反DCT变换子过程可以与后续子块的DCT变换及量化子过程同时进行,重建子过程可以与后续子块的反量化及反DCT变换子过程同时进行,依次类推。A pipeline-based intra-frame prediction mode block coding acceleration method, which divides the intra-frame coding process into four sub-processes: prediction, DCT transformation and quantization, inverse quantization, inverse DCT transformation and reconstruction. Data dependency, adjust the sub-block intra-coding order from left to right and from top to bottom, so that there is no data correlation between sub-blocks and subsequent sub-blocks in the coding order, so that sub-block intra-coded sub-blocks The pipeline operation is formed between the processes, and the sub-process of the subsequent sub-block does not need to wait for the completion of all the sub-processes of the previous sub-block. Without increasing resource consumption, the DCT transformation and quantization sub-process of the previous sub-block can be compared with The prediction sub-process of subsequent sub-blocks is carried out simultaneously, the sub-process of inverse quantization and inverse DCT transformation can be carried out simultaneously with the sub-process of DCT transformation and quantization of subsequent sub-blocks, and the sub-process of reconstruction can be carried out together with the sub-process of inverse quantization and inverse DCT transformation of subsequent sub-blocks Simultaneously, and so on.
附图说明Description of drawings
图1是MPEG-4AVC/H.264帧内4×4块编码顺序图。Fig. 1 is a sequence diagram of encoding 4*4 blocks in an MPEG-4AVC/H.264 frame.
图2是MPEG-4AVC/H.264预测参考点图。FIG. 2 is a diagram of MPEG-4AVC/H.264 prediction reference points.
图3是帧内编码流水线示意图。Fig. 3 is a schematic diagram of an intra-frame encoding pipeline.
图4是顺序执行序列图。Figure 4 is a sequential execution sequence diagram.
图5是理想情况下流水线执行序列图。Figure 5 is an ideal pipeline execution sequence diagram.
图6是实际情况下流水线执行序列图。Fig. 6 is a sequence diagram of pipeline execution under actual conditions.
发明的具体实施方式Specific Embodiments of the Invention
图1中,以MPEG-4AVC/H.264帧内预测为例:In Figure 1, take MPEG-4AVC/H.264 intra-frame prediction as an example:
MPEG-4AVC/H.264将视频帧划分为16*16的宏块,再将宏块划分为4*4的子块,在帧内预测模式中对每一子块分别预测编码。图1为编码顺序,MPEG-4AVC/H.264 divides the video frame into 16*16 macroblocks, and then divides the macroblock into 4*4 subblocks, and predicts and codes each subblock separately in the intra prediction mode. Figure 1 shows the coding sequence,
图2是预测所需参考点。Figure 2 is the reference point required for prediction.
如图3,帧内4x4块编码过程可以分为预测、DCT变换及量化、反量化及反DCT变换和重建四个子过程,设四个子过程所需时间分别为T1、T2、T3、T4,则对一个宏块的16个子块帧内编码顺序执行所需总时间As shown in Figure 3, the intra-frame 4x4 block encoding process can be divided into four sub-processes: prediction, DCT transformation and quantization, inverse quantization, inverse DCT transformation and reconstruction. The time required for the four sub-processes is respectively T 1 , T 2 , T 3 , T 4 , then the total time required to execute the intra-frame coding sequence of 16 sub-blocks of a macroblock
Tseq=16*(T1+T2+T3+T4)T seq =16*(T 1 +T 2 +T 3 +T 4 )
执行序列如图4所示。The execution sequence is shown in Figure 4.
可以注意到,预测、DCT变换及量化、反量化及反DCT变换和重建四个子过程在任何时刻都只有一个在执行,造成了资源的浪费和计算时间的延长,因此可以采用流水线技术充分利用计算资源并减少计算时间。如图5所示,在理想情况下对一个宏块的16个子块帧内编码流水线的执行时间It can be noticed that only one of the four sub-processes of prediction, DCT transformation and quantization, inverse quantization and inverse DCT transformation and reconstruction is executed at any time, resulting in waste of resources and prolongation of calculation time, so pipeline technology can be used to make full use of calculation resources and reduce computing time. As shown in Figure 5, under ideal conditions, the execution time of the 16 sub-block intra-frame coding pipelines of a macroblock
Tpipeline_ideal=T1+max(T1+T2)+max((T1+T2+T3)T pipeline_ideal =T 1 +max(T 1 +T 2 )+max((T 1 +T 2 +T 3 )
+max(T1+T2+T3+T4)*13+max(T 1 +T 2 +T 3 +T 4 )*13
+max(T2+T3+T4)+max(T3+T4)+T4 +max(T 2 +T 3 +T 4 )+max(T 3 +T 4 )+T 4
但是由于各子块之间存在数据相关性,不能达到理想状态,如子块1的预测需要字块0的重建数据,子块2的预测需要子块0和子块0的重建数据。根据数据相关性,将子块编码顺序进行调整以充分发挥流水线效率,编码顺序调整如下:However, due to the data correlation between sub-blocks, the ideal state cannot be achieved. For example, the prediction of
0,1,4,2,5,3,6,8,7,9,12,10,13,11,14,15执行序列图如图6所示。0, 1, 4, 2, 5, 3, 6, 8, 7, 9, 12, 10, 13, 11, 14, 15 are shown in Figure 6.
对一个宏块的16个子块帧内编码执行所需总时间Total time required to perform intra coding of 16 subblocks of a macroblock
Tpipeline_real=(T1+T2+T3+T4)*4+{T1+T4+[max(T1,T2)+max(T2,T pipeline_real = (T 1 +T 2 +T 3 +T 4 )*4+{T 1 +T 4 +[max(T 1 , T 2 )+max(T 2 ,
T3)+max(T3,T4)+max(T4,T1)]*2}*3T 3 )+max(T 3 , T 4 )+max(T 4 , T 1 )]*2}*3
加速比λ=Tseq/Tpipeline_real Speedup ratio λ=T seq /T pipeline_real
在FPGA参考硬件实现中,T1=20cycle,T2=T3=16cycle,T4=18cycle,可以得出加速比为1.3365,在不增加硬件资源消耗的情况下性能提高了33.65%。In the FPGA reference hardware implementation, T 1 =20cycle, T 2 =T 3 =16cycle, T 4 =18cycle, it can be obtained that the acceleration ratio is 1.3365, and the performance is improved by 33.65% without increasing the consumption of hardware resources.
Claims (1)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 200310101445 CN1235411C (en) | 2003-10-17 | 2003-10-17 | Flow-line-based frame predictive mode coding acceleration method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN 200310101445 CN1235411C (en) | 2003-10-17 | 2003-10-17 | Flow-line-based frame predictive mode coding acceleration method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN1529512A CN1529512A (en) | 2004-09-15 |
CN1235411C true CN1235411C (en) | 2006-01-04 |
Family
ID=34304198
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN 200310101445 Expired - Fee Related CN1235411C (en) | 2003-10-17 | 2003-10-17 | Flow-line-based frame predictive mode coding acceleration method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN1235411C (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100558166C (en) * | 2006-09-04 | 2009-11-04 | 中国科学院计算技术研究所 | A kind of encoding and decoding method of graphic terminal interface |
Families Citing this family (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101710991B (en) * | 2004-11-04 | 2015-06-24 | 汤姆森特许公司 | Fast intra mode prediction for a video encoder |
US7830960B2 (en) * | 2005-01-13 | 2010-11-09 | Qualcomm Incorporated | Mode selection techniques for intra-prediction video encoding |
CN100413344C (en) * | 2006-10-20 | 2008-08-20 | 清华大学 | Implementation method of high parallelism intra-frame predictor |
JP5082548B2 (en) * | 2007-03-30 | 2012-11-28 | 富士通株式会社 | Image processing method, encoder and decoder |
CN100542298C (en) * | 2007-09-29 | 2009-09-16 | 中国科学院计算技术研究所 | Block Size Calculation Method and Transmission Method for Cylindrical Panoramic Video Coding |
JP5449791B2 (en) * | 2009-02-02 | 2014-03-19 | オリンパス株式会社 | Data processing apparatus and image processing apparatus |
TW201123908A (en) * | 2009-07-02 | 2011-07-01 | Mediatek Inc | Methods of intra prediction, video encoder, and video decoder thereof |
WO2012046435A1 (en) | 2010-10-04 | 2012-04-12 | パナソニック株式会社 | Image processing device, image coding method and image processing method |
CN102143361B (en) * | 2011-01-12 | 2013-05-01 | 浙江大学 | Video coding method and video coding device |
CN102420989B (en) * | 2011-12-07 | 2014-03-19 | 中国航空无线电电子研究所 | Intra-frame prediction method and device |
JPWO2013108330A1 (en) * | 2012-01-18 | 2015-05-11 | パナソニックIpマネジメント株式会社 | Image decoding apparatus, image encoding apparatus, image decoding method, and image encoding method |
JP2014007469A (en) * | 2012-06-21 | 2014-01-16 | Canon Inc | Image coding device and image coding method |
CN104393958B (en) * | 2014-11-28 | 2017-11-28 | 成都航天通信设备有限责任公司 | Data frame sending method, method of reseptance based on streamline |
CN108989805A (en) * | 2018-06-06 | 2018-12-11 | 郑州云海信息技术有限公司 | Image processing method and device based on WebP image compression algorithm |
-
2003
- 2003-10-17 CN CN 200310101445 patent/CN1235411C/en not_active Expired - Fee Related
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100558166C (en) * | 2006-09-04 | 2009-11-04 | 中国科学院计算技术研究所 | A kind of encoding and decoding method of graphic terminal interface |
Also Published As
Publication number | Publication date |
---|---|
CN1529512A (en) | 2004-09-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN1235411C (en) | Flow-line-based frame predictive mode coding acceleration method | |
CN106375765B (en) | By using the method and apparatus of the inter prediction encoding/decoding image of any block | |
CA2748374C (en) | Video encoding using previously calculated motion information | |
CN101115208B (en) | Picture coding apparatus | |
CN105306939B (en) | Method and apparatus for being decoded to video | |
KR100455119B1 (en) | Adaptive decision method for a range of motion vector | |
CN110351552B (en) | A Fast Coding Method in Video Coding | |
CN1879418A (en) | Selective and/or scalable complexity control for video codecs | |
WO2010078212A1 (en) | Multiple-candidate motion estimation with advanced spatial filtering of differential motion vectors | |
WO2007109938A1 (en) | A video layered coding method and a coding and decoding device in interlaced mode | |
CN107135392A (en) | HEVC Motion Search Parallel Method Based on Asynchronous Mode | |
JP5004180B2 (en) | Video encoding apparatus and decoding apparatus | |
CN1615020A (en) | Method for pridicting sortable complex in frame | |
CN1476253A (en) | An Intra-frame Coding Method Using Intra-frame Prediction Based on Prediction Block Group | |
CN102595132A (en) | Distributed video encoding and decoding method applied to wireless sensor network | |
KR20080033754A (en) | Image coding method and apparatus | |
CN104113761A (en) | Code rate control method for video encoding and encoder | |
CN105791865A (en) | Intra-frame prediction and deblocking filtering method | |
CN108965814A (en) | A kind of video mix decoding rendering method based on CUDA acceleration technique | |
CN1809167A (en) | Quick inter-frame forecast mode selection method | |
CN1263309C (en) | Motion vector prediction method used for video coding | |
CN100452878C (en) | Motion image handling method in video coding | |
CN102625109B (en) | Multi-core-processor-based moving picture experts group (MPEG)-2-H.264 transcoding method | |
JP2007282014A (en) | Method of generating image data | |
CN1515085A (en) | Motion compensation for fine-grain scalable video |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20060104 Termination date: 20191017 |