Skip to content

Client tools for using CADC services

Notifications You must be signed in to change notification settings

SharonGoliath/cadctools

 
 

Repository files navigation

cadctools

Client tools and utilities for using Canadian Astronomy Data Centre services

Developers Guide

Requires pip.

Installing Packages

cd cadcutils && pip install -r ./dev_requirements.txt
cd cadcdata && pip install -r ./dev_requirements.txt
cd cadcetrans && pip install -r ./dev_requirements.txt
cd cadccutout && pip install -r ./dev_requirements.txt

Testing packages

Testing cadcutils

cd ./cadcutils
python setup.py test

Testing cadcdata

cd ./cadcdata
python setup.py test

Checkstyle

flake8 style checking is enforced on pull requests. Following commands should not report errors

flake8 cadcutils/cadcutils cadcdata/cadcdata cadcetrans/cadcetrans
cadccutout/cadccutout

Usage Example

In library mode

Write the following into a file named test.py

from cadcdata import CadcDataClient
from cadcutils import net

client = CadcDataClient(net.Subject())
print(client.get_file_info('GEMINI', '00AUG02_002'))

Then Run

python test.py

Direct Usage

After installing the cadcdata package, run

cadc-data get GEMINI 00AUG02_002

This will download the fits file to your current directory.

To see more information do

cadc-data put --help
cadc-data get --help
cadc-data info --help

Docker image

Rather than deploying a project environment, you could just use docker.

To use

  1. Install docker.

  2. Then run:

    docker build . -t cadc/cadctools
    docker run --name cadctools cadc/cadctools
    

About

Client tools for using CADC services

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 95.4%
  • Makefile 2.0%
  • Batchfile 1.9%
  • Other 0.7%