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
f7e79bc6
Commit
f7e79bc6
authored
Dec 15, 2023
by
BO ZHANG
🏀
Browse files
add module headers
parent
9a499f72
Pipeline
#2422
failed with stage
Changes
9
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
csst_common/__init__.py
View file @
f7e79bc6
"""
Identifier:
KSC-SJ4-
csst_common/__init__.py
Identifier: csst_common/__init__.py
Name: __init__.py
Description: csst_common package
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
202
2-09
-1
3
, Bo Zhang, created
202
2-09
-1
3
, Bo Zhang,
fixed a bug
202
3-12
-1
5
, Bo Zhang, created
202
3-12
-1
5
, Bo Zhang,
add module header
"""
from
.status
import
CsstResult
,
CsstStatus
...
...
csst_common/ccds/__init__.py
View file @
f7e79bc6
"""
Identifier: csst_common/ccds/__init__.py
Name: __init__.py
Description: CCDS wrapper
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
2023-12-15, Bo Zhang, created
2023-12-15, Bo Zhang, add CCDS wrapper
"""
from
.ccds
import
CCDS
csst_common/ccds/ccds.py
View file @
f7e79bc6
"""
Identifier: csst_common/__init__.py
Name: __init__.py
Description: csst_common package
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
2023-07-08, Bo Zhang, created
2023-12-15, Bo Zhang, add module header
"""
import
functools
import
os
...
...
csst_common/ccds/slsconf.py
View file @
f7e79bc6
"""
Identifier: csst_common/ccds/slsconf.py
Name: slsconf.py
Description: csst_common package
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
2023-12-15, Bo Zhang, created
2023-12-15, Bo Zhang, add module header
"""
import
json
import
os
import
re
import
astropy.io.fits
as
pyfits
from
ccds
import
client
...
...
csst_common/decorator.py
View file @
f7e79bc6
"""
Identifier: csst_common/decorator.py
Name: decorator.py
Description: module wrapper
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
2023-12-15, Bo Zhang, created
2023-12-15, Bo Zhang, add module header
"""
import
functools
import
logging
import
time
import
traceback
from
typing
import
Callable
,
NamedTuple
,
Optional
from
csst_common.status
import
CsstResult
,
CsstStatus
from
csst_common.logger
import
get_logger
from
csst_common.status
import
CsstResult
,
CsstStatus
__all__
=
[
"ModuleResult"
,
"parameterized_module_decorator"
]
...
...
csst_common/file.py
View file @
f7e79bc6
"""
Identifier: csst_common/__init__.py
Name: __init__.py
Description: csst_common package
Author: Bo Zhang
Created: 2023-12-13
Modified-History:
2023-12-13, Bo Zhang, created
2023-12-13, Bo Zhang, add File
2023-12-15, Bo Zhang, use re to match file name
2023-12-15, Bo Zhang, add module header
"""
import
os
import
re
from
typing
import
Optional
...
...
csst_common/time.py
View file @
f7e79bc6
"""
Identifier: csst_common/time.py
Name: time.py
Description: time module
Author: Bo Zhang
Created: 2023-03-09
Modified-History:
2023-03-09, Bo Zhang, created
2023-03-09, Bo Zhang, add two time formats
"""
import
datetime
def
now
():
"""
Return ISOT8601 format datetime, for time stamps in data products.
"""
return
datetime
.
datetime
.
now
().
strftime
(
'
%Y-%m-%dT%H:%M:%S.%f
'
)
"""Return ISOT8601 format datetime, for time stamps in data products."""
return
datetime
.
datetime
.
now
().
strftime
(
"
%Y-%m-%dT%H:%M:%S.%f
"
)
def
now_dfs
():
"""
Return ISOT8601 format datetime, for DFS usage only.
"""
return
datetime
.
datetime
.
now
().
strftime
(
'
%Y-%m-%d %H:%M:%S
'
)
"""Return ISOT8601 format datetime, for DFS usage only."""
return
datetime
.
datetime
.
now
().
strftime
(
"
%Y-%m-%d %H:%M:%S
"
)
csst_common/utils/tempfile.py
View file @
f7e79bc6
import
secrets
import
string
...
...
tests/test_status.py
View file @
f7e79bc6
"""
Identifier: tests/test_status.py
Name: test_status.py
Description: test CsstStatus
Author: Bo Zhang
Created: 2022-09-13
Modified-History:
2022-09-13, Bo Zhang, created
2022-09-13, Bo Zhang, added CsstMbiDataManager
"""
import
unittest
from
csst_common.status
import
CsstStatus
...
...
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