Network Tools for Astronomy

The network tools paper is here. All the scripts in a tar file are here. This script does a simple sftp transfer of files from one machine to another. It assumes a no-password public key between the systems, or else it will prompt for a password. This type of script could, as a cron job, automatically backup disks in off-hours, or transfer files that pass a certain age, etc. Similar to the script, but using the much clearer pexpect module. This script reads a webpage with the option to strip out the HTML tags. The simplest retrieval of a webpage. This script is a cheap email client, but demonstrates the use of smtplib to send mail by scripts. This script does a simple connect to NED's website to extract the coordinates of a galaxy. This script extracts the XML data from NED for the input galaxy name and prints the variable of interest. All the NED variables are listed here. Same as above, but extracts all the cross IDs for a galaxy from NED. Same as above, but extracts all photometry values for a galaxy from NED. This is the XML processing module. It is best explored by interaction and reading its help file. This script downloads FITS images from the DSS archive. Same as above, only for access to 2MASS images. This script accesses 2MASS image archive and stitchs together a 512x512 pixel image for the galaxy of interest. This script is a simple example of the more powerful mechanzie module which allows a script to behave like a browser for interaction with even the most complicated webpage.

Added Note: check out selenium for deeper web programming