abdullahsajid commited on
Commit
a27a142
·
verified ·
1 Parent(s): b64f6b8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -12,9 +12,8 @@ import base64
12
  import io
13
  from PIL import Image
14
  from ultralytics import YOLO
15
-
16
-
17
  from PIL import Image
 
18
  app = Flask(__name__)
19
  CORS(app)
20
 
@@ -118,7 +117,7 @@ def home():
118
  return "Welcome to the Flask API!"
119
 
120
 
121
- @app.route('/api/data', methods=['GET'])
122
  def get_data():
123
  img = plt.imread('test1.jpeg')
124
  img_arr = np.array(img)
@@ -134,7 +133,7 @@ def get_data():
134
  }
135
  return jsonify(data)
136
 
137
- @app.route('/', methods=['POST'])
138
  def post_data():
139
  try:
140
  # Parse the JSON request
 
12
  import io
13
  from PIL import Image
14
  from ultralytics import YOLO
 
 
15
  from PIL import Image
16
+
17
  app = Flask(__name__)
18
  CORS(app)
19
 
 
117
  return "Welcome to the Flask API!"
118
 
119
 
120
+ @app.route('/api/face', methods=['GET'])
121
  def get_data():
122
  img = plt.imread('test1.jpeg')
123
  img_arr = np.array(img)
 
133
  }
134
  return jsonify(data)
135
 
136
+ @app.route('/api/face', methods=['POST'])
137
  def post_data():
138
  try:
139
  # Parse the JSON request