sloancone

https://zenodo.org/badge/62136666.svg

https://img.shields.io/pypi/pyversions/sloancone https://img.shields.io/pypi/v/sloancone https://img.shields.io/github/license/thespacedoctor/sloancone https://img.shields.io/pypi/dm/sloancone

http://157.245.42.153:8080/buildStatus/icon?job=sloancone%2Fmaster&subject=build%20master http://157.245.42.153:8080/buildStatus/icon?job=sloancone%2Fdevelop&subject=build%20dev https://cdn.jsdelivr.net/gh/thespacedoctor/sloancone@master/coverage.svg https://readthedocs.org/projects/sloancone/badge/?version=master https://img.shields.io/github/issues/thespacedoctor/sloancone/type:%20bug?label=bug%20issues

SDSS conesearching tools via the CL or Python API. Return conesearch results, or simply check whether or not a location in the sky has been covered by SDSS..

Documentation for sloancone is hosted by Read the Docs ( development version and master version). The code lives on github. Please report any issues you find here.

Features

How to cite sloancone

If you use sloancone in your work, please cite using the following BibTeX entry:

@software{Young_sloancone,
    author = {Young, David R.},
    doi = {10.5281/zenodo.8038193},
    license = {GPL-3.0-only},
    title = ,
    url = {https://github.com/thespacedoctor/sloancone}
}

Installation

The easiest way to install sloancone is to use pip (here we show the install inside of a conda environment):

conda create -n sloancone python=3.7 pip
conda activate sloancone
pip install sloancone

Or you can clone the github repo and install from a local version of the code:

git clone git@github.com:thespacedoctor/sloancone.git
cd sloancone
python setup.py install

To upgrade to the latest version of sloancone use the command:

pip install sloancone --upgrade

To check installation was successful run sloancone -v. This should return the version number of the install.

Development

If you want to tinker with the code, then install in development mode. This means you can modify the code from your cloned repo:

git clone git@github.com:thespacedoctor/sloancone.git
cd sloancone
python setup.py develop

Pull requests are welcomed!

Initialisation

Before using sloancone you need to use the init command to generate a user settings file. Running the following creates a yaml settings file in your home folder under ~/.config/sloancone/sloancone.yaml:

sloancone init

The file is initially populated with sloancone’s default settings which can be adjusted to your preference.

If at any point the user settings file becomes corrupted or you just want to start afresh, simply trash the sloancone.yaml file and rerun sloancone init.

Modifying the Settings

Once created, open the settings file in any text editor and make any modifications needed.

Basic Python Setup

If you plan to use sloancone in your own scripts you will first need to parse your settings file and set up logging etc. One quick way to do this is to use the fundamentals package to give you a logger, a settings dictionary and a database connection (if connection details given in settings file):

## SOME BASIC SETUP FOR LOGGING, SETTINGS ETC
from fundamentals import tools
from os.path import expanduser
home = expanduser("~")
settingsFile  = home + "/.config/sloancone/sloancone.yaml"
su = tools(
    arguments={"settingsFile": settingsFile},
    docString=__doc__,
)
arguments, settings, log, dbConn = su.setup()

Todo List

Todo

  • nice!

(The original entry is located in /home/docs/checkouts/readthedocs.org/user_builds/sloancone/checkouts/master/docs/source/_template_.md, line 1.)

Release Notes

v0.4.3 - August 16, 2023

  • FIXED: Docs now building again on readthedocs

v0.4.2 - July 3, 2023

  • FIXED: Sloan URL endpoints changed again. Now updated.

v0.4.1 - May 20, 2022

  • FIXED: Sloan URL endpoints changed. Now updated.

v0.4.0 - May 6, 2020

  • enhancement: upgraded code to python 3

API Reference

Modules

sloancone.commonutils

common tools used throughout package

sloancone.utKit

Unit testing tools

Classes

sloancone.check_coverage

The worker class for the check_coverage module

sloancone.cone_search

The worker class for the cone_search module

sloancone.image

The worker class for the image module

sloancone.sdss_square_search

The worker class for the sdss_square_search module

A-Z Index

Modules

sloancone.commonutils

common tools used throughout package

sloancone.utKit

Unit testing tools

Classes

sloancone.check_coverage

The worker class for the check_coverage module

sloancone.cone_search

The worker class for the cone_search module

sloancone.image

The worker class for the image module

sloancone.sdss_square_search

The worker class for the sdss_square_search module

Functions

Release Notes

v0.4.3 - August 16, 2023

  • FIXED: Docs now building again on readthedocs

v0.4.2 - July 3, 2023

  • FIXED: Sloan URL endpoints changed again. Now updated.

v0.4.1 - May 20, 2022

  • FIXED: Sloan URL endpoints changed. Now updated.

v0.4.0 - May 6, 2020

  • enhancement: upgraded code to python 3