Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,6 +3,10 @@ API_URL = "https://api-inference.huggingface.co/models/Salesforce/blip-image-cap
|
|
3 |
# Helper functions
|
4 |
import requests, json
|
5 |
import io
|
|
|
|
|
|
|
|
|
6 |
#Image-to-text endpoint
|
7 |
def get_completion(inputs, parameters=None, ENDPOINT_URL=API_URL):
|
8 |
hf_api_key = "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"
|
|
|
3 |
# Helper functions
|
4 |
import requests, json
|
5 |
import io
|
6 |
+
import io
|
7 |
+
import IPython.display
|
8 |
+
from PIL import Image
|
9 |
+
import base64
|
10 |
#Image-to-text endpoint
|
11 |
def get_completion(inputs, parameters=None, ENDPOINT_URL=API_URL):
|
12 |
hf_api_key = "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"
|