- Timestamp:
- Nov 13, 2015, 12:11:58 PM (11 years ago)
- Location:
- trunk/ippToPsps
- Files:
-
- 3 edited
-
jython/diffbatch.py (modified) (1 diff)
-
jython/testCode.py (modified) (1 diff)
-
test/mksasdata.dvo (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/diffbatch.py
r39123 r39134 775 775 for table in tables: 776 776 # check for AP_NPIX columns: missing for SAS39 777 if table.name == "SkyChip_psf": 777 self.logger.debugPair("checking table", table.name) 778 if table.name == "SkyChip.psf": 778 779 columns = table.columns() 779 if 'AP_NPIX' in columns: 780 self.haveApNpix[num] = 1 781 if 'PSF_FWHM_MAJ' in columns: 782 self.havePsfFwhm[num] = 1 783 if 'SRC_CHIP_X' in columns: 784 self.haveSrcPos[num] = 1 785 780 for column in columns: 781 columnString = str(column) 782 if columnString == 'AP_NPIX': 783 self.haveApNpix[num] = 1 784 self.logger.debugPair("found AP_NPIX in file", fileNamePos) 785 if columnString == 'PSF_FWHM_MAJ': 786 self.havePsfFwhm[num] = 1 787 self.logger.debugPair("found PSF_FWHM_MAG in file", fileNamePos) 788 if columnString == 'SRC_CHIP_X': 789 self.haveSrcPos[num] = 1 790 self.logger.debugPair("found SRC_CHIP_X in file", fileNamePos) 786 791 787 792 myTable = table.name.replace(".","_") + "_" + str(num) -
trunk/ippToPsps/jython/testCode.py
r39103 r39134 96 96 print "words[1]: " + words[1] 97 97 98 myList = ["word1", "word2", "word3"] 99 if "word1" in myList: 100 print "found word1" 101 102 if 'word1' in myList: 103 print "alt word1" 98 104 99 105 -
trunk/ippToPsps/test/mksasdata.dvo
r39105 r39134 22 22 list expfiles -glob sasdata.v39/*.smf 23 23 list wrpfiles -glob sasdata.v39/*.wrp.*ff*.cmf 24 list diffiles -glob sasdata.v39/*.WS.dif.*.cmf 24 # list diffiles -glob sasdata.v39/*.WS.dif.*.cmf 25 list diffiles -glob sasdata.v40/*.WS.dif.*.inv.cmf 25 26 list stkfiles -glob sasdata.v39/*skycal*.cmf 26 27 … … 192 193 193 194 # create a populated catdir with a set of cmf files, save the filenames in list for use by insert.exp 194 macro mkcatdir.dif 195 if ($0 != 1) 196 echo "mkcatdir.dif "195 macro mkcatdir.dif.old 196 if ($0 != 1) 197 echo "mkcatdir.dif.old" 197 198 break 198 199 end 199 200 200 201 for i 0 $diffiles:n 201 $diff ile = $diffiles:$i202 $difffile = $diffiles:$i 202 203 echo addstar -D SKY_DEPTH 4 -D CATDIR $catdir_diff -D CATFORMAT PS1_V5 -D CAMERA gpc1 -update $diffile -D ZERO_POINT_OPTION CHIP_HEADER -accept-astrom -D ZERO_POINT_KEYWORD FPA.ZP 203 204 exec addstar -D SKY_DEPTH 4 -D CATDIR $catdir_diff -D CATFORMAT PS1_V5 -D CAMERA gpc1 -update $diffile -D ZERO_POINT_OPTION CHIP_HEADER -accept-astrom -D ZERO_POINT_KEYWORD FPA.ZP 205 # echo addstar -D CAMERA gpc1 -D CATDIR $catdir -D CATFORMAT PS1_V5 $stkfile -update -quick-airmass -D ZERO_POINT_OPTION CHIP_HEADER 206 end 207 end 208 209 # create a populated catdir with a set of cmf files, save the filenames in list for use by insert.exp 210 macro mkcatdir.dif 211 if ($0 != 1) 212 echo "mkcatdir.dif" 213 break 214 end 215 216 for i 0 $diffiles:n 217 $negfile = $diffiles:$i 218 strsub $negfile inv.cmf cmf -var posfile 219 exec rm -f diff.list.txt 220 output diff.list.txt 221 echo $posfile 222 echo $negfile 223 output stdout 224 echo addstar -D SKY_DEPTH 4 -D CATDIR $catdir_diff -D CATFORMAT PS1_V5 -D CAMERA gpc1 -update -list diff.list.txt -D ZERO_POINT_OPTION CHIP_HEADER -accept-astrom -D ZERO_POINT_KEYWORD FPA.ZP -diff-inv 225 exec addstar -D SKY_DEPTH 4 -D CATDIR $catdir_diff -D CATFORMAT PS1_V5 -D CAMERA gpc1 -update -list diff.list.txt -D ZERO_POINT_OPTION CHIP_HEADER -accept-astrom -D ZERO_POINT_KEYWORD FPA.ZP -diff-inv 204 226 # echo addstar -D CAMERA gpc1 -D CATDIR $catdir -D CATFORMAT PS1_V5 $stkfile -update -quick-airmass -D ZERO_POINT_OPTION CHIP_HEADER 205 227 end … … 380 402 381 403 for i 0 $diffiles:n 382 $filename = $diffiles:$i 383 strlen $filename Nchar 384 substr $filename 0 {$Nchar - 4} path_base; # the database needs the path without the extension (.smf/.cmf) 385 386 $diffSkyfileID = `echo $filename | fields IMAGEID | prcol 2` 404 $negfile = $diffiles:$i 405 strsub $negfile inv.cmf cmf -var posfile 406 strlen $posfile Nchar 407 substr $posfile 0 {$Nchar - 4} path_base; # the database needs the path without the extension (.smf/.cmf) 408 409 $diffSkyfileID = `echo $posfile | fields IMAGEID | prcol 2` 387 410 $skycell = "skycell.1315.090" 388 $filter = `echo $ filename | fields FPA.FILTERID | prcol 2`389 $mjd = `echo $ filename | fields MJD-OBS | prcol 2`411 $filter = `echo $posfile | fields FPA.FILTERID | prcol 2` 412 $mjd = `echo $posfile | fields MJD-OBS | prcol 2` 390 413 391 414 $wrpID = $i
Note:
See TracChangeset
for help on using the changeset viewer.
