Spaces:
Sleeping
Sleeping
TuanScientist
commited on
Commit
•
0841602
1
Parent(s):
ac3c529
Update app.py
Browse files
app.py
CHANGED
@@ -6,7 +6,7 @@ import warnings
|
|
6 |
set_log_level("ERROR")
|
7 |
warnings.filterwarnings("ignore", category=UserWarning)
|
8 |
|
9 |
-
url = "
|
10 |
df = pd.read_csv(url)
|
11 |
df = df[["Date", "Price"]]
|
12 |
df = df.rename(columns={"Date": "ds", "Price": "y"})
|
@@ -43,13 +43,13 @@ def predict_vn_index(option=None):
|
|
43 |
|
44 |
|
45 |
if __name__ == "__main__":
|
46 |
-
dropdown = gr.inputs.Dropdown(["
|
47 |
outputs = [
|
48 |
-
gr.outputs.Image(type="filepath", label="Lịch sử
|
49 |
-
gr.outputs.Image(type="filepath", label="Dự đoán
|
50 |
gr.outputs.Textbox(label="Mô tả"),
|
51 |
gr.outputs.Textbox(label="Disclaimer")
|
52 |
]
|
53 |
-
interface = gr.Interface(fn=predict_vn_index, inputs=dropdown, outputs=outputs, title="Dự báo
|
54 |
interface.launch()
|
55 |
|
|
|
6 |
set_log_level("ERROR")
|
7 |
warnings.filterwarnings("ignore", category=UserWarning)
|
8 |
|
9 |
+
url = "XAU_USD Historical Data.csv"
|
10 |
df = pd.read_csv(url)
|
11 |
df = df[["Date", "Price"]]
|
12 |
df = df.rename(columns={"Date": "ds", "Price": "y"})
|
|
|
43 |
|
44 |
|
45 |
if __name__ == "__main__":
|
46 |
+
dropdown = gr.inputs.Dropdown(["GOLD/USD"], label="Choose an option", default="GOLD/USD")
|
47 |
outputs = [
|
48 |
+
gr.outputs.Image(type="filepath", label="Lịch sử GOLD và dự đoán"),
|
49 |
+
gr.outputs.Image(type="filepath", label="Dự đoán GOLD cho 90 ngày tới"),
|
50 |
gr.outputs.Textbox(label="Mô tả"),
|
51 |
gr.outputs.Textbox(label="Disclaimer")
|
52 |
]
|
53 |
+
interface = gr.Interface(fn=predict_vn_index, inputs=dropdown, outputs=outputs, title="Dự báo GOLD/USD 90 ngày tới")
|
54 |
interface.launch()
|
55 |
|