orreryspaceapp / test.py
Sushan
Model deployed
7aa2125
raw
history blame
478 Bytes
import requests
# URL of the deployed API (replace with your actual space URL)
url = "https://<your-space-name>.hf.space/predict"
# Sample input data
data = {
"absolute_magnitude_h": 22.1,
"estimated_diameter_min_km": 0.127,
"estimated_diameter_max_km": 0.285,
"relative_velocity_km_per_sec": 5.67,
"miss_distance_km": 386000.0
}
# Make a request to the API
response = requests.post(url, json=data)
# Display the prediction result
print(response.json())