-
Notifications
You must be signed in to change notification settings - Fork 58
[DLStreamer] gvagenai: enable memory mapper, add support for prompt-path #938
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
base: main
Are you sure you want to change the base?
Conversation
auto gst_frame = std::make_shared<dlstreamer::GSTFrame>(buffer, info); | ||
auto mapped_frame = mapper->map(gst_frame, dlstreamer::AccessMode::Read); | ||
|
||
// Convert to Mat, code from gvawatermark |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Conversion of VAMemory / DMABuf to OpenCV Mat will involve memory copy.
Please add support for remote tensors instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RemoteTensor is not supported. See CVS-160602
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is GPU memory not supported at all, or the limitation is lack of ov::preprocessor in genai front-end?
We should be able to generate RGB or BGR images in VAMemory, and create tensor wrappers around.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both. VAAPI surface doesn't support 24 bits RGB or BGR, only supports 32 bits RGBA or BGRA.
For GenAI, the image encoding (preprocessing) handles the data on CPU. See classes.cpp llava_image_embed_make_with_bytes_slice
and resample
functions.
Also the VLMPipeline
class doesn't expose RemoteContext
, also RemoteContext
cannot be passed into VLMPipeline
, so no way to create a RemoteTensor
.
Description
Enabled memory mapper for gvagenai so it supports VAMemory, VASurface, DMABuf frames now.
Add support for prompt-path.
Any Newly Introduced Dependencies
None
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Checklist: