diff --git a/configs/webui/webui_streamlit.yaml b/configs/webui/webui_streamlit.yaml index c6d2bc3..c8c8719 100644 --- a/configs/webui/webui_streamlit.yaml +++ b/configs/webui/webui_streamlit.yaml @@ -62,6 +62,9 @@ general: update_preview: True update_preview_frequency: 10 +debug: + enable_hydralit: False + txt2img: prompt: width: diff --git a/scripts/sd_utils.py b/scripts/sd_utils.py index 9ef0ca0..183b850 100644 --- a/scripts/sd_utils.py +++ b/scripts/sd_utils.py @@ -120,8 +120,9 @@ if st.session_state["defaults"].daisi_app.running_on_daisi_io: modeldownload.updateModels() # -#app = st.HydraApp(title='Stable Diffusion WebUI', favicon="", sidebar_state="expanded", - #hide_streamlit_markers=False, allow_url_nav=True , clear_cross_app_sessions=False) +#if st.session_state["defaults"].debug.enable_hydralit: +app = st.HydraApp(title='Stable Diffusion WebUI', favicon="", sidebar_state="expanded", layout="wide", + hide_streamlit_markers=False, allow_url_nav=True , clear_cross_app_sessions=False) # should and will be moved to a settings menu in the UI at some point diff --git a/scripts/webui_streamlit.py b/scripts/webui_streamlit.py index 63002ec..cd2a478 100644 --- a/scripts/webui_streamlit.py +++ b/scripts/webui_streamlit.py @@ -88,10 +88,13 @@ def load_css(isLocal, nameOrURL): else: remote_css(nameOrURL) +@app.addapp("App") def layout(): """Layout functions to define all the streamlit layout here.""" - st.set_page_config(page_title="Stable Diffusion Playground", layout="wide") - #app = st.HydraApp(title='Stable Diffusion WebUI', favicon="", sidebar_state="expanded", + if not st.session_state["defaults"].debug.enable_hydralit: + st.set_page_config(page_title="Stable Diffusion Playground", layout="wide") + + #app = st.HydraApp(title='Stable Diffusion WebUI', favicon="", sidebar_state="expanded", layout="wide", #hide_streamlit_markers=False, allow_url_nav=True , clear_cross_app_sessions=False) with st.empty(): @@ -144,6 +147,10 @@ def layout(): from img2img import layout layout() + #with inpainting_tab: + #from inpainting import layout + #layout() + with txt2vid_tab: from txt2vid import layout layout() @@ -174,4 +181,8 @@ def layout(): layout() if __name__ == '__main__': - layout() \ No newline at end of file + + if st.session_state["defaults"].debug.enable_hydralit: + app.run() + else: + layout()