CarPy

Reading time ~1 minute

You should always reduce your data carefully by hand. Unless you’re lazy or time-poor. If that’s the case and you’re using MIKE on Magellan (where this post is written from) then the CarPy pipeline will do a pretty good reduction for you in most cases.

However it turns out it’s broken on the Las Campanas Observatory computers. Here’s how to fix it:

setenv PYPREFIX /usr/local/CarPy
setenv PYTHONBASE /usr/local/CarPy/builds/Darwin.10.6.x86_64/
source /usr/local/CarPy/Setup.csh 
setenv PATH /usr/local/CarPy/builds/Darwin.10.6.x86_64/bin:/usr/local/CarPy/builds/Darwin.10.6.x86_64/Python.framework/Versions/2.5/bin:/usr/local/CarPy/dist/bin_local:/usr/local/CarPy/dist/bin:/usr/local/CarPy/dist/bin_oldnumeric:/usr/local/CarPy/builds/Darwin.10.6.x86_64/bin:/usr/local/CarPy/builds/Darwin.10.6.x86_64/Python.framework/Versions/Current/bin:/usr/local/CarPy/dist/bin_local:/usr/local/CarPy/dist/bin:/usr/local/CarPy/dist/bin_oldnumeric:/Library/Frameworks/EPD64.framework/Versions/Current/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/texbin:/usr/X11/bin:/usr/local/wcstools/bin:/usr/local/isis/bin:/usr/local/cdsclient/bin:/Applications/itt/idl/bin:/usr/local/magellan/bin:/usr/local/lco/bin
setenv PYTHONPATH /usr/local/CarPy/dist/lib_local:/usr/local/CarPy/dist/lib:/usr/local/CarPy/dist/lib_oldnumeric
setenv PYTHONDATA /usr/local/CarPy/datafiles

Now you can follow the instructions properly. But there is one additional step for the blue arm. After you’ve run this step:

mikesetup -db DATABASE_FILE -blue -all -mk Makefile

You will need to add a flag in the lampblue/Makefile file before running make. To find the right line number (it’s usually 59):

cd lampblue
grep -n mikeMatchLamps Makefile
59:	mikeMatchLamps lampblue_lamp1136fbspecs.fits -x 5 -o 4

Then just add -maxsh 300 so it looks like:

grep -n mikeMatchLamps Makefile
59:	mikeMatchLamps lampblue_lamp1136fbspecs.fits -x 5 -o 4 -maxsh 300

And now you should be good to make.

Making Python GUIs

Sometimes I want to make a simple (or complex) graphical user interface (GUI) for exploratory data analysis. I use Python, but there are ...… Continue reading

Hiatus

Published on September 13, 2015

Best and Brightest EMP Stars

Published on September 18, 2014