| 1 |
1. Obtain list of files to be pinned |
| 2 |
|
| 3 |
2. Create a working cdbs area: |
| 4 |
mkdir /eng/ssb/syn_pysyn/cdbs_pinned |
| 5 |
cp -r /grp/hst/cdbs/comp/ /eng/ssb/syn_pysyn/cdbs_pinned |
| 6 |
cp -r /grp/hst/cdbs/mtab /eng/ssb/syn_pysyn/cdbs_pinned |
| 7 |
ln -s /grp/hst/cdbs/grid/ /eng/ssb/syn_pysyn/cdbs_pinned |
| 8 |
ln -s /grp/hst/cdbs/extinction/ /eng/ssb/syn_pysyn/cdbs_pinned |
| 9 |
ln -s /grp/hst/cdbs/calspec/ /eng/ssb/syn_pysyn/cdbs_pinned |
| 10 |
|
| 11 |
3. Loop over the pinlist from within the shell |
| 12 |
flist=open('combined_pinlist.txt') |
| 13 |
bluelist=open('combined_bluelist.txt') |
| 14 |
out=open('combined_pinlist.log','w') |
| 15 |
outb=open('combined_bluelist.log','w') |
| 16 |
import extrap,os |
| 17 |
os.chdir('/eng/ssb/syn_pysyn/cdbs_pinned') |
| 18 |
for fname in flist: |
| 19 |
x=extrap.run(fname.strip()) |
| 20 |
out.write("%s\n"%x) |
| 21 |
flist.close() |
| 22 |
out.close() |
| 23 |
|
| 24 |
4. Loop over the blueside-only list |
| 25 |
|
| 26 |
for fname in bluelist: |
| 27 |
x=extrap.blue(fname.strip()) |
| 28 |
outb.write("%s\n"%x) |
| 29 |
bluelist.close |
| 30 |
outb.close() |
| 31 |
|
| 32 |
5. Create the new TMC file |
| 33 |
os.chdir('/eng/ssb/syn_pysyn/cdbs_pinned/') |
| 34 |
extrap.buildtmc('mtab/s8i22541m_tmc.fits') |
| 35 |
mv mtab/s8i22541m_tmc_new.fits mtab/zzz_s8i22541m_tmc.fits |