Commits (2)
...@@ -10,6 +10,8 @@ CpicImgSim is a Python library for numerical simulation of the observational ima ...@@ -10,6 +10,8 @@ CpicImgSim is a Python library for numerical simulation of the observational ima
联系方式:南京天光所 赵刚 gzhao@niaot.ac.cn 025-85482316 联系方式:南京天光所 赵刚 gzhao@niaot.ac.cn 025-85482316
## 软件更新日志 ## 软件更新日志
2025年6月5日:添加了新的宇宙线生成模块,使用主巡天内的模块代码。新的模块可以更好的兼容通用的宇宙线识别模块。设置方法:在run_config 里添加msc_cr_model: true条目可以启用新的宇宙线生成模块。 V2.1.0 2025年6月5日:添加了新的宇宙线生成模块,使用主巡天内的模块代码。新的模块可以更好的兼容通用的宇宙线识别模块。设置方法:在run_config 里添加msc_cr_model: true条目可以启用新的宇宙线生成模块。
2025年6月10日:增加了波前电压设置功能。现在对于每一次曝光可以设置不同的波前电压。在观测yaml中增加dm_volt_index: xxx选项。xxx为整形,例如565, 661等。另外支持1, 2, 3, 4选项,为四个不同方向的暗区。实验功能:dm_volt_index可设置-1,自动选择和波段匹配的暗区(该功能谨慎使用)。 V2.1.1 2025年6月10日:增加了波前电压设置功能。现在对于每一次曝光可以设置不同的波前电压。在观测yaml中增加dm_volt_index: xxx选项。xxx为整形,例如565, 661等。另外支持1, 2, 3, 4选项,为四个不同方向的暗区。实验功能:dm_volt_index可设置-1,自动选择和波段匹配的暗区(该功能谨慎使用)。
V2.1.2 2025年7月18日:修改了宇宙线位置并非随机的bug,修复了头文件中filenmae显示不完整的bug
\ No newline at end of file
...@@ -260,7 +260,7 @@ class CosmicRayFrameMaker(object): ...@@ -260,7 +260,7 @@ class CosmicRayFrameMaker(object):
exTime=expt, exTime=expt,
cr_pixelRatio=0.003*expt/600., # 5e-6/pixel , 1.3e-6 for cpic package cr_pixelRatio=0.003*expt/600., # 5e-6/pixel , 1.3e-6 for cpic package
gain=1, # gain = 1, means the unit of output image is electron gain=1, # gain = 1, means the unit of output image is electron
attachedSizes=self.attachedSize) attachedSizes=self.attachedSize, seed=seed)
return cr_map return cr_map
for i in range(len(cr_array)): for i in range(len(cr_array)):
......
...@@ -153,7 +153,7 @@ with open(cpism_refdata + '/cpism_config.yaml', 'r') as f: ...@@ -153,7 +153,7 @@ with open(cpism_refdata + '/cpism_config.yaml', 'r') as f:
if os.environ.get('PYSYN_CDBS') is None: if os.environ.get('PYSYN_CDBS') is None:
os.environ['PYSYN_CDBS'] = config['pysyn_refdata'] os.environ['PYSYN_CDBS'] = config['pysyn_refdata']
__version__ = '2.0.0' __version__ = '2.1.1'
# we need to ignore the warning from pysynphot, because we only use the star models. # we need to ignore the warning from pysynphot, because we only use the star models.
with warnings.catch_warnings(): # pragma: no cover with warnings.catch_warnings(): # pragma: no cover
......
...@@ -280,9 +280,9 @@ def primary_hdu( ...@@ -280,9 +280,9 @@ def primary_hdu(
# header['GROUPS'] = False # header['GROUPS'] = False
header['DATE'] = datetime_obj_to_iso(datetime.now()) header['DATE'] = datetime_obj_to_iso(datetime.now())
heaer_filename = filename[:-4] heaer_filename = filename[:-5]
if len(heaer_filename) > 68: # if len(heaer_filename) > 68:
heaer_filename = heaer_filename[:68] # heaer_filename = heaer_filename[:68]
header['FILENAME'] = heaer_filename header['FILENAME'] = heaer_filename
header['TELESCOP'] = 'CSST' header['TELESCOP'] = 'CSST'
header['INSTRUME'] = 'CPIC' header['INSTRUME'] = 'CPIC'
......
band: f520 band: f520
# emgain: 100 # emgain: 100
emset: 180 emset: 160
expt: 30 expt: 30
nframe: 2 nframe: 5
obsid: '40100000005' obsid: '40100000005'
rotation: 30 rotation: 30
dataset: cpic-v01 dataset: cpic-v01
......
...@@ -37,8 +37,7 @@ camera: ...@@ -37,8 +37,7 @@ camera:
nonlinear: false nonlinear: false
shutter: false shutter: false
csst_format: true csst_format: true
nsample: 1 nsample: 10
check_fits_header: true check_fits_header: true
output: ./example_output/ output: ./example_output/
actuator_file: ${cpism_refdata}/optics/dark_zone_0011_volt.fits
msc_cr_model: true msc_cr_model: true
...@@ -5,3 +5,5 @@ pysynphot==2.0.0 ...@@ -5,3 +5,5 @@ pysynphot==2.0.0
hcipy==0.6.0 hcipy==0.6.0
setuptools==68.2.2 setuptools==68.2.2
pandas==2.2.1 pandas==2.2.1
# toml==0.10.2
# tqdm==4.67.1
\ No newline at end of file