-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.py
39 lines (26 loc) · 877 Bytes
/
app.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import os
import sys
import cv2
import numpy as np
from flask import Flask, render_template, jsonify, request
from jinja2 import Environment, FileSystemLoader
app = Flask(__name__)
# HTML을 주는 부분
@app.route('/', methods=['POST', 'GET'])
def mainpage():
return render_template('mainpage.html')
@app.route('/imagetoimage', methods=['POST', 'GET'])
def imagetoimage():
return render_template('imagetoimage.html')
@app.route('/texttoimage', methods=['POST', 'GET'])
def texttoimage():
return render_template('texttoimage.html')
# @app.route('/lightbox', methods=['POST', 'GET'])
# def lightbox():
# return render_template('lightbox.html')
@app.route('/lightbox', methods=['POST', 'GET'])
def lightbox():
return render_template('lightbox.html')
# 서버 연결
if __name__ == '__main__':
app.run()