Commit 4168b748 authored by Zhang Xin's avatar Zhang Xin
Browse files

update header; fix sls bug: psf A and B error, modify the band bounders of sls

parent 877d689f
Loading
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -533,8 +533,8 @@ def generateExtensionHeader(chip, xlen=9216, ylen=9232, ra=60, dec=-40, pa=-23.4
    # h_ext['CCDCHIP'] = CCDID[k - 1].rjust(2, '0')
    # h_ext['CCDLABEL'] = filters[k-1] + '-' + filterID[k-1]
    # h_ext['FILTER'] = filters[k-1]
    h_ext['CHIPID'] = str(chip.chipID).rjust(2, '0')
    h_ext['CHIPLABL'] = chip.chip_name
    h_ext['DETECTOR'] = str(chip.chipID).rjust(2, '0')
    h_ext['DETLABEL'] = chip.chip_name
    h_ext['FILTER'] = chip.filter_type
    h_ext['NAXIS1'] = xlen
    h_ext['NAXIS2'] = ylen
+3 −3
Original line number Diff line number Diff line
@@ -37,9 +37,9 @@ class FilterParam(object):
                # [TODO]
                "FGS":   [5000.0,  8000.0,  3000.0,  11000.0,  0.6500, 0.164, 0., 30.],

                "GU":    [0.0,        0.0,  2550.0,   4200.0,     1.0, 0.037, 14.0, 26.0],
                "GV":    [0.0,        0.0,  4000.0,   6500.0,     1.0, 0.037, 14.0, 26.0],
                "GI":    [0.0,        0.0,  6200.0,  10000.0,     1.0, 0.037, 14.0, 26.0],
                "GU":    [0.0,        0.0,  2550.0,   10000.0,     1.0, 0.037, 14.0, 26.0],
                "GV":    [0.0,        0.0,  3500.0,   6500.0,     1.0, 0.037, 14.0, 26.0],
                "GI":    [0.0,        0.0,  5000.0,  10000.0,     1.0, 0.037, 14.0, 26.0],
            }
        else:
            filtP = filter_param
+14 −12
Original line number Diff line number Diff line
@@ -335,7 +335,7 @@ class Galaxy(MockObject):
                pos_img_local[1] = pos_img.y - y_start
                nnx = 0
                nny = 0
                for order in ["B", "A"]:
                for order in ["A", "B"]:
                    EXTRA = False
                    if self.getMagFilter(filt) <= filt.mag_saturation-2.:
                        EXTRA = True
@@ -362,6 +362,7 @@ class Galaxy(MockObject):
                for order in ["C", "D", "E"]:
                    galImg_List.append(galImg)
            except:
                try:
                    psf, pos_shear = psf_model.get_PSF(chip=chip, pos_img=pos_img)
                    star_p = galsim.Convolve(psf, gal)
                    galImg = star_p.drawImage(wcs=chip_wcs_local, offset=offset)
@@ -371,7 +372,8 @@ class Galaxy(MockObject):
                        return 2, pos_shear
                    for order in ["A", "B", "C", "D", "E"]:
                        galImg_List.append(galImg)

                except Exception as e:
                    continue
            # starImg = gal.drawImage(
            #     wcs=chip_wcs_local, offset=offset, method='real_space')

+1 −1
Original line number Diff line number Diff line
@@ -445,7 +445,7 @@ class MockObject(object):
                pos_img_local[1] = pos_img.y - y_start
                nnx = 0
                nny = 0
                for order in ["B", "A"]:
                for order in ["A", "B"]:
                    EXTRA = False
                    if self.getMagFilter(filt) <= filt.mag_saturation-2.:
                        EXTRA = True