azizalto commited on
Commit
b0174c1
1 Parent(s): 2a32d74

Re-align input layout

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -16,7 +16,8 @@ class InputData:
16
  Returns:
17
 
18
  """
19
- sample = st.selectbox(
 
20
  "Sample datasets",
21
  options=["", "sample1", "sample2", "avg_daily_air_temp_celsius_helsinki"],
22
  )
@@ -24,15 +25,14 @@ class InputData:
24
  file_ = f"data/{sample}.csv"
25
  return pd.read_csv(file_)
26
 
27
- uploaded_data = cls.read_file()
28
  if uploaded_data is not None:
29
  return uploaded_data
30
 
31
  @classmethod
32
- def read_file(cls):
33
- global DATE_FORMATTER
34
 
35
- file_ = st.file_uploader("Upload your dataset (csv file)")
36
  if not file_:
37
  st.stop()
38
 
 
16
  Returns:
17
 
18
  """
19
+ st1, st2 = st.columns(2)
20
+ sample = st1.selectbox(
21
  "Sample datasets",
22
  options=["", "sample1", "sample2", "avg_daily_air_temp_celsius_helsinki"],
23
  )
 
25
  file_ = f"data/{sample}.csv"
26
  return pd.read_csv(file_)
27
 
28
+ uploaded_data = cls.read_file(st2)
29
  if uploaded_data is not None:
30
  return uploaded_data
31
 
32
  @classmethod
33
+ def read_file(cls, st_):
 
34
 
35
+ file_ = st_.file_uploader("Upload your dataset (csv file)")
36
  if not file_:
37
  st.stop()
38