Computing
Tips, tricks, and scripts
Some of my favorite packages:
Python library focused on general astronomy/astrophysics
For querying online astronomical resources. I am a contributor and helped implement and maintain the ephemeris query codes.
Python library focused on small solar system objects. Best for comet and asteroid work. I co-founded this package along with Michael Mommert, Miguel de Val Borro, and Jian-Yang Li.
A must if you work with NAIF's SPICE toolkit.
Simulates photometric data and spectra.
Display numpy arrays in SAOImage DS9. See tip below.
Python toolkit for astronomical image viewers.
pyds9 and iPython startup
Display numpy arrays in DS9. My favorite short-cut is to define a .view method for DS9, which I find easier to type for interactive work than .set_np2arr. I have an iPython profile named scipy. After initializing with ipython --profile=scipy, create the file .ipython/profile_scipy/startup/99-user.py (location for GNU/Linux systems) with the following content:
from importlib import reload
import scipy.ndimage as nd
import matplotlib as mpl
import matplotlib.pyplot as plt
from matplotlib.pyplot import *
try:
from astropy.io import fits, ascii
from astropy.table import Table
import astropy.units as u
import astropy.constants as const
from astropy.coordinates import Angle
from astropy.time import Time
except ImportError:
pass
try:
from sbpy.data import *
from sbpy.activity import *
except ImportError:
pass
try:
import pyds9
pyds9.DS9.view = pyds9.DS9.set_np2arr
except ImportError:
pass
try:
import mskpy
from mskpy import *
except ImportError:
pass