diff --git a/python/desc/imsim/flats.py b/python/desc/imsim/flats.py index d3b3e82e..c6b6e191 100644 --- a/python/desc/imsim/flats.py +++ b/python/desc/imsim/flats.py @@ -41,6 +41,8 @@ def make_flat(gs_det, counts_per_iter, niter, rng, buf=2, logger=None, ------- galsim.ImageF """ + config = desc.imsim.read_config() + if logger is None: logger = desc.imsim.get_logger('DEBUG', name='make_flat') if wcs is None: @@ -49,6 +51,7 @@ def make_flat(gs_det, counts_per_iter, niter, rng, buf=2, logger=None, nrow = gs_det.yMaxPix - gs_det.yMinPix + 1 flat = galsim.ImageF(ncol, nrow, wcs=wcs) sensor = galsim.SiliconSensor(rng=rng, + strength=config['ccd']['bf_strength'], treering_center=gs_det.tree_rings.center, treering_func=gs_det.tree_rings.func, transpose=True) diff --git a/python/desc/imsim/skyModel.py b/python/desc/imsim/skyModel.py index 69a7f1ff..61bbe508 100755 --- a/python/desc/imsim/skyModel.py +++ b/python/desc/imsim/skyModel.py @@ -283,9 +283,11 @@ def addNoiseAndBackground(self, image, bandpass=None, m5=None, # Use the transpose=True option since "eimages" of LSST sensors # follow the Camera Coordinate System convention where the # parallel transfer direction is along the x-axis. - nrecalc = 1e300 # disable pixel boundary updating. + config = get_config() + nrecalc = 1e300 # disable pixel boundary updating. sensor = galsim.SiliconSensor(rng=self.randomNumbers, nrecalc=nrecalc, + strength=config['ccd']['bf_strength'], treering_func=detector.tree_rings.func, treering_center=detector.tree_rings.center, transpose=True) @@ -462,11 +464,14 @@ def process_photons(self, image, skyCounts, detector, chunk_size=int(5e6)): nrow, ncol = image.array.shape dx = ncol//nx # number of pixels in x for an amp dy = nrow//ny # number of pixels in y + + config = get_config() # Disable the updating of the pixel boundaries by # setting nrecalc to 1e300 nrecalc = 1e300 sensor = galsim.SiliconSensor(rng=self.randomNumbers, nrecalc=nrecalc, + strength=config['ccd']['bf_strength'], treering_center=tree_rings.center, treering_func=tree_rings.func, transpose=True)