From 62aad057cbf962a0bf56629fe70f046b7d79f3a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=B1=BC=E9=AA=A8=E5=89=AA?= <1580622474@qq.com> Date: Thu, 8 Aug 2024 22:46:26 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=9D=E6=AD=A5=E5=AE=9E=E7=8E=B0=E4=BA=86?= =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E5=99=A8=E6=95=B0=E6=8D=AE=E7=9A=84=E6=98=BE?= =?UTF-8?q?=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.py | 2 +- index.html | 74 ++++++++++++++++++++++++++++++++++++++++++++++++------ 2 files changed, 68 insertions(+), 8 deletions(-) diff --git a/app.py b/app.py index d4852ee..3dc9ae4 100644 --- a/app.py +++ b/app.py @@ -25,7 +25,7 @@ data_dict = dict() def hello(): return 'hi. —— CheckGPUsWeb' -@app.route('/data', methods=['GET']) +@app.route('/all_data', methods=['GET']) def get_data(): return jsonify(get_all_data()) diff --git a/index.html b/index.html index 7e20b05..e63498d 100644 --- a/index.html +++ b/index.html @@ -3,26 +3,86 @@ - Fetch JSON from Flask + Server and GPU Information + -

Fetch JSON from Flask Example

- -
+

Server and GPU Information

+