chore: debug
Browse files- play_with_endpoint.py +6 -2
play_with_endpoint.py
CHANGED
@@ -86,15 +86,19 @@ for i in range(nb_samples):
|
|
86 |
"evaluation_keys": evaluation_keys,
|
87 |
}
|
88 |
|
|
|
|
|
89 |
# Run the inference on HF servers
|
90 |
duration -= time.time()
|
|
|
91 |
encrypted_prediction = query(payload)
|
|
|
92 |
duration += time.time()
|
93 |
|
94 |
-
encrypted_prediction = from_json(encrypted_prediction)
|
95 |
-
|
96 |
print(f"{encrypted_prediction=}")
|
97 |
|
|
|
|
|
98 |
if is_first:
|
99 |
is_first = False
|
100 |
print(f"Size of the payload: {sys.getsizeof(payload)} bytes")
|
|
|
86 |
"evaluation_keys": evaluation_keys,
|
87 |
}
|
88 |
|
89 |
+
print(f"{payload=}")
|
90 |
+
|
91 |
# Run the inference on HF servers
|
92 |
duration -= time.time()
|
93 |
+
print(f"Starting at {time.time()}")
|
94 |
encrypted_prediction = query(payload)
|
95 |
+
print(f"Ending at {time.time()}")
|
96 |
duration += time.time()
|
97 |
|
|
|
|
|
98 |
print(f"{encrypted_prediction=}")
|
99 |
|
100 |
+
encrypted_prediction = encrypted_prediction
|
101 |
+
|
102 |
if is_first:
|
103 |
is_first = False
|
104 |
print(f"Size of the payload: {sys.getsizeof(payload)} bytes")
|