f64 commited on
Commit
bf0d601
·
1 Parent(s): ec0290b
CTAPT.py CHANGED
@@ -1,7 +1,8 @@
1
  import os, re, sys, time, math, shutil, urllib, string, random, pickle, zipfile, datetime, platform, psutil
2
  import streamlit as st, pandas as pd, numpy as np
3
 
4
- st.set_page_config(page_title="Предсказание V", page_icon="🦋", layout="wide", initial_sidebar_state="expanded")
 
5
  # set_page_config() can only be called once per app page, and must be called as the first Streamlit command in your script.
6
 
7
  import my_static_tools as mst
@@ -27,6 +28,7 @@ st.sidebar.markdown(f"Your favorite command is **{favorite_command}** 🎚️")
27
  with st.container():
28
  cols1 = st.columns([4,4,4,4])
29
  dirParams = {
 
30
  "os.getcwd": os.getcwd(),
31
  "cpu_count": os.cpu_count(),
32
  #"environ": os.environ,
 
1
  import os, re, sys, time, math, shutil, urllib, string, random, pickle, zipfile, datetime, platform, psutil
2
  import streamlit as st, pandas as pd, numpy as np
3
 
4
+ st.set_page_config(page_title="Стартовая страница", page_icon="🦋", layout="wide", initial_sidebar_state="expanded")
5
+ # This must be the first Streamlit command used on an app page, and must only be set once per page.
6
  # set_page_config() can only be called once per app page, and must be called as the first Streamlit command in your script.
7
 
8
  import my_static_tools as mst
 
28
  with st.container():
29
  cols1 = st.columns([4,4,4,4])
30
  dirParams = {
31
+ "psutil.virtual_memory": psutil.virtual_memory(),
32
  "os.getcwd": os.getcwd(),
33
  "cpu_count": os.cpu_count(),
34
  #"environ": os.environ,
pages/2_TECT_IDXYZ.py CHANGED
@@ -4,6 +4,7 @@ import my_static_tools as mst
4
  from my_static_tools import HF_tools as hft
5
  from my_static_tools import XYZV_tools as xvt
6
 
 
7
 
8
  if True:
9
  st.html(mst.STYLE_CORRECTION)
 
4
  from my_static_tools import HF_tools as hft
5
  from my_static_tools import XYZV_tools as xvt
6
 
7
+ st.set_page_config(page_title="Прогноз XYZV", page_icon="📜", layout="wide", initial_sidebar_state="expanded")
8
 
9
  if True:
10
  st.html(mst.STYLE_CORRECTION)
pages/4_Загрузка Просмотр CSV.py CHANGED
@@ -6,6 +6,8 @@ import my_static_tools as mst
6
  from my_static_tools import HF_tools as hft
7
  from my_static_tools import XYZV_tools as xvt
8
 
 
 
9
  st.html(mst.STYLE_CORRECTION)
10
  REPO = mst.HfRepo("f64k/gaziev", "dataset", st.secrets["HF_WRITE"])
11
 
@@ -14,12 +16,12 @@ st.sidebar.markdown("# 🧊 Просмотр")
14
 
15
  def st_rerun():
16
  try:
17
- #st.rerun()
18
- st.experimental_rerun()
19
  except Exception as exRerun:
20
  print(exRerun)
21
 
22
- @st.experimental_dialog("Сохранение Dataframe в репозиторий")
23
  def save_dataframe_dialog_start(new_filename, dfToSave):
24
  st.write(f"Файл '{new_filename}' будет сохранён")
25
  cnt_msg = st.container()
@@ -29,7 +31,8 @@ def save_dataframe_dialog_start(new_filename, dfToSave):
29
  cnt_msg.write(commit_info)
30
  #st_rerun()
31
  if d_cols[0].button("Закрыть"):
32
- st_rerun()
 
33
 
34
  tab1,tab2 = st.tabs(["💾 Загрузка локального файла на сервер", "🧊 Просмотр загруженных файлов"])
35
 
 
6
  from my_static_tools import HF_tools as hft
7
  from my_static_tools import XYZV_tools as xvt
8
 
9
+ st.set_page_config(page_title="Загрузка + Просмотр", page_icon="💾", layout="wide", initial_sidebar_state="expanded")
10
+
11
  st.html(mst.STYLE_CORRECTION)
12
  REPO = mst.HfRepo("f64k/gaziev", "dataset", st.secrets["HF_WRITE"])
13
 
 
16
 
17
  def st_rerun():
18
  try:
19
+ st.rerun() # To close the modal dialog programmatically, call st.rerun() explicitly inside of the dialog function
20
+ #st.experimental_rerun()
21
  except Exception as exRerun:
22
  print(exRerun)
23
 
24
+ @st.dialog("Сохранение Dataframe в репозиторий") # @st.experimental_dialog("Сохранение Dataframe в репозиторий")
25
  def save_dataframe_dialog_start(new_filename, dfToSave):
26
  st.write(f"Файл '{new_filename}' будет сохранён")
27
  cnt_msg = st.container()
 
31
  cnt_msg.write(commit_info)
32
  #st_rerun()
33
  if d_cols[0].button("Закрыть"):
34
+ st.rerun() # To close the modal dialog programmatically, call st.rerun() explicitly inside of the dialog function
35
+
36
 
37
  tab1,tab2 = st.tabs(["💾 Загрузка локального файла на сервер", "🧊 Просмотр загруженных файлов"])
38
 
pages/6_Chat.py CHANGED
@@ -6,6 +6,7 @@ import my_static_tools as mst
6
  from my_static_tools import HF_tools as hft
7
  from my_static_tools import XYZV_tools as xvt
8
 
 
9
 
10
  # https://docs.gspread.org/en/latest/user-guide.html#updating-cells
11
  # https://docs.streamlit.io/develop/tutorials/databases/private-gsheet
 
6
  from my_static_tools import HF_tools as hft
7
  from my_static_tools import XYZV_tools as xvt
8
 
9
+ st.set_page_config(page_title="Чат страница недоделанная", page_icon="💬", layout="wide", initial_sidebar_state="expanded")
10
 
11
  # https://docs.gspread.org/en/latest/user-guide.html#updating-cells
12
  # https://docs.streamlit.io/develop/tutorials/databases/private-gsheet