Spaces:
Sleeping
Sleeping
Commit
·
511f1d6
1
Parent(s):
e1ddd94
Update app.py
Browse files
app.py
CHANGED
@@ -15,7 +15,7 @@ load_dotenv(find_dotenv())
|
|
15 |
|
16 |
def handwriting_to_text(image):
|
17 |
API_URL = "https://api-inference.huggingface.co/models/microsoft/trocr-base-handwritten"
|
18 |
-
headers = {"Authorization": "Bearer
|
19 |
with open(image, "rb") as f:
|
20 |
data = f.read()
|
21 |
response = requests.post(API_URL, headers=headers, data=data)
|
|
|
15 |
|
16 |
def handwriting_to_text(image):
|
17 |
API_URL = "https://api-inference.huggingface.co/models/microsoft/trocr-base-handwritten"
|
18 |
+
headers = {"Authorization": "Bearer xxxxxxxxxx"}
|
19 |
with open(image, "rb") as f:
|
20 |
data = f.read()
|
21 |
response = requests.post(API_URL, headers=headers, data=data)
|