Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -125,20 +125,20 @@ def proof(name):
|
|
125 |
add_transaction(get_id_from_p2p(peer), "out", 0)
|
126 |
|
127 |
def get_coin(id):
|
128 |
-
c =
|
129 |
return c
|
130 |
|
131 |
|
132 |
def get_gpus():
|
133 |
outout = []
|
134 |
-
for id, mem in
|
135 |
outout.append({"name":get_name(id),"gpu":mem})
|
136 |
return output
|
137 |
|
138 |
def get_data():
|
139 |
output = []
|
140 |
output.append({"gpus":get_gpus()})
|
141 |
-
output.append({"total":{"total" :
|
142 |
output.append({"chain":blockchain.chain})
|
143 |
return output
|
144 |
|
|
|
125 |
add_transaction(get_id_from_p2p(peer), "out", 0)
|
126 |
|
127 |
def get_coin(id):
|
128 |
+
c = blockchain.get_user_balance(id)
|
129 |
return c
|
130 |
|
131 |
|
132 |
def get_gpus():
|
133 |
outout = []
|
134 |
+
for id, mem in blockchain.user_gpus.items():
|
135 |
outout.append({"name":get_name(id),"gpu":mem})
|
136 |
return output
|
137 |
|
138 |
def get_data():
|
139 |
output = []
|
140 |
output.append({"gpus":get_gpus()})
|
141 |
+
output.append({"total":{"total" : blockchain.get_total_gpu_mem, "used":38}})
|
142 |
output.append({"chain":blockchain.chain})
|
143 |
return output
|
144 |
|