dataClassification / interact.py
G3
update
3ae22f3
Raw
History Blame Contribute Delete
385 Bytes
import requests
# URL to the Gradio Space API
url = "https://your-username-your-space-name.hf.space/api/predict"
# Path to your Excel file
file_path = "/path/to/your/input_file.xlsx"
# Read the file in binary mode
with open(file_path, "rb") as file:
files = {"data": file}
response = requests.post(url, files=files)
# Print the response from the API
print(response.json())