import requests import json # Replace with your actual Space URL API_URL = "https://shorndrup-owlvit-api.hf.space/predict" image_path = "C:/Users/Administrator/Downloads/pokedex/images/solrock.png" with open(image_path, "rb") as image_file: files = {"data": image_file} response = requests.post(API_URL, files=files) # Print the raw response content for debugging print(response.text) # Try parsing JSON if the response is valid JSON print(response.json())