gradio: The file uploading speed is way slower in Gradio 4 than in Gradio 3
Describe the bug
I am using gr.File(…) to upload DXF file as input for the next step. But I noticed that the uploading speed is super slow when I upgrade my gradio 3.34.0 to gradio 4.4.0/4.5.0. To upload a file around 300KB, the previous uploading time is <100ms, but now it is around 5-10 seconds.
Any clue to explain this or solve this?
Have you searched existing issues? 🔎
- I have searched and found no existing issues
Reproduction
with gr.Blocks(title='demo') as demo:
file_input = gr.File(file_types=['.dxf'], label='Please select a dxf file')
demo.launch(show_error=True, auth=('test','test'))
Screenshot
No response
Logs
No response
System Info
python 3.10.12
gradio 4.4.0/4.5.0
Severity
I can work around it
About this issue
- Original URL
- State: open
- Created 7 months ago
- Comments: 24 (5 by maintainers)
I’m having the same problem. But when I use shitft+f5 and crt+R to clear the cache, upload returns to normal.
We have not been able to repro on windows @yimin-demo !(cc @yvrjsharma )
Does this happen with all browsers? Are there other processes running on your computer maybe? Don’t have a good idea for the culprit right now.