mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-27 02:30:17 +08:00
35f58db405
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
4.3 KiB
4.3 KiB
@gradio/upload
0.3.4
Patch Changes
- Updated dependencies [
465f58957
]:- @gradio/atoms@0.2.1
0.3.3
Patch Changes
- Updated dependencies [
e70805d54
]:- @gradio/atoms@0.2.0
0.3.2
Patch Changes
- Updated dependencies []:
- @gradio/atoms@0.1.4
0.3.1
Patch Changes
- Updated dependencies [
8f0fed857
]:- @gradio/icons@0.2.0
- @gradio/atoms@0.1.3
0.3.0
Features
- #5554
75ddeb390
- Accessibility Improvements. Thanks @hannahblair!
0.2.1
Patch Changes
- Updated dependencies []:
- @gradio/atoms@0.1.2
0.2.0
Features
- #5373
79d8f9d8
- Addsheight
andzoom_speed
parameters toModel3D
component, as well as a button to reset the camera position. Thanks @abidlabs!
0.1.0
Highlights
Improve startup performance and markdown support (#5279 fe057300
)
Improved markdown support
We now have better support for markdown in gr.Markdown
and gr.Dataframe
. Including syntax highlighting and Github Flavoured Markdown. We also have more consistent markdown behaviour and styling.
Various performance improvements
These improvements will be particularly beneficial to large applications.
- Rather than attaching events manually, they are now delegated, leading to a significant performance improvement and addressing a performance regression introduced in a recent version of Gradio. App startup for large applications is now around twice as fast.
- Optimised the mounting of individual components, leading to a modest performance improvement during startup (~30%).
- Corrected an issue that was causing markdown to re-render infinitely.
- Ensured that the
gr.3DModel
does re-render prematurely.
Thanks @pngwn!
Features
- #5216
4b58ea6d
- Update i18n tokens and locale files. Thanks @hannahblair!
Fixes
0.0.3
Fixes
highlight:
Now supports loading streamed outputs
Allows users to use generators to stream audio out, yielding consecutive chunks of audio. Requires streaming=True
to be set on the output audio.
import gradio as gr
from pydub import AudioSegment
def stream_audio(audio_file):
audio = AudioSegment.from_mp3(audio_file)
i = 0
chunk_size = 3000
while chunk_size*i < len(audio):
chunk = audio[chunk_size*i:chunk_size*(i+1)]
i += 1
if chunk:
file = f"/tmp/{i}.mp3"
chunk.export(file, format="mp3")
yield file
demo = gr.Interface(
fn=stream_audio,
inputs=gr.Audio(type="filepath", label="Audio file to stream"),
outputs=gr.Audio(autoplay=True, streaming=True),
)
demo.queue().launch()
From the backend, streamed outputs are served from the /stream/
endpoint instead of the /file/
endpoint. Currently just used to serve audio streaming output. The output JSON will have is_stream
: true
, instead of is_file
: true
in the file data object. Thanks @aliabid94!
0.0.2
Patch Changes
- Updated dependencies []:
- @gradio/atoms@0.0.2