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

width and height of gr.Video doesn't seem to be working properly #4895

Closed
1 task done
hysts opened this issue Jul 12, 2023 · 1 comment · Fixed by #4946
Closed
1 task done

width and height of gr.Video doesn't seem to be working properly #4895

hysts opened this issue Jul 12, 2023 · 1 comment · Fixed by #4946
Assignees
Labels
bug Something isn't working

Comments

@hysts
Copy link
Collaborator

hysts commented Jul 12, 2023

Describe the bug

Maybe related to my 1 year old issue, but when specifying height in gr.Video, the video will be cut off if the height of the video is larger than the width. Also, width doesn't seem to be working.

Have you searched existing issues? 🔎

  • I have searched and found no existing issues

Reproduction

https://huggingface.co/spaces/hysts-debug/video-size

import gradio as gr

with gr.Blocks() as demo:
    with gr.Row():
        gr.Video('data/dog0.mp4')
        gr.Video('data/dog1.mp4')
    with gr.Row():
        gr.Video('data/dog0.mp4', height=400)
        gr.Video('data/dog1.mp4', height=400)
    with gr.Row():
        gr.Video('data/dog0.mp4', width=100, min_width=100)
        gr.Video('data/dog1.mp4', width=100, min_width=100)

demo.queue().launch()

Screenshot

No response

Logs

No response

System Info

gradio==3.36.1

Severity

I can work around it

@hysts hysts added the bug Something isn't working label Jul 12, 2023
@abidlabs abidlabs added this to the Component Cleanup milestone Jul 12, 2023
@hannahblair
Copy link
Collaborator

I'll look into this. I've got a fix for #1641 so I'll see if it addresses this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants