dhanishetty commited on
Commit
e18064f
·
verified ·
1 Parent(s): a8c7844

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -4,7 +4,7 @@ from azure.ai.vision.imageanalysis.models import VisualFeatures
4
  from azure.core.credentials import AzureKeyCredential
5
 
6
 
7
- def sample_ocr_image_file(image1, end_point, API_Key):
8
 
9
  if (end_point == '' or API_Key == ''):
10
  output = "*** Please provide EndPoint URL and API_KEY ***"
@@ -39,7 +39,7 @@ def sample_ocr_image_file(image1, end_point, API_Key):
39
 
40
  return output
41
 
42
- demo = gr.Interface( sample_ocr_image_file,
43
  [gr.UploadButton("Click to Upload an Image File", file_types=["image"]), gr.Textbox(label="Enter your Endpoint URL", placeholder="URL", lines=1),gr.Textbox(type = "password", label="Enter your API-Key", placeholder="API-Key", lines=1)],
44
  [gr.Textbox(label = "Output")]
45
 
 
4
  from azure.core.credentials import AzureKeyCredential
5
 
6
 
7
+ def ocr_image_file(image1, end_point, API_Key):
8
 
9
  if (end_point == '' or API_Key == ''):
10
  output = "*** Please provide EndPoint URL and API_KEY ***"
 
39
 
40
  return output
41
 
42
+ demo = gr.Interface( ocr_image_file,
43
  [gr.UploadButton("Click to Upload an Image File", file_types=["image"]), gr.Textbox(label="Enter your Endpoint URL", placeholder="URL", lines=1),gr.Textbox(type = "password", label="Enter your API-Key", placeholder="API-Key", lines=1)],
44
  [gr.Textbox(label = "Output")]
45