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

[QUESTION] Missing fragments in get_images api #399

Open
david-molnar-oculai opened this issue Aug 23, 2023 · 5 comments
Open

[QUESTION] Missing fragments in get_images api #399

david-molnar-oculai opened this issue Aug 23, 2023 · 5 comments
Labels
question Further information is requested

Comments

@david-molnar-oculai
Copy link

We're using this producer library to send frames to AWS Kinesis Video. The stream's resolution is 2560x1920 and has 1 FPS with 1 Mbps max bitrate. The stream plays perfectly fine when using HLS streaming. No frames are missing. Also, requesting MP4 fragments for a specific time range works correctly. However, using the get_images from kinesis-video-archived-media fails with NO_MEDIA errors. Roughly 50% of the frames is missing. What could be the reasons for this? What should we check?

We set the frame.decodingTs and frame.presentationTs to the same value. Here is a list of the values for a 16 second clip:

1692794842005
1692794843005
1692794844005
1692794845005
1692794846005
1692794847005
1692794848005
1692794849005
1692794850005
1692794851005
1692794852005
1692794853005
1692794854005
1692794855005
1692794856005
1692794857005
@david-molnar-oculai david-molnar-oculai added the question Further information is requested label Aug 23, 2023
@disa6302
Copy link
Contributor

@david-molnar-oculai ,

Are you using the sample application? If not, are you enabling image generation in the SDK using this API?
https://github.com/awslabs/amazon-kinesis-video-streams-producer-c/blob/v1.4.1/samples/KvsAudioVideoStreamingSample.c#L79

@disa6302 disa6302 added the awaiting-response Awaiting for customers response label Aug 25, 2023
@david-molnar-oculai
Copy link
Author

david-molnar-oculai commented Aug 31, 2023

@disa6302 thank you for your reply. Yes, we used the sample application as a base (modified it slightly). I tried to call putKinesisVideoEventMetadata after every keyframe (every 16 frame = every 16 seconds), but it didn't make a big difference. Calling it more often, e.g. every 4 frame failed with 0x5200008b error code (this error code is missing from https://docs.aws.amazon.com/kinesisvideostreams/latest/dg/producer-sdk-errors.html). The missing fragment rate is around 45% now. What should the expected output to be? Should we expect an image every 16 seconds, if the sampling interval is 1 second?

@david-molnar-oculai
Copy link
Author

Producing a key frame every 4 frame (instead of every 16 frame) and calling putKinesisVideoEventMetadata fixes the problem.

@daveisfera
Copy link
Contributor

Also probably worth noting that GET_IMAGES usually doesn't return an image for the first result

@david-molnar-oculai
Copy link
Author

david-molnar-oculai commented Sep 11, 2023

It's fine, that not all images are returned. We have other sources, where the failure rate is around 15%, which is acceptable, but in our case it's 50%.

@niyatim23 niyatim23 removed the awaiting-response Awaiting for customers response label Nov 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants