Commit aca2a6b8 authored by Yan Zhaojun's avatar Yan Zhaojun
Browse files

debug

parent 4ed00146
Pipeline #4114 failed with stage
in 0 seconds
Requirement already satisfied: PyQt5 in /home/yan/anaconda3/lib/python3.8/site-packages (5.15.10)
Requirement already satisfied: PyQt5-sip<13,>=12.13 in /home/yan/anaconda3/lib/python3.8/site-packages (from PyQt5) (12.13.0)
Requirement already satisfied: PyQt5-Qt5>=5.15.2 in /home/yan/anaconda3/lib/python3.8/site-packages (from PyQt5) (5.15.2)
...@@ -44,9 +44,13 @@ class CDM03bidir(): ...@@ -44,9 +44,13 @@ class CDM03bidir():
self.log = log self.log = log
self._setupLogger() self._setupLogger()
#default CDM03 settings # #default CDM03 settings
self.params = dict(beta_p=0.6, beta_s=0.6, fwc=200000., vth=1.168e7, vg=6.e-11, t=20.48e-3, # self.params = dict(beta_p=0.6, beta_s=0.6, fwc=200000., vth=1.168e7, vg=6.e-11, t=20.48e-3,
sfwc=730000., svg=1.0e-10, st=5.0e-6, parallel=1., serial=1.) # sfwc=730000., svg=1.0e-10, st=5.0e-6, parallel=1., serial=1.)
self.params = dict(beta_p=0.6, beta_s=0.6, fwc=100000., vth=1.168e7, vg=6.e-11, t=1.0e-3,
sfwc=700000., svg=1.0e-10, st=1.0e-6, parallel=1., serial=0.)
#update with inputs #update with inputs
self.params.update(self.values) self.params.update(self.values)
......
...@@ -1241,28 +1241,23 @@ class IFSsimulator(): ...@@ -1241,28 +1241,23 @@ class IFSsimulator():
self.information.update(dict(quadrant=int(0), self.information.update(dict(quadrant=int(0),
ccdx=int(0), ccdx=int(0),
ccdy=int(0), ccdy=int(0),
psfoversampling=1.0,
ccdxgap=1.643, ccdxgap=1.643,
ccdygap=8.116, ccdygap=8.116,
bluesize=4000, bluesize=4000,
redsize=6000, redsize=6000,
prescanx=50, # prescanx=50,
ovrscanx=20, # ovrscanx=20,
fullwellcapacity=90000, fullwellcapacity=90000,
dark=0.001, dark=0.001,
readout=4, readout=4,
bias=500.0, bias=500.0,
cosmic_bkgd=0.182758225257,
scattered_light=2.96e-2,
e_adu=1.5, e_adu=1.5,
exposures=1,
exptime=300.0,
readouttime=0.13824, readouttime=0.13824,
rdose=8.0e9, rdose=8.0e9,
ra=0.0, ra=0.0,
dec=0.0, dec=0.0,
injection=80000.0, coveringfraction=0.1,
coveringfraction=0.5,
# CR: 3.0% is for 565s exposure # CR: 3.0% is for 565s exposure
######################################### #########################################
...@@ -1976,11 +1971,17 @@ class IFSsimulator(): ...@@ -1976,11 +1971,17 @@ class IFSsimulator():
# blue channle # blue channle
b_4 = np.sum(self.image_b[0:1024, 0:2048], axis=0) b_4 = np.sum(self.image_b[0:1024, 0:2048], axis=0)
b_3 = np.sum(self.image_b[0:1024, 2048:4096], axis=0)
###### flip right to left of part3 and part2
temp_b_3=np.fliplr(self.image_b[0:1024, 2048:4096]) ## left to right
b_3 = np.sum(temp_b_3, axis=0)
b_2 = np.sum(self.image_b[1024:1024+1024, 2048:2048+2048], axis=0) temp_b_2=np.fliplr(self.image_b[1024:1024+1024, 2048:2048+2048]) ## left to right
b_2 = np.sum(temp_b_2, axis=0)
b_1 = np.sum(self.image_b[1024:1024+1024, 0:2048], axis=0) b_1 = np.sum(self.image_b[1024:1024+1024, 0:2048], axis=0)
####
for k in range(1024+320): for k in range(1024+320):
# part # part
self.frame_b_4[k, :] += b_4*0.09216/self.information['exptime'] self.frame_b_4[k, :] += b_4*0.09216/self.information['exptime']
...@@ -2402,10 +2403,13 @@ class IFSsimulator(): ...@@ -2402,10 +2403,13 @@ class IFSsimulator():
self.log.debug('Starting to apply radiation damage model...') self.log.debug('Starting to apply radiation damage model...')
# at this point we can give fake data... # at this point we can give fake data...
cti = CTI.CDM03bidir(self.information, [], log=self.log) cti = CTI.CDM03bidir(self.information, [], log=self.log)
# here we need the right input data
### here we need the right input data
self.image_b = cti.applyRadiationDamage(self.image_b.copy( self.image_b = cti.applyRadiationDamage(self.image_b.copy(
).transpose(), iquadrant=self.information['quadrant']).transpose() ).transpose(), iquadrant=self.information['quadrant']).transpose()
self.log.info('Radiation damage added.') self.log.info('Radiation damage added.')
self.log.debug('Starting to apply radiation damage model...') self.log.debug('Starting to apply radiation damage model...')
# at this point we can give fake data... # at this point we can give fake data...
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment