Loading observation_sim/instruments/FilterParam.py +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class FilterParam(object): # 6) sky background: e/pix/s # 7) saturation magnitude # 8) dim end magnitude if filter_param == None: if filter_param is None: filtP = { "NUV": [2867.7, 705.4, 2470.0, 3270.0, 0.1404, 0.004, 15.7, 25.4], "u": [3601.1, 852.1, 3120.0, 4090.0, 0.2176, 0.021, 16.1, 25.4], Loading observation_sim/instruments/FocalPlane.py +2 −2 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ class FocalPlane(object): self.nchips = 42 self.ignore_chips = [] if bad_chips == None: if bad_chips is None: self.bad_chips = [] else: self.bad_chips = bad_chips Loading Loading @@ -80,7 +80,7 @@ class FocalPlane(object): if logger is not None: logger.info( " Construct the wcs of the entire image mosaic using Gnomonic/TAN projection") if (xcen == None) or (ycen == None): if (xcen is None) or (ycen is None): xcen = self.cen_pix_x ycen = self.cen_pix_y Loading observation_sim/instruments/chip/Chip.py +1 −1 Original line number Diff line number Diff line Loading @@ -191,7 +191,7 @@ class Chip(FocalPlane): """Return the filter index and type for a given chip #(chipID) """ filter_type_list = _util.ALL_FILTERS if chipID == None: if chipID is None: chipID = self.chipID # updated configurations Loading observation_sim/instruments/chip/chip_utils.py +2 −2 Original line number Diff line number Diff line Loading @@ -206,7 +206,7 @@ def get_poisson(seed=0, sky_level=0.): def get_base_img(img, chip, read_noise, readout_time, dark_noise, exptime=150., InputDark=None): if InputDark == None: if InputDark is None: # base_level = read_noise**2 + dark_noise*(exptime+0.5*readout_time) # base_level = dark_noise*(exptime+0.5*readout_time) base_level = dark_noise*(exptime) Loading Loading @@ -237,7 +237,7 @@ def add_poisson(img, chip, exptime=150., seed=0, sky_level=0., poisson_noise=Non img.addNoise(poisson_noise) # img -= read_noise**2 if InputDark != None: if InputDark is not None: # "Instrument/data/dark/dark_1000s_example_0.fits" hdu = fits.open(InputDark) img += hdu[0].data/hdu[0].header['exptime']*exptime Loading observation_sim/sim_steps/add_pattern_noise.py +1 −1 Original line number Diff line number Diff line Loading @@ -80,6 +80,6 @@ def add_bias(self, chip, filt, tel, pointing, catalog, obs_param): nsecy=chip.nsecy, nsecx=chip.nsecx, seed=self.overall_config["random_seeds"]["seed_biasNonUniform"]+chip.chipID) elif obs_param["bias_16channel"] == False: elif obs_param["bias_16channel"] is False: chip.img += chip.bias_level return chip, filt, tel, pointing run_sim.py +1 −1 File changed.Contains only whitespace changes. Show changes observation_sim/instruments/_util.py +1 −1 File changed.Contains only whitespace changes. Show changes Loading
observation_sim/instruments/FilterParam.py +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ class FilterParam(object): # 6) sky background: e/pix/s # 7) saturation magnitude # 8) dim end magnitude if filter_param == None: if filter_param is None: filtP = { "NUV": [2867.7, 705.4, 2470.0, 3270.0, 0.1404, 0.004, 15.7, 25.4], "u": [3601.1, 852.1, 3120.0, 4090.0, 0.2176, 0.021, 16.1, 25.4], Loading
observation_sim/instruments/FocalPlane.py +2 −2 Original line number Diff line number Diff line Loading @@ -9,7 +9,7 @@ class FocalPlane(object): self.nchips = 42 self.ignore_chips = [] if bad_chips == None: if bad_chips is None: self.bad_chips = [] else: self.bad_chips = bad_chips Loading Loading @@ -80,7 +80,7 @@ class FocalPlane(object): if logger is not None: logger.info( " Construct the wcs of the entire image mosaic using Gnomonic/TAN projection") if (xcen == None) or (ycen == None): if (xcen is None) or (ycen is None): xcen = self.cen_pix_x ycen = self.cen_pix_y Loading
observation_sim/instruments/chip/Chip.py +1 −1 Original line number Diff line number Diff line Loading @@ -191,7 +191,7 @@ class Chip(FocalPlane): """Return the filter index and type for a given chip #(chipID) """ filter_type_list = _util.ALL_FILTERS if chipID == None: if chipID is None: chipID = self.chipID # updated configurations Loading
observation_sim/instruments/chip/chip_utils.py +2 −2 Original line number Diff line number Diff line Loading @@ -206,7 +206,7 @@ def get_poisson(seed=0, sky_level=0.): def get_base_img(img, chip, read_noise, readout_time, dark_noise, exptime=150., InputDark=None): if InputDark == None: if InputDark is None: # base_level = read_noise**2 + dark_noise*(exptime+0.5*readout_time) # base_level = dark_noise*(exptime+0.5*readout_time) base_level = dark_noise*(exptime) Loading Loading @@ -237,7 +237,7 @@ def add_poisson(img, chip, exptime=150., seed=0, sky_level=0., poisson_noise=Non img.addNoise(poisson_noise) # img -= read_noise**2 if InputDark != None: if InputDark is not None: # "Instrument/data/dark/dark_1000s_example_0.fits" hdu = fits.open(InputDark) img += hdu[0].data/hdu[0].header['exptime']*exptime Loading
observation_sim/sim_steps/add_pattern_noise.py +1 −1 Original line number Diff line number Diff line Loading @@ -80,6 +80,6 @@ def add_bias(self, chip, filt, tel, pointing, catalog, obs_param): nsecy=chip.nsecy, nsecx=chip.nsecx, seed=self.overall_config["random_seeds"]["seed_biasNonUniform"]+chip.chipID) elif obs_param["bias_16channel"] == False: elif obs_param["bias_16channel"] is False: chip.img += chip.bias_level return chip, filt, tel, pointing
observation_sim/instruments/_util.py +1 −1 File changed.Contains only whitespace changes. Show changes