Changing Image Algorithm to Bilinear#4159
Merged
willhuang1997 merged 7 commits intostreamlit:developfrom Dec 27, 2021
Merged
Conversation
vdonato
approved these changes
Dec 21, 2021
3dc24fe to
9a80bc1
Compare
tconkling
added a commit
to tconkling/streamlit
that referenced
this pull request
Jan 3, 2022
* develop: Fix hello demo type annotation (streamlit#4228) Release 1.3.1 (streamlit#4220) Improve beta_ deprecation message (streamlit#4219) Changing Image Algorithm to Bilinear (streamlit#4159) Allow columns to be rendered to create spacing (streamlit#4217) Fix issue with hidden balloons (approach 2) (streamlit#4204) Fix mypy errors from 0.930 release (streamlit#4218) Fix/selectbox typings (streamlit#4194) Support running tests locally on Apple Silicon (streamlit#4185) Stop screencast recorder when user removes permission / stops using browser button. (streamlit#4180)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Did some testing and Lanczos is the best algorithm to resize but it's a bit slower but NOT that much slower (maybe 10% slower than Bicubic but a little bit better quality). Especially since I don't think Streamlit users will be using st.image that many times for the performance to take a hit.
For now, the Streamlit team has agreed to use bilinear since that's what other browsers are using and the difference in quality is not very noticeable.
Notion doc down below.

Adding notion doc: https://www.notion.so/streamlit/f820815df991408789cfbed1b2b4d3f3?v=3a50f3730b1543b3bc0682d6f193a863
Note: The experimentation is only done on localhost. I haven't tried it on cloud.