streamlit-image-select
streamlit-image-select copied to clipboard
image_select cant load any images as it is not on the line of code
I am using image_select multiple times for my form input, however, the image can't load for the first time, I need to go to another page and back to the form input page so the image can properly appear as it should. Fortunately, this happens only in Google Chrome and not in Mozilla Firefox.
This is my form input:
with st.form("user_input"): st.subheader("User Input", anchor=False) color_input = st.selectbox("Hair Color", options=color_value) hair_base_input = image_select("Hair base", hair_image, hair_base_value, return_value="index") hair_middle_input = image_select("Hair middle", hair_image, hair_middle_value, return_value="index") hair_tip_input = image_select("Hair tip", hair_tip_image, hair_tip_value, return_value="index") medula_base_input = image_select("Medula base", medula_base_image, medula_base_value, return_value="index") medula_middle_input = image_select("Medula middle", medula_middle_image, medula_middle_value, return_value="index") medula_tip_input = image_select("Medula tip", medula_tip_image, medula_tip_value, return_value="index") st.image('static/diameter.jpg', caption="DM: Diameter Medula, DR: Diameter Rambut, Index medula: DM/DR") d_rambut_input = st.number_input("Diameter rambut",step=0) d_medula_input = st.number_input("Diameter medula",step=0) index_medula_input = st.number_input("index medula",step=1e-7,format="%.6f")
the form should appear like this:
but in Chrome:
Please help, Thanks