7.1批量添加数据集、导出结果的后端实现
This commit is contained in:
parent
6d93383c12
commit
9947df004f
|
@ -7,7 +7,7 @@ import json
|
||||||
import os
|
import os
|
||||||
import zipfile
|
import zipfile
|
||||||
|
|
||||||
from app.libs.tools import read_txt_file, write_json, read_json_file, make_dir
|
from ...libs.tools import read_txt_file, write_json, read_json_file, make_dir
|
||||||
|
|
||||||
api = RedPrint('anno')
|
api = RedPrint('anno')
|
||||||
|
|
||||||
|
|
|
@ -9,6 +9,7 @@ import os
|
||||||
from ...entities.entities import ReturnInfo, FileInfo
|
from ...entities.entities import ReturnInfo, FileInfo
|
||||||
from ...libs.tools import read_json_file,read_txt_file,write_json
|
from ...libs.tools import read_json_file,read_txt_file,write_json
|
||||||
|
|
||||||
|
#
|
||||||
api = RedPrint('files')
|
api = RedPrint('files')
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -10,6 +10,7 @@ api = RedPrint('index')
|
||||||
|
|
||||||
|
|
||||||
# 访问首页 http://localhost:9060/v1/index
|
# 访问首页 http://localhost:9060/v1/index
|
||||||
|
|
||||||
# @api.route('/index')
|
# @api.route('/index')
|
||||||
@api.route('', methods=['GET'])
|
@api.route('', methods=['GET'])
|
||||||
def index():
|
def index():
|
||||||
|
|
|
@ -18,5 +18,6 @@ PROJECT_CONFIG_PATH = PROJECTS + '/' + "{}" + '/config.json'
|
||||||
|
|
||||||
#下载标注结果所在的位置
|
#下载标注结果所在的位置
|
||||||
DOWNLOAD_FILE_LOCATION = 'projects/{}/result.json'
|
DOWNLOAD_FILE_LOCATION = 'projects/{}/result.json'
|
||||||
|
|
||||||
# 标注信息存储路径
|
# 标注信息存储路径
|
||||||
ANNO_OUTPUT_PATH = PROJECTS + '/' + '{}' + '/' + 'anno.json'
|
ANNO_OUTPUT_PATH = PROJECTS + '/' + '{}' + '/' + 'anno.json'
|
||||||
|
|
|
@ -3,5 +3,5 @@
|
||||||
| url | methods | params | return |
|
| url | methods | params | return |
|
||||||
| -------------------------- | ------- | -------------------------------------------------------- | -------------------------------- |
|
| -------------------------- | ------- | -------------------------------------------------------- | -------------------------------- |
|
||||||
| v1/project/get_zipped_data | POST | projectName:项目名 file:数据集文件(目前只支持.zip格式) | json :errcode表示是否成功导入 |
|
| v1/project/get_zipped_data | POST | projectName:项目名 file:数据集文件(目前只支持.zip格式) | json :errcode表示是否成功导入 |
|
||||||
| v1/files/get_json | GET | projectName:项目名 | file(json格式的数据集标注结果) |
|
| v1/files/get_json | GET | projectName:项目名 | file(.json格式的数据集标注结果) |
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue