Ashrafb commited on
Commit
b3e768f
·
1 Parent(s): 2d3135b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -3,8 +3,8 @@ import requests
3
  import base64
4
 
5
  def main():
6
- st.title("Image Captioning App")
7
-
8
  uploaded_file = st.file_uploader("Choose an image...", type=["jpg", "png", "jpeg"])
9
 
10
  if uploaded_file is not None:
@@ -21,7 +21,7 @@ def main():
21
  payload = {"data": ["data:image/jpeg;base64," + image_base64]}
22
 
23
  # Make the API request
24
- response = requests.post("https://ashrafb-salesforce-blip-image-captioning-base.hf.space/run/predict", json=payload)
25
 
26
  # Check if response is successful (status code 200)
27
  if response.status_code == 200:
 
3
  import base64
4
 
5
  def main():
6
+ st.title("Aiconvert.online Image Captioning App")
7
+ st.markdown('<style>h1{color: Crimson; text-align: center;}</style>', unsafe_allow_html=True)
8
  uploaded_file = st.file_uploader("Choose an image...", type=["jpg", "png", "jpeg"])
9
 
10
  if uploaded_file is not None:
 
21
  payload = {"data": ["data:image/jpeg;base64," + image_base64]}
22
 
23
  # Make the API request
24
+ response = requests.post("https://ashrafb-salesforce-blip-image-captioning-base2.hf.space/run/predict", json=payload)
25
 
26
  # Check if response is successful (status code 200)
27
  if response.status_code == 200: