Git Product home page Git Product logo

uavs3e's Introduction

uavs3e

uavs3e is an opensource avs3 encoder, supports AVS3-P2 baseline profile.
features:

  1. AVS3-P2 baseline profile.
  2. supports to compile for Windows/Linux systems.
  3. optimized for SSE4/AVX2 chips.
  4. 10bit encoding on all supported platforms (without SIMD).
  5. The uavs3 codec has supported x86 and arm platforms, and has been tested and verified on the Kunpeng processor.
  6. The ARM platform recommends the Kunpeng processor.

license

Copyright reserved by “Peking University Shenzhen Graduate School”, “Peng Cheng Laboratory”, and “Guangdong Bohua UHD Innovation Corporation”

This program is a free software. You can redistribute it and/or modify it under the terms of the BSD 4-clause license.
For more details, please view the file "COPYING" in the project.

compile

The default configuration only support 8bit encoding.
To support 10bit streams encoding: cmake -DCOMPILE_10BIT=1

windows

Prerequisites: Visual Studio 2017

build:

  1. ./version.bat (to generate version.h)
  2. solution file: build/x86_windows/uavs3e.sln

To support 10bit streams encoding, edit inc/com_api.h : #define COMPILE_10BIT 1

linux

Prerequisites:

  1. gawk (http://www.gnu.org/software/gawk/)
  2. CMake (https://cmake.org) version 2.8 or higher

Build:

  1. mkdir build/linux
  2. cd build/linux && cmake -DCOMPILE_10BIT=0 ../..
  3. make && make install

To support 10bit streams encoding: cmake -DCOMPILE_10BIT=1 to build shared library, set BUILD_SHARED_LIBS=1 please.

Run tests

window/linux

uavs3e [--config file] [-paramShort ParameterValue] [--paramLong ParameterValue]

 --config file    
         All Parameters are initially taken from the 'file', typically: "encode_RA.cfg".

 -paramShort ParameterValue
 --paramLong ParameterValue
         If -paramShort or --paramLong parameters are present, then the ParameterValue will override the default settings in the configuration file.

Contributors

This program is originally developed by the team of Prof.Ronggang Wang ([email protected]) at Peking University Shenzhen Graduate School.

  • Main contributors:

    • Zhenyu Wang ([email protected]), Peking University Shenzhen Graduate School.
    • Bingjie Han ([email protected]), Peking University Shenzhen Graduate School.
    • Jiang Du, Peking University Shenzhen Graduate School.
    • Kui Fan, Peking University Shenzhen Graduate School.
    • Xi Xie, Peking University Shenzhen Graduate School.
    • Shengyuan Wu, Peking University Shenzhen Graduate School.
    • Tong Wu, Peking University Shenzhen Graduate School.
    • Shiyi Liu, Peking University Shenzhen Graduate School.
    • Jiayu Yang, Peking University Shenzhen Graduate School.
    • Chunhui Yang, Peking University Shenzhen Graduate School.
    • Dapeng Chen, Bigo Technology Pte. Ltd
    • Jin Lin, Harbin Institute of Technology, Shenzhen.
    • Yi Ma, Peking University Shenzhen Graduate School.
    • Litian Li, Peking University Shenzhen Graduate School.
    • Guisen Xu, Peking University Shenzhen Graduate School.
    • Xufeng Li, Peking University Shenzhen Graduate School.
    • Yangang Cai, Peking University Shenzhen Graduate School.
    • Hao Lv, Peng Cheng Laboratory.
    • Ronggang Wang ([email protected]), Peking University Shenzhen Graduate School

    XueliCheng

    luofl

References

*This program also refers to the following fast algorithm:

  • 陈焕浜, 杨海涛. SMVD编码加速. AVS技术提案, M5218. 2020年3月.
  • 赵寅, 杨海涛. 块划分快速算法. AVS技术提案, M5137. 2020年3月.
  • 张焕宸, 陈雅梅, 喻莉. 基于灰度共生矩阵与编码信息的帧内预测快速算法. AVS技术提案, M5327.

uavs3e's People

Contributors

chaojimayi avatar chengxueli avatar dapengchen-pri avatar dujiangpku avatar hanbingjie515 avatar hecaiyuan avatar jyyangchina avatar luofalei avatar myron-ych avatar syliu11 avatar tjudoubletong avatar wukei avatar zywang-sirius avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

uavs3e's Issues

Version.bat does not run on Windows 10

generally the sh command is not available in the Windows command prompt and neither are many of the commands used in the shell script.

The preconditions for building in a Windows environment should be described in the Readme

库与头文件安装目的错误

原因是使用了固定目录, 即/usr/include/与/usr/lib:
install(TARGETS uavs3e LIBRARY DESTINATION /usr/lib ARCHIVE DESTINATION /usr/lib)
install(FILES ../inc/uavs3e.h DESTINATION /usr/include/uavs3e/)
install(FILES ../inc/com_api.h DESTINATION /usr/include/uavs3e/)

而应为:
install(TARGETS uavs3e LIBRARY DESTINATION ${CMAKE_INSTALL_LIB_DIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIB_DIR})
install(FILES ../inc/uavs3e.h DESTINATION ${INSTALL_INCLUDE_DIR}/uavs3e/)
install(FILES ../inc/com_api.h DESTINATION ${INSTALL_INCLUDE_DIR}/uavs3e/)

[编码时间显示错误]Linux fps计算错误 显示编码时间比实际时间长较多倍

版本信息:Linux, Ubuntu 18.04.2 LTS, uavs3e version: 1.2.208_release

编码使用脚本:

import os
import time

uavs3_v1_2_208 = "/home/yxj/yangxijie/software/git/uavs3e/build/linux/uavs3enc"

yuv_video = "/mnt/video/E/FourPeople_1280x720_60.yuv"
yuv_width = '1280'
yuv_height = '720'
yuv_fps = '60'

set_qp = '45'
set_speed_level = '3'

coding_video = ' ./uavs3e.avs3'

begin_time = time.time()
cmd = uavs3_v1_2_208 + ' --speed_level ' + set_speed_level + ' --width ' + yuv_width + ' --height ' + yuv_height + ' --fps_num ' + yuv_fps + ' --fps_den 1 ' + ' --i_period ' + yuv_fps + ' --rc_type 0 ' + ' --input_bit_depth 8 ' + ' --qp ' + set_qp + ' --wpp_threads 40 ' + ' --frm_threads 40 ' + ' --input ' + yuv_video + ' --output ' + coding_video + ' --verbose 2 ' 
os.system(cmd)
end_time = time.time()
print('END' + str(end_time - begin_time) + 's')

使用python3 a.py得到输出:

xj@coolc:~/yangxijie/playground/j$ python3 a.py
Version: 1.2.208_release,  SHA-1: cd295084706a307f887dea18b53d4716795974d4
-----------------------------------------------------------------------------------------------------------------------------------
< Sequence's Info >
	resolution input         : 1280 x 720
	resolution coding        : 1280 x 720
	bitdepth input           : 8
	bitdepth coding          : 8
	frame rate               : 60 / 1
	intra picture period     : 60
	close_gop                : 0
	max b frames             : 15
	signature                : 0

< LookAhead Info >
	lookahead                : 40
	scenecut                 : 0
	schistogram              : 0
	adaptive_gop             : 0

< Parallel Info >
	WPP threads              : 6
	frame threads            : 40

< RC Info >
	RC type                  : 0 (0: CQP, 1: CRF, 2: ABR, 3: CBR)
	qp                       : 45
	qp_offset_cb             : 0
	qp_offset_cr             : 0

< CU split CFG >
	ctu_size:        128
	min_cu_size:     4
	max_part_ratio:  8
	max_split_times: 6
	min_qt_size:     8
	max_bt_size:     64
	max_eqt_size:    32
	max_dt_size:     16

< Tool CFG >
	Loop Filter:  deblock: 1, sao: 1, alf: 1, cross_patch: 1,
	Inter: AMVR(1) HMVP_NUM(8) AFFINE(1) SMVD(1) UMVE(1) EMVR(1)
	Intra: TSCPM(1) IPF(1) DT(1)
	Transform: PBT(1) SECTrans(1)
	Quant: WeightedQuant: 0
	ENC-Side Tools: chroma_qp(1) AQ(0)
	Speed_level: 3
-----------------------------------------------------------------------------------------------------------------------------------
  Input YUV file           : /mnt/video/E/FourPeople_1280x720_60.yuv
  Output bitstream         : ./uavs3e.avs3
-----------------------------------------------------------------------------------------------------------------------------------
    POC | QP |  PSNR-Y  PSNR-U  PSNR-V| SSIM-Y SSIM-U SSIM-V|   Bits |  Time |        Ref. List      | Ext_info
************************************************************
    0(I)|41.0| 37.1648 42.2469 43.7415| 0.9491 0.9618 0.9743|  149888|   5838|L0         |L1         |[]
************************************************************
   16(B)|46.0| 36.3726 42.1169 43.4899| 0.9432 0.9609 0.9732|   13904|   1473|L0   0     |L1   0     |[]
***************************************************************************************
(省略)

===============================================================================
  PSNR Y(dB)       : 35.8344
  PSNR U(dB)       : 41.9294
  PSNR V(dB)       : 43.3710
  SSIM Y(dB)       : 0.9391
  SSIM U(dB)       : 0.9603
  SSIM V(dB)       : 0.9724
  Total bits(bits) : 2870696
  bitrate(kbps)    : 287.0696
===============================================================================
Encoded frame count               = 600
Total encoding time               = 450612.000 msec, 450.612 sec
Average encoding time for a frame = 751.020 msec
Average encoding speed            = 1.33152 frames/sec
===============================================================================
END80.22815370559692s

可以看到输出log的后面Total encoding time为450s,但是用python脚本提供的时间计算发现实际编码时间为80.2s。这也导致fps计算错误。(也可能是我对log中Total的理解有差。

无法在macOS下编译

/Users/ibobby/GitHub/avs/uavs3e/src/uavs3e.c:1336:5: error: implicit declaration of function 'uavs3e_funs_init_sse' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
    uavs3e_funs_init_sse();
    ^
/Users/ibobby/GitHub/avs/uavs3e/src/uavs3e.c:1336:5: note: did you mean 'uavs3e_funs_init_c'?
/Users/ibobby/GitHub/avs/uavs3e/src/../inc/com_util.h:367:6: note: 'uavs3e_funs_init_c' declared here
void uavs3e_funs_init_c();
     ^
/Users/ibobby/GitHub/avs/uavs3e/src/uavs3e.c:1337:9: error: implicit declaration of function 'uavs3e_simd_avx_level' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
    if (uavs3e_simd_avx_level(NULL) >= 2) {
        ^
/Users/ibobby/GitHub/avs/uavs3e/src/uavs3e.c:1338:9: error: implicit declaration of function 'uavs3e_funs_init_avx2' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
        uavs3e_funs_init_avx2();
        ^
3 warnings and 3 errors generated.
make[2]: *** [src/CMakeFiles/uavs3e.dir/uavs3e.c.o] Error 1
make[1]: *** [src/CMakeFiles/uavs3e.dir/all] Error 2
make: *** [all] Error 2

以下是我运行的命令

git clone https://github.com/uavs3/uavs3e.git
cd uavs3e
mkdir build/macos
cd build/macOS
cmake ../..
make

[编码性能疑问] uavs3-RealTime对比x265性能相差50%左右

如标题,在实测中,Random Access 单线程配置下,uAVS3e-RealTime与x265编码器性能相差很大。采用ClassA~ClassF,另外增加4个额外的4K视频序列,uavs3e-RealTime对比x265编码性能相差50%左右。这个与智媒之音(https://mp.weixin.qq.com/s/cXMHveOYegzuKi2rN7Ftgg)的评测结论相差很大。

uavs3e采用RealTime分支的最快档次,配置参数如下:
uAVS3 -f /bin/encoder_ra.cfg -p InputFile= Beauty_3840x2160_50_600.yuv -p OutputFile=Beauty_3840x2160_50_600_Anchor_qp32.bin -p SourceWidth= 3840 -p SourceHeight= 2160 -p FramesToBeEncoded= 600 -p FrameRate=30 -p SpeedLevel=6 -p IntraPeriod=100 -p RateControl=0 -p QP= 32

x265采用veryfast,具体配置参数如下:
x265 --input Beauty_3840x2160_50_600.yuv --preset veryfast -t psnr --psnr -o Beauty_3840x2160_50_600_Anchor_qp27.bin --input-res 3840x2160 --fps 30 --keyint 100 --qp 27 --no-wpp -F 1 --bframes 3

[实时分支问题]uAVS3_gop多次运行偶现码流不一致

问题现象:
使用RealTime分支编码器uAVS3_gop进行多次编码,会偶现每次跑码流不一致问题。
(同一命令,60次跑其中有1次与其他59次码流存在微小差异)

问题命令:
./uAVS3_gop -f ../bin/encoder_ra.cfg -p InputFile=./7680X4320_10bit.yuv -p threads-frm=9 -p threads-wpp=16 -p threads-gop=1 -p RateControl=3 -p TargetBitRate=35000 -p QP=32 -p SpeedLevel=7 -p FrameRate=100 -p FramesToBeEncoded=50 -p OutputFile=./out.avs3

环境:
CPU:ARM64
OS:openEuler release 22.03 LTS
GCC:10.3.1

RealTime分支内存泄漏问题

操作系统: linux
编译命令:

export C_FLAGS="-fsanitize=leak -fno-stack-protector -no-omit-frame-pointer -saditize=address -fsanitize-recover=address"
mkdir build && cd build
cmake .. -DCOMPILE_10BIT=1
make -j

编码命令:
./uAVS3_gop -f ../bin/encoder_ra.cfg -p InputFile=in.yuv -p OutputFile=out.avs3 -p threads-gop=2

编码过程中发现
存在以下内存泄露问题:

  1. 编码器avs3gop_t handle未释放
  2. utest_gop.c中SPEED_TEST开启后,main、ReadOneth_10bit中存在内存申请后未释放
  3. avs3_lib_create中对部分全局资源初始化,多次调用avs3_lib_create导致全局资源重复初始化,造成资源泄露

RealTime分支--地址消毒段错误问题

操作系统: linux
编译命令:

export C_FLAGS="-fsanitize=leak -fno-stack-protector -no-omit-frame-pointer -saditize=address -fsanitize-recover=address"
mkdir build && cd build
cmake .. -DCOMPILE_10BIT=1
make -j

基本编码命令:
./uAVS3_gop -f ../bin/encoder_ra.cfg -p InputFile=in.yuv -p OutputFile=out.avs3 -p SourceWidth=7680 -p SourceHeight=4320 -p SampleBitDepth=10 -p CodingBitDepth=10

问题描述:使用asan地址消毒器对RealTime分支进行测试,当存在以下输入场景时,产生段错误,asan地址消毒器接收到SEGV信号

  1. 输入CQP场景边界参数"-p RateControl=0 -p QP=0",会引起对数组tab_QP_SCALE_CR的越界访问
  2. 输入未注册参数如"-p unknow=1",会引起对tab_cfg_map的越界访问
  3. 输入不存在的配置文件,如"-f unknow.cfg",会引起对空文件对象的访问
  4. 输入yuv像素值超过10bit最大值,会导致计算过程中出现段错误
  5. 输入"-p threads-gop=-1",导致初始化过程中出现段错误

[编码选项 编码log]--verbose选项提供更多的选择

uavs3e --verbose的说明为:

  -v, --verbose [INTEGER] (optional)
    : verbose level
	 0: no message
	 1: frame-level messages (default)
	 2: all messages

但是个人感觉1和2并没有差异……都包含逐帧的信息(Linux, Ubuntu 18.04.2 LTS, uavs3e version: 1.2.208_release,也可能是操作系统上版本的问题)

参考x265的--log-level说明

--log-level <integer|string>
Controls the level of information displayed on the console. Debug level enables per-frame QP, metric, and bitrate logging. Full level enables hash and weight logging. -1 disables all logging, except certain fatal errors, and can be specified by the string “none”.

0. error
1. warning
2. info (default)
3. debug
4. full

希望编码得到的基本信息为最开头的 视频、参数设置信息 和 最后面的视频编码数据,省略中间逐帧的信息,而不是现在default的 frame-level messages

另外,如果可以,基本信息可以再精简一些,输出的log可以更贴近自然语言一些

eg. x265的编码log

yuv  [info]: 1280x720 fps 60000/1000 i420p8 frames 0 - 599 of 600
raw  [info]: output file: /home/yxj/yangxijie/playground/g/E/FourPeople_1280x720_60/x265_medium/qp27/coding.hevc
x265 [info]: HEVC encoder version 3.5+1-f0c1022b6
x265 [info]: build info [Linux][GCC 7.5.0][64 bit] 8bit
x265 [info]: using cpu capabilities: MMX2 SSE2Fast LZCNT SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
x265 [warning]: --ssim used with AQ off: results will be invalid!
x265 [warning]: --tune ssim should be used if attempting to benchmark ssim!
x265 [info]: Main profile, Level-4 (Main tier)
x265 [info]: Thread pool 0 using 16 threads on numa nodes 0,1
x265 [info]: Slices                              : 1
x265 [info]: frame threads / pool features       : 4 / wpp(12 rows)
x265 [info]: Coding QT: max CU size, min CU size : 64 / 8
x265 [info]: Residual QT: max TU size, max depth : 32 / 1 inter / 1 intra
x265 [info]: ME / range / subpel / merge         : hex / 57 / 2 / 3
x265 [info]: Keyframe min / max / scenecut / bias  : 6 / 60 / 40 / 5.00
x265 [info]: Lookahead / bframes / badapt        : 20 / 4 / 2
x265 [info]: b-pyramid / weightp / weightb       : 1 / 1 / 0
x265 [info]: References / ref-limit  cu / depth  : 3 / off / on
x265 [info]: Rate Control                        : CQP-27
x265 [info]: tools: rd=3 early-skip rskip mode=1 signhide tmvp b-intra
x265 [info]: tools: strong-intra-smoothing lslices=4 deblock sao
x265 [info]: frame I:     10, Avg QP:24.00  kb/s: 26655.79  PSNR Mean: Y:42.892 U:46.108 V:47.181  SSIM Mean: 0.976873 (16.359dB)
x265 [info]: frame P:    114, Avg QP:27.00  kb/s: 2908.29   PSNR Mean: Y:40.956 U:45.219 V:46.447  SSIM Mean: 0.970450 (15.294dB)
x265 [info]: frame B:    476, Avg QP:28.74  kb/s: 514.69    PSNR Mean: Y:40.853 U:45.285 V:46.517  SSIM Mean: 0.970223 (15.261dB)
x265 [info]: Weighted P-Frames: Y:0.0% UV:0.0%
x265 [info]: consecutive B-frames: 0.8% 0.0% 0.0% 12.9% 86.3%

encoded 600 frames in 7.42s (80.85 fps), 1405.16 kb/s, Avg QP:28.33, Global PSNR: 42.155, SSIM Mean Y: 0.9703773 (15.284 dB)

[编码输出]自定义psnr.txt文件的位置

目前每次编码都会在当前路径下追加写psnr.txt,写入编码的psnr ssim和fps。

希望能在编码选项中添加类似--export --report --csv的选项,实现该文件位置的自定义

[编码输出信息] 编码log输出长串星号

版本信息:Linux, Ubuntu 18.04.2 LTS, uavs3e version: 1.2.208_release

编码使用脚本:

import os
import time

uavs3_v1_2_208 = "/home/yxj/yangxijie/software/git/uavs3e/build/linux/uavs3enc"

yuv_video = "/mnt/video/E/FourPeople_1280x720_60.yuv"
yuv_width = '1280'
yuv_height = '720'
yuv_fps = '60'

set_qp = '45'
set_speed_level = '3'

coding_video = ' ./uavs3e.avs3'

begin_time = time.time()
cmd = uavs3_v1_2_208 + ' --speed_level ' + set_speed_level + ' --width ' + yuv_width + ' --height ' + yuv_height + ' --fps_num ' + yuv_fps + ' --fps_den 1 ' + ' --i_period ' + yuv_fps + ' --rc_type 0 ' + ' --input_bit_depth 8 ' + ' --qp ' + set_qp + ' --wpp_threads 40 ' + ' --frm_threads 40 ' + ' --input ' + yuv_video + ' --output ' + coding_video + ' --verbose 0 ' 
os.system(cmd)
end_time = time.time()
print('END' + str(end_time - begin_time) + 's')

发现将log参数调整为0:None还是会在控制台输出长串的星号

使用python3 a.py得到输出:

Version: 1.2.208_release,  SHA-1: cd295084706a307f887dea18b53d4716795974d4
-----------------------------------------------------------------------------------------------------------------------------------
< Sequence's Info >
	resolution input         : 1280 x 720
	resolution coding        : 1280 x 720
	bitdepth input           : 8
	bitdepth coding          : 8
	frame rate               : 60 / 1
	intra picture period     : 60
	close_gop                : 0
	max b frames             : 15
	signature                : 0

< LookAhead Info >
	lookahead                : 40
	scenecut                 : 0
	schistogram              : 0
	adaptive_gop             : 0

< Parallel Info >
	WPP threads              : 6
	frame threads            : 40

< RC Info >
	RC type                  : 0 (0: CQP, 1: CRF, 2: ABR, 3: CBR)
	qp                       : 45
	qp_offset_cb             : 0
	qp_offset_cr             : 0

< CU split CFG >
	ctu_size:        128
	min_cu_size:     4
	max_part_ratio:  8
	max_split_times: 6
	min_qt_size:     8
	max_bt_size:     64
	max_eqt_size:    32
	max_dt_size:     16

< Tool CFG >
	Loop Filter:  deblock: 1, sao: 1, alf: 1, cross_patch: 1,
	Inter: AMVR(1) HMVP_NUM(8) AFFINE(1) SMVD(1) UMVE(1) EMVR(1)
	Intra: TSCPM(1) IPF(1) DT(1)
	Transform: PBT(1) SECTrans(1)
	Quant: WeightedQuant: 0
	ENC-Side Tools: chroma_qp(1) AQ(0)
	Speed_level: 3
************************************************************
************************************************************
****************************************************************************************
***********************************************************************************************************************************
(省略星号)

编码出来的文件用HPM解码报错

  1. 通过uavs3e编码出来的文件

meiguo_LD.zip

编码命令: uavs3e.exe -i D:\Material\meiguo_1024_576_420_8.yuv -w 1024 -h 576 -d 8 -f 200 --fps_num 25 --fps_den 1 -q 60 -o meiguo_LD.bin -r meiguo_LD_rec.yuv

  1. 通过HPM对上述编码出的文件解码,程序崩溃
    解码命令:decoder_app.exe -s -i D:\Code\AVS\uavs3e\bin\meiguo_LD.bin -o D:\Code\AVS\uavs3e\bin\meiguo_LD_dec.yuv

image
image

Build error

I'm getting the following build error:

[100%] Linking C executable uavs3enc
/usr/bin/ld: src/libuavs3e.so: undefined reference to `min'
/usr/bin/ld: src/libuavs3e.so: undefined reference to `max'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/uavs3enc.dir/build.make:104: uavs3enc] Error 1
make[2]: Leaving directory '/build/uavs3e-git/src/uavs3e/build/linux'
make[1]: *** [CMakeFiles/Makefile2:115: CMakeFiles/uavs3enc.dir/all] Error 2
make[1]: Leaving directory '/build/uavs3e-git/src/uavs3e/build/linux'
make: *** [Makefile:149: all] Error 2
make: Leaving directory '/build/uavs3e-git/src/uavs3e/build/linux'

A git bisect shows that is caused by commit 218528c.

I can confirm that it was building fine until commit 457b5c9.

System information:

OS: Arch Linux x86_64
Compiler: gcc 10.2.0
CMake: 3.19.2
glibc: 2.32

这个编码速度是不是太慢了

不知道是不是我参数哪了没设对,这个编码器的编码速度每一帧都要花好几秒?我能想到的和编码速度有关的参数就这些了。
//#========== speed/quality trade-off ==============
cfg->speed_level = 4;

//#========== parallel configuration ===============
cfg->wpp_threads         =   4;
cfg->frm_threads         =   4;

[参数说明]Command Line Options 添加与优化

〇 希望能够在编码器的参数中添加-h, --help的单参数:而不是每次都用./uavs3enc来调出

input[-i] is mandatory!
Configuration error, please refer to the usage.
< Usage >
  --config [STRING] (optional)
    : file name of configuration
  -i, --input [STRING]
……

从而调出usage界面

〇 希望能够有专门的一个网页对Command Line Options进行解释(命令行--help只调出简版的),类似x265 cli

〇 添加-V, --version的单参数

〇 添加 --speed_level [INTEGER] (optional) : Level of coding speed的可选范围,1至3应该可以选,再往上选会发生什么呢……

assertion fail at com_mv_mvr_check

when encode some stream, assert fail at src/me.c:42: com_mv_mvr_check: Assertion `0' failed.
[New Thread 0x7ffff54eb700 (LWP 9663)]
[New Thread 0x7fffe5a09700 (LWP 9664)]

uAVS3_gop编码视频偶现程序无法正常退出

现象描述:
使用RealTime分支Demo进行8k片源编码时,所有帧编码结束后,程序无法正常退出。
该问题为偶现问题。
无法退出时堆栈如下:
avs3_threadpool_wait
avs3_lib_free
avs3gop_lib_free
main

命令:
./uAVS3_gop -f ../encoder_ra.cfg -p InputFile=7680x4320_10bit.yuv -p OutputFile=./xx.avs3

环境:
CPU:ARM64
OS:openEuler release 22.03 LTS
GCC:10.3.1

[仓库分支]添加仓库分支说明

目前版本库**有master, Realtime, aq, cudetheqt, sobel_ql五个分支

在任何README.md中都没有关于这几个分支差异的说明,希望能在主分支的README中添加关于分支的说明

如果分支与master分支相差较大,希望能在该分支下添加README说明(如Realtime分支

如果分支无用,希望可以删减以精简项目

BUG report in scenecut-detection fuctions

if (h->cfg.scenecut) {
if (h->img_rlist[0].sc_ratio > sc_threshold) {
while (cur_ip_idx) {
double sc_ratio = loka_get_sc_ratio(&h->pinter, h->img_rlist[cur_ip_idx].img, h->img_lastIP, bit_depth);
if (sc_ratio <= sc_threshold) {
for (int i = 0; i <= cur_ip_idx; i++) {
h->img_rlist[i].sc_ratio = 0;
}
break;
}
cur_ip_idx--;
}
if (cur_ip_idx == 0) {
add_input_node(h, h->img_rlist[cur_ip_idx].img, 1, FRM_DEPTH_0, SLICE_I);
//
update_last_ip(h, h->img_rlist[cur_ip_idx].img, SLICE_I);
/
/
shift_reorder_list(h, cur_ip_idx);
return;
}
}
}

update_last_ip(h, h->img_rlist[cur_ip_idx].img, SLICE_I); should be added there after an I frame asserted in the node, or it might cause h->img_lastIP not updated and results in a series of errors.

CMakeLists.txt中lib及h文件安装目录设定有误

原因是使用了固定目录, 即/usr/include/与/usr/lib:
install(TARGETS uavs3e LIBRARY DESTINATION /usr/lib ARCHIVE DESTINATION /usr/lib)
install(FILES ../inc/uavs3e.h DESTINATION /usr/include/uavs3e/)
install(FILES ../inc/com_api.h DESTINATION /usr/include/uavs3e/)

而应为:
install(TARGETS uavs3e LIBRARY DESTINATION ${CMAKE_INSTALL_LIB_DIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIB_DIR})
install(FILES ../inc/uavs3e.h DESTINATION ${INSTALL_INCLUDE_DIR}/uavs3e/)
install(FILES ../inc/com_api.h DESTINATION ${INSTALL_INCLUDE_DIR}/uavs3e/)

若CMAKE_INSTALL_PREFIX为空, 才设为缺省值/usr.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.