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-sims
csst_mci_sim
Commits
05965d4e
Commit
05965d4e
authored
Jan 24, 2025
by
Yan Zhaojun
Browse files
Replace shao.py
parent
2e3aec48
Pipeline
#7907
passed with stage
in 0 seconds
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
csst_mci_sim/support/shao.py
View file @
05965d4e
...
...
@@ -19,28 +19,28 @@ def onOrbitObsPosition(path, input_ra_list, input_dec_list, input_pmra_list, inp
input_parallax_list
,
input_nstars
,
input_x
,
input_y
,
input_z
,
input_vx
,
input_vy
,
input_vz
,
input_epoch
,
input_date_str
,
input_time_str
):
# Check input parameters
#
if isinstance(type(input_nstars), type(1)): # type(input_nstars) != type(1):
#
raise TypeError("Parameter 7 is not int!", input_nstars)
#
if isinstance(type(input_nstars), type(1)): # type(input_nstars) != type(1):
#
raise TypeError("Parameter 7 is not int!", input_nstars)
#
checkInputList(input_ra_list, input_nstars)
#
checkInputList(input_dec_list, input_nstars)
#
checkInputList(input_pmra_list, input_nstars)
#
checkInputList(input_pmdec_list, input_nstars)
#
checkInputList(input_rv_list, input_nstars)
#
checkInputList(input_parallax_list, input_nstars)
#
#
if isinstance(type(input_x), type(1.1)): # type(input_x) != type(1.1):
#
raise TypeError("Parameter 8 is not double!", input_x)
#
if isinstance(type(input_y), type(1.1)): # type(input_y) != type(1.1):
#
raise TypeError("Parameter 9 is not double!", input_y)
#
if isinstance(type(input_z), type(1.1)): # type(input_z) != type(1.1):
#
raise TypeError("Parameter 10 is not double!", input_z)
#
if isinstance(type(input_vx), type(1.1)): # type(input_vx) != type(1.1):
#
raise TypeError("Parameter 11 is not double!", input_vx)
#
if isinstance(type(input_vy), type(1.1)): # type(input_vy) != type(1.1):
#
raise TypeError("Parameter 12 is not double!", input_vy)
#
if isinstance(type(input_vz), type(1.1)): # type(input_vz) != type(1.1):
#
raise TypeError("Parameter 13 is not double!", input_vz)
#
checkInputList(input_ra_list, input_nstars)
#
checkInputList(input_dec_list, input_nstars)
#
checkInputList(input_pmra_list, input_nstars)
#
checkInputList(input_pmdec_list, input_nstars)
#
checkInputList(input_rv_list, input_nstars)
#
checkInputList(input_parallax_list, input_nstars)
#
if isinstance(type(input_x), type(1.1)): # type(input_x) != type(1.1):
#
raise TypeError("Parameter 8 is not double!", input_x)
#
if isinstance(type(input_y), type(1.1)): # type(input_y) != type(1.1):
#
raise TypeError("Parameter 9 is not double!", input_y)
#
if isinstance(type(input_z), type(1.1)): # type(input_z) != type(1.1):
#
raise TypeError("Parameter 10 is not double!", input_z)
#
if isinstance(type(input_vx), type(1.1)): # type(input_vx) != type(1.1):
#
raise TypeError("Parameter 11 is not double!", input_vx)
#
if isinstance(type(input_vy), type(1.1)): # type(input_vy) != type(1.1):
#
raise TypeError("Parameter 12 is not double!", input_vy)
#
if isinstance(type(input_vz), type(1.1)): # type(input_vz) != type(1.1):
#
raise TypeError("Parameter 13 is not double!", input_vz)
# Convert km -> m
input_x
=
input_x
*
1000.0
...
...
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