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-dfs
csst-dfs-api
Commits
4af64a90
Commit
4af64a90
authored
Jul 05, 2023
by
Wei Shoulin
Browse files
update sls 2
parent
4aee301e
Changes
3
Hide whitespace changes
Inline
Side-by-side
csst_dfs_api/sls/level2spectra.py
View file @
4af64a90
...
...
@@ -15,7 +15,7 @@ class Level2SpectraApi(object):
:param kwargs: Parameter dictionary, key items support:
level0_id: [str]
level1_id: [int]
spectra_id
: [str]
file_type
: [str]
create_time : (start, end),
qc2_status : [int],
prc_status : [int],
...
...
@@ -65,8 +65,7 @@ class Level2SpectraApi(object):
:param kwargs: Parameter dictionary, key items support:
level0_id: [str]
level1_id: [int]
spectra_id : [str]
region : [str]
file_type : [str]
filename : [str]
file_path : [str]
prc_status : [int]
...
...
tests/sls/test_sls_level1.py
deleted
100644 → 0
View file @
4aee301e
import
os
import
unittest
from
astropy.io
import
fits
from
csst_dfs_api.facility.level1
import
Level1DataApi
class
SLSLevel1DataTestCase
(
unittest
.
TestCase
):
def
setUp
(
self
):
self
.
api
=
Level1DataApi
()
def
test_find_by_qc1_status
(
self
):
recs
=
self
.
api
.
sls_find_by_qc1_status
(
qc1_status
=-
1
)
print
(
'find_by_qc1_status:'
,
recs
)
def
test_find
(
self
):
recs
=
self
.
api
.
find
(
ra_cen
=
1
,
dec_cen
=
2
,
radius_cen
=
1
)
print
(
'find:'
,
recs
)
tests/sls/test_sls_level2_spectra.py
View file @
4af64a90
...
...
@@ -22,15 +22,14 @@ class SLSLevel2SpectraTestCase(unittest.TestCase):
rec
=
self
.
api
.
update_proc_status
(
id
=
1
,
status
=
4
)
print
(
'update_proc_status:'
,
rec
)
def
test_update_qc
1
_status
(
self
):
rec
=
self
.
api
.
update_qc
1
_status
(
id
=
1
,
status
=
7
)
def
test_update_qc
2
_status
(
self
):
rec
=
self
.
api
.
update_qc
2
_status
(
id
=
1
,
status
=
7
)
print
(
'update_qc1_status:'
,
rec
)
def
test_write
(
self
):
rec
=
self
.
api
.
write
(
level1_id
=
2
,
spectra_id
=
"222"
,
region
=
"[12,13,24,24]"
,
file_type
=
"SPC"
,
prc_status
=
3
,
prc_time
=
'2021-10-22 11:12:13'
,
filename
=
"MSC_MS_210525120000_100000000_20_cat.fits"
,
...
...
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