Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
csst-cicd
csst-dag
Commits
361caefb
Commit
361caefb
authored
Jul 22, 2025
by
BO ZHANG
🏀
Browse files
append n_file_expected and n_file_found in task
parent
3d80bb19
Changes
1
Hide whitespace changes
Inline
Side-by-side
csst_dag/dag/_dispatcher.py
View file @
361caefb
...
@@ -473,6 +473,7 @@ class Dispatcher:
...
@@ -473,6 +473,7 @@ class Dispatcher:
task_list
=
[]
task_list
=
[]
# loop over obsid
# loop over obsid
for
this_obsid_basis
in
obsid_basis
.
groups
:
for
this_obsid_basis
in
obsid_basis
.
groups
:
# find relevant plan
this_relevant_plan_basis
=
table
.
join
(
this_relevant_plan_basis
=
table
.
join
(
this_obsid_basis
[
group_keys
][:
1
],
this_obsid_basis
[
group_keys
][:
1
],
plan_basis
,
plan_basis
,
...
@@ -480,6 +481,8 @@ class Dispatcher:
...
@@ -480,6 +481,8 @@ class Dispatcher:
join_type
=
PLAN_JOIN_TYPE
,
join_type
=
PLAN_JOIN_TYPE
,
)
)
assert
len
(
this_relevant_plan_basis
)
==
1
assert
len
(
this_relevant_plan_basis
)
==
1
# generate task
this_task
=
dict
(
this_relevant_plan_basis
[
group_keys
][
0
])
n_file_expected
=
this_relevant_plan_basis
[
0
][
"n_file"
]
n_file_expected
=
this_relevant_plan_basis
[
0
][
"n_file"
]
n_file_found
=
len
(
this_obsid_basis
)
n_file_found
=
len
(
this_obsid_basis
)
this_instrument
=
this_relevant_plan_basis
[
0
][
"instrument"
]
this_instrument
=
this_relevant_plan_basis
[
0
][
"instrument"
]
...
@@ -489,6 +492,8 @@ class Dispatcher:
...
@@ -489,6 +492,8 @@ class Dispatcher:
n_file_expected
==
n_file_found
n_file_expected
==
n_file_found
and
detectors_found
==
detectors_expected
and
detectors_found
==
detectors_expected
)
)
this_task
[
"n_file_expected"
]
=
n_file_expected
this_task
[
"n_file_found"
]
=
n_file_found
# append this task
# append this task
task_list
.
append
(
task_list
.
append
(
dict
(
dict
(
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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