demo_facility_level0.py 458 Bytes
Newer Older
Wei Shoulin's avatar
demo  
Wei Shoulin committed
1
2
3
4
5
from csst_dfs_api.facility.level0 import Level0DataApi

api = Level0DataApi()

# find
Wei Shoulin's avatar
test    
Wei Shoulin committed
6
recs = api.find(obs_id = 17, obs_type = 'sci', limit = 0, prc_status = -1)
Wei Shoulin's avatar
demo  
Wei Shoulin committed
7
8
9
10
11
12
13
14
15
16
17
18
19
print('find:', recs)

# get
rec = api.get(fits_id = 100)
print('get:', rec)

# update_proc_status
rec = api.update_proc_status(fits_id = 100, status = 6)
print('update_proc_status:', rec)

# update_qc0_status
rec = api.update_qc0_status(fits_id = 100, status = 7)
print('update_qc0_status:', rec)