head_pose_estimation_tracking_app / utils /streamlit_options.py
manhdo's picture
Clean code and fix out of boundary prediction box
aef4429
Raw History Blame Contribute Delete
1.33 kB
import streamlit as st
def default_UI():
st.file_uploader("Upload image file or directory:", key="img_upload", accept_multiple_files=True)
st.checkbox("Turn on **precise visualization**", key="turn_on_visualize")
st.checkbox("Viualize **position box**", key="show_rectangle_position")
st.radio(
"Select sample size for model input and save output:",
key="img_size",
options=[
"512x512",
"640x640",
"1280x1280",
],
index=1
)
st.slider(
"Select sample width size for visualization:",
key="width_visual",
min_value=80, max_value=1000,
value=560,
)
st.checkbox("Show all **main** faces", key="show_all_main_faces")
st.checkbox("Show all **sub** faces", key="show_all_sub_faces")
st.write("**Advanced options**")
st.slider(
"Adjust position horizontal thresholds:",
key="position_horizontal_thresholds",
min_value=0.0, max_value=1.0,
value=(0.33, 0.66),
)
st.slider(
"Adjust position vertical thresholds:",
key="position_vertical_thresholds",
min_value=0.0, max_value=1.0,
value=(0.33, 0.66),
)
st.checkbox(
"Using **local cache** for results saving",
key="using_local_cache"
)