From 1ffa986cbd452de93f4222e3c9b076587803c44c Mon Sep 17 00:00:00 2001 From: Yan Zhaojun Date: Fri, 24 Jan 2025 12:06:56 +0000 Subject: [PATCH] Replace shao.py --- csst_mci_sim/support/shao.py | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/csst_mci_sim/support/shao.py b/csst_mci_sim/support/shao.py index ba243ba..9aaa834 100644 --- a/csst_mci_sim/support/shao.py +++ b/csst_mci_sim/support/shao.py @@ -1,22 +1,22 @@ from ctypes import * -def checkInputList(input_list, n): - if type(input_list) != type([1, 2, 3]): - raise TypeError("Input type is not list!", input_list) - for i in input_list: - if type(i) != type(1.1): - if type(i) != type(1): - raise TypeError("Input list's element is not float or int!", input_list) - if len(input_list) != n: - raise RuntimeError("Length of input list is not equal to stars' number!", input_list) - +#def checkInputList(input_list, n): +# if type(input_list) != type([1, 2, 3]): +# raise TypeError("Input type is not list!", input_list) +# for i in input_list: +# if type(i) != type(1.1): +# if type(i) != type(1): +# raise TypeError("Input list's element is not float or int!", input_list) +# if len(input_list) != n: +# raise RuntimeError("Length of input list is not equal to stars' number!", input_list) + def onOrbitObsPosition(path, input_ra_list, input_dec_list, input_pmra_list, input_pmdec_list, input_rv_list, \ 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 type(input_nstars) != type(1): - raise TypeError("Parameter 7 is not int!", input_nstars) - + # Check input parameters +# if 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) -- GitLab