Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -204,7 +204,10 @@ val_data = features.loc[train_split:]
|
|
204 |
start = past + future
|
205 |
end = start + train_split
|
206 |
|
207 |
-
|
|
|
|
|
|
|
208 |
y_train = features.iloc[start:end][[1]]
|
209 |
|
210 |
sequence_length = int(past / step)
|
@@ -212,7 +215,10 @@ x_end = len(val_data) - past - future
|
|
212 |
|
213 |
label_start = train_split + past + future
|
214 |
|
215 |
-
|
|
|
|
|
|
|
216 |
y_val = features.iloc[label_start:][[1]]
|
217 |
|
218 |
dataset_val = keras.preprocessing.timeseries_dataset_from_array(
|
@@ -263,4 +269,3 @@ fig = plot()
|
|
263 |
st.pyplot(fig)
|
264 |
|
265 |
# %%
|
266 |
-
|
|
|
204 |
start = past + future
|
205 |
end = start + train_split
|
206 |
|
207 |
+
if ("0" == "mycustom"):
|
208 |
+
x_train = train_data[[i for i in range(7)]].values
|
209 |
+
if ("0" != "mycustom"):
|
210 |
+
x_train = train_data[[i for i in range(myfields.len())]].values
|
211 |
y_train = features.iloc[start:end][[1]]
|
212 |
|
213 |
sequence_length = int(past / step)
|
|
|
215 |
|
216 |
label_start = train_split + past + future
|
217 |
|
218 |
+
if ("0" == "mycustom"):
|
219 |
+
x_val = val_data.iloc[:x_end][[i for i in range(7)]].values
|
220 |
+
if ("0" != "mycustom"):
|
221 |
+
x_val = val_data.iloc[:x_end][[i for i in range(myfields.len())]].values
|
222 |
y_val = features.iloc[label_start:][[1]]
|
223 |
|
224 |
dataset_val = keras.preprocessing.timeseries_dataset_from_array(
|
|
|
269 |
st.pyplot(fig)
|
270 |
|
271 |
# %%
|
|