Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Got incorrect bitstream in encoding VP9 8K #1847

Closed
Shao-Feng opened this issue Aug 27, 2024 · 10 comments
Closed

[Bug]: Got incorrect bitstream in encoding VP9 8K #1847

Shao-Feng opened this issue Aug 27, 2024 · 10 comments
Assignees
Labels
Encode video encode related KMD KMD related, or has dependence VP9 VP9

Comments

@Shao-Feng
Copy link
Contributor

Which component impacted?

Encode

Is it regression? Good in old configuration?

No, this issue exist a long time

What happened?

On Android,
with media-driver intel-media-24.1.5, and intel-gmmlib-22.3.18

Running oneVPL example "hello-encode" with the change projectceladon/libvpl#16
for encoding VP9 7680x4320 video. The bitstream is incorrect.
The input is generated with ffmpeg cmd below

ffmpeg -v verbose -f lavfi -i testsrc=size=7680x4320:rate=1 -pix_fmt yuv420p -vframes 5 -y test.yuv

On Ubuntu with the media-driver and gmmlib, this issue can not be reproduced.

The Codec dump on Android and Ubuntu is below
T1829561088_ubuntu_8k.zip
T1389417720_android_8K.zip

What's the usage scenario when you are seeing the problem?

Video Conference

What impacted?

Fail to encode VP9 video in 8K.
No problem to encode VP9 video in 4K
and no problem to encode H264 and H265 video

Debug Information

No response

Do you want to contribute a patch to fix the issue?

None

@Shao-Feng
Copy link
Contributor Author

@intel intel deleted a comment Aug 27, 2024
@intel intel deleted a comment Aug 27, 2024
@Shao-Feng
Copy link
Contributor Author

Shao-Feng commented Aug 28, 2024

After disable scalability as below, this issue is not reproduced.

diff --git a/media_driver/agnostic/common/codec/hal/codechal_hw.h b/media_driver/agnostic/common/codec/hal/codechal_hw.h
index 6d3c07ac7..590e830be 100644
--- a/media_driver/agnostic/common/codec/hal/codechal_hw.h
+++ b/media_driver/agnostic/common/codec/hal/codechal_hw.h
@@ -1634,7 +1634,8 @@ public:
bool IsDisableScalability()
{
- return m_disableScalability;
+ return true;
}

This issue is caused by enabling scalability for 8K VP9 encoding.

@leyu-yao
Copy link
Contributor

@Shao-Feng May I know which platform you are working on?

@Shao-Feng
Copy link
Contributor Author

On RPL, Gen12

Shao-Feng added a commit to Shao-Feng/media-driver that referenced this issue Aug 28, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
@Shao-Feng
Copy link
Contributor Author

This issue only can be reproduced with kernel 6.1.80.
On Ubuntu with kernel 6.5.0-45, this issue is not reproduced.
When this issue happen, scalability is enabled, and number of VDBox is 2.
with kernel 6.1.80, the second VDBox did not work as expected, and the right half part of the bitstream shown on ViCue is incorrect, I suppose the right half part are encoded by the second VDBox.
With kernel 6.5.0-45, the right half part are encoded correcly as the left half

@bai-isaac
Copy link
Contributor

thanks shao feng for experiment!
Have one more question, for good result with kernel 6.5.0-45, scalability is disabled or enabled?

@Shao-Feng
Copy link
Contributor Author

thanks shao feng for experiment! Have one more question, for good result with kernel 6.5.0-45, scalability is disabled or enabled?

Enabled and run encoding with 2 VDBox

@bai-isaac bai-isaac added KMD KMD related, or has dependence VP9 VP9 Encode video encode related labels Sep 2, 2024
@intel-mediadev
Copy link
Contributor

Auto Created VSMGWL-75955 for further analysis.

Shao-Feng added a commit to Shao-Feng/media-driver that referenced this issue Sep 3, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
@Jexu
Copy link
Contributor

Jexu commented Sep 9, 2024

Pls check the release note, RPL starts fron kernel 6.2.

ADL-N/RPL-S/RPL-P: starting from kernel 6.2

@Shao-Feng
Copy link
Contributor Author

Thanks for checking it. Probably this issue is caused by the GuC of SRIOV VF. Close this one. I will check on local

sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Sep 13, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Sep 13, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Sep 13, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
lsun30 pushed a commit to lsun30/media-driver that referenced this issue Dec 6, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>
(cherry picked from commit a059ab2)
Signed-off-by: Lina Sun <[email protected]>
lsun30 pushed a commit to lsun30/media-driver that referenced this issue Dec 10, 2024
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>

(cherry picked from commit a059ab2)
Tracked-On: OAM-128364
Signed-off-by: Lina Sun <[email protected]>
sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Jan 6, 2025
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>

(cherry picked from commit a059ab2)
Tracked-On: OAM-128364
Signed-off-by: Lina Sun <[email protected]>
sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Jan 6, 2025
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>

(cherry picked from commit a059ab2)
Tracked-On: OAM-128364
Signed-off-by: Lina Sun <[email protected]>
sysopenci pushed a commit to projectceladon/media-driver that referenced this issue Jan 6, 2025
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>

(cherry picked from commit a059ab2)
Tracked-On: OAM-128364
Signed-off-by: Lina Sun <[email protected]>
JeevakaPrabu pushed a commit to projectceladon/media-driver that referenced this issue Jan 29, 2025
In VP9 8K encoding case, scalability is enabled. and make encoding incorrect.
Issue is reported to upstream on intel/media-driver#1847

Tracked-On: OAM-123073
Signed-off-by: Shaofeng Tang <[email protected]>

(cherry picked from commit a059ab2)
Tracked-On: OAM-128364
Signed-off-by: Lina Sun <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Encode video encode related KMD KMD related, or has dependence VP9 VP9
Projects
None yet
Development

No branches or pull requests

7 participants
@Shao-Feng @Jexu @leyu-yao @XinfengZhang @intel-mediadev @bai-isaac and others