Commit 847adc08 authored by BO ZHANG's avatar BO ZHANG 🏀
Browse files

tweak dm.dfs_rc_query()

parent 22dcd647
......@@ -673,7 +673,7 @@ class CsstMsDataManager:
return pointing_ra, pointing_dec
def dfs_rc_auto(self):
""" Download RC. """
""" Download RC for the current exposure. """
assert self.dfs_is_available()
assert len(self.target_detectors) >= 1
pointing_ra, pointing_dec = self.get_coord()
......@@ -701,11 +701,6 @@ class CsstMsDataManager:
obstime=-1,
limit=-1
)
print(
f"RA, Dec = [{pointing_ra}, {pointing_dec}], "
f"Status = {isinstance(refcat, Table)}, "
f"N_entries = {len(refcat)}"
)
return refcat
def dfs_rc_query(
......@@ -749,11 +744,21 @@ class CsstMsDataManager:
obstime=obstime,
limit=limit
)
self.logger_ppl.info(f"Results from DFS CATAPI: code = {cat['code']}, message = {cat['message']}")
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)
else:
self.logger_ppl.info(
f"Results from DFS CATAPI: \n"
f" - code = {cat['code']}"
f" - message = {cat['message']}"
)
raise ValueError("Bad results!")
def dfs_l1_push(self):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment