Update myapp.py
Browse files
myapp.py
CHANGED
@@ -3,8 +3,8 @@ from flask_cors import CORS
|
|
3 |
from gradio_client import Client
|
4 |
from all_models import models # Import the models list
|
5 |
|
6 |
-
|
7 |
-
CORS(
|
8 |
|
9 |
# Initialize Gradio Client with the first model in the list
|
10 |
client = Client("Geek7/mdztxi2")
|
@@ -42,4 +42,4 @@ def predict():
|
|
42 |
return jsonify({"error": str(e)}), 500
|
43 |
|
44 |
if __name__ == '__main__':
|
45 |
-
|
|
|
3 |
from gradio_client import Client
|
4 |
from all_models import models # Import the models list
|
5 |
|
6 |
+
myapp = Flask(__name__)
|
7 |
+
CORS(myapp)
|
8 |
|
9 |
# Initialize Gradio Client with the first model in the list
|
10 |
client = Client("Geek7/mdztxi2")
|
|
|
42 |
return jsonify({"error": str(e)}), 500
|
43 |
|
44 |
if __name__ == '__main__':
|
45 |
+
myapp.run(debug=True)
|