Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
DA-Platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
文档服务地址:
http://47.92.0.57:3000/
周报索引地址:
http://47.92.0.57:3000/s/NruNXRYmV
Open sidebar
Berlin
DA-Platform
Commits
3e001082
Commit
3e001082
authored
Oct 26, 2020
by
李景熙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
根据数据单创建任务
parent
9b535aef
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
data_set.py
DAPlatform/Dao/data_set.py
+2
-0
No files found.
DAPlatform/Dao/data_set.py
View file @
3e001082
...
@@ -63,11 +63,13 @@ def set_complete(_id):
...
@@ -63,11 +63,13 @@ def set_complete(_id):
# 根据数据单id创建任务
# 根据数据单id创建任务
# 需要模板id
def
createtask
(
id
):
def
createtask
(
id
):
try
:
try
:
result
=
collection
.
find_one
({
'_id'
:
ObjectId
(
id
)})
result
=
collection
.
find_one
({
'_id'
:
ObjectId
(
id
)})
Task
.
create_task
(
result
[
'user_id'
],
str
(
result
[
'_id'
]))
Task
.
create_task
(
result
[
'user_id'
],
str
(
result
[
'_id'
]))
for
i
in
result
[
'data_list'
]:
for
i
in
result
[
'data_list'
]:
# 每一个i对应两个分片,一个文本分片,一个图像分片
print
(
i
[
'id'
])
print
(
i
[
'id'
])
return
True
return
True
except
Exception
as
e
:
except
Exception
as
e
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment