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-pipeline
csst_common
Commits
847adc08
Commit
847adc08
authored
Feb 17, 2023
by
BO ZHANG
🏀
Browse files
tweak dm.dfs_rc_query()
parent
22dcd647
Changes
1
Show whitespace changes
Inline
Side-by-side
csst_common/data_manager.py
View file @
847adc08
...
@@ -673,7 +673,7 @@ class CsstMsDataManager:
...
@@ -673,7 +673,7 @@ class CsstMsDataManager:
return
pointing_ra
,
pointing_dec
return
pointing_ra
,
pointing_dec
def
dfs_rc_auto
(
self
):
def
dfs_rc_auto
(
self
):
""" Download RC. """
""" Download RC
for the current exposure
. """
assert
self
.
dfs_is_available
()
assert
self
.
dfs_is_available
()
assert
len
(
self
.
target_detectors
)
>=
1
assert
len
(
self
.
target_detectors
)
>=
1
pointing_ra
,
pointing_dec
=
self
.
get_coord
()
pointing_ra
,
pointing_dec
=
self
.
get_coord
()
...
@@ -701,11 +701,6 @@ class CsstMsDataManager:
...
@@ -701,11 +701,6 @@ class CsstMsDataManager:
obstime
=-
1
,
obstime
=-
1
,
limit
=-
1
limit
=-
1
)
)
print
(
f
"RA, Dec = [
{
pointing_ra
}
,
{
pointing_dec
}
], "
f
"Status =
{
isinstance
(
refcat
,
Table
)
}
, "
f
"N_entries =
{
len
(
refcat
)
}
"
)
return
refcat
return
refcat
def
dfs_rc_query
(
def
dfs_rc_query
(
...
@@ -749,11 +744,21 @@ class CsstMsDataManager:
...
@@ -749,11 +744,21 @@ class CsstMsDataManager:
obstime
=
obstime
,
obstime
=
obstime
,
limit
=
limit
limit
=
limit
)
)
self
.
logger_ppl
.
info
(
f
"Results from DFS CATAPI: code =
{
cat
[
'code'
]
}
, message =
{
cat
[
'message'
]
}
"
)
if
cat
[
"code"
]
==
0
:
if
cat
[
"code"
]
==
0
:
self
.
logger_ppl
.
info
(
f
"totalCount =
{
cat
[
'totalCount'
]
}
, columns =
{
cat
[
'columns'
]
}
"
)
self
.
logger_ppl
.
info
(
f
"Results from DFS CATAPI:
\n
"
f
" - code =
{
cat
[
'code'
]
}
"
f
" - message =
{
cat
[
'message'
]
}
"
f
" - totalCount =
{
cat
[
'totalCount'
]
}
"
f
" - columns =
{
cat
[
'columns'
]
}
"
)
return
self
.
dfs_CatApi
.
to_table
(
cat
)
return
self
.
dfs_CatApi
.
to_table
(
cat
)
else
:
else
:
self
.
logger_ppl
.
info
(
f
"Results from DFS CATAPI:
\n
"
f
" - code =
{
cat
[
'code'
]
}
"
f
" - message =
{
cat
[
'message'
]
}
"
)
raise
ValueError
(
"Bad results!"
)
raise
ValueError
(
"Bad results!"
)
def
dfs_l1_push
(
self
):
def
dfs_l1_push
(
self
):
...
...
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