Shafeek Saleem
added template files
0cba43f
raw
history blame
358 Bytes
import requests
API_URL = "https://api-inference.huggingface.co/models/CynthiaCR/emotions_classifier"
headers = {"Authorization": "Bearer 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"}
def query(filename):
with open(filename, "rb") as f:
data = f.read()
response = requests.post(API_URL, headers=headers, data=data)
return response.json()