Skip to main content

Cygrid is a cython-powered convolution-based gridding module for astronomy

Project description

# Introduction #

  • Version: 0.9

  • Authors: Benjamin Winkel, Lars Flöer, Daniel Lenz

[![PyPI version](https://img.shields.io/pypi/v/cygrid.svg)](https://pypi.python.org/pypi/cygrid) [![PyPI downloads](https://img.shields.io/pypi/dm/cygrid.svg)](https://pypi.python.org/pypi/cygrid) [![Build Status](https://travis-ci.org/bwinkel/cygrid.svg?branch=master)](https://travis-ci.org/bwinkel/cygrid) [![Publication](http://img.shields.io/badge/arXiv-1604.06667-blue.svg)](http://arxiv.org/abs/1604.06667) [![License](https://img.shields.io/badge/license-GPL-blue.svg)](https://www.github.com/bwinkel/cygrid/blob/master/COPYING)

# Purpose#

cygrid allows to resample a number of spectra (or data points) to a regular grid - a data cube - using any valid astronomical FITS/WCS projection (see http://docs.astropy.org/en/stable/wcs/).

The method is a based on serialized convolution with finite gridding kernels. Currently, only Gaussian (radial-symmetric or elliptical) kernels are provided (which has the drawback of slight degradation of the effective resolution). The algorithm has very small memory footprint, allows easy parallelization, and is very fast.

A detailed description of the algorithm is given in [Winkel, Lenz & Flöer (2016)](http://adsabs.harvard.edu/abs/2016arXiv160406667W), which we kindly ask to be used as reference if you found cygrid useful for your research.

# Features

  • Supports any WCS projection system as target.

  • Conserves flux.

  • Low memory footprint.

  • Scales very well on multi-processor/core platforms.

# Usage #

### Installation ###

The easiest way to install cygrid is via pip:

` pip install cygrid `

The installation is also possible from source. Download the tar.gz-file, extract (or clone from GitHub) and simply execute

` python setup.py install `

### Dependencies ###

We kept the dependencies as minimal as possible. The following packages are required: * numpy 1.10 or later * cython 0.23.4 or later * astropy 1.0 or later (Older versions of these libraries may work, but we didn’t test this!)

If you want to run the notebooks yourself, you will also need the Jupyter server, matplotlib and wcsaxes packages.

### Examples ###

Check out the [ipython notebooks](http://nbviewer.jupyter.org/github/bwinkel/cygrid/blob/master/notebooks/index.ipynb) in the repository for some examples of how to use cygrid. Note that you only view them on the nbviewer service, and will have to clone the repository to run them on your machine.

### Who do I talk to? ###

If you encounter any problems or have questions, do not hesitate to raise an issue or make a pull request. Moreover, you can contact the devs directly:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cygrid-0.9.5.tar.gz (582.6 kB view details)

Uploaded Source

File details

Details for the file cygrid-0.9.5.tar.gz.

File metadata

  • Download URL: cygrid-0.9.5.tar.gz
  • Upload date:
  • Size: 582.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for cygrid-0.9.5.tar.gz
Algorithm Hash digest
SHA256 252411ce2e960ea6594164697bb3705ff1e37a8fb3584df01ad478d76a05b896
MD5 80a621353782082f3cefc9265509c1ee
BLAKE2b-256 65aff430bee7312409b1aa417ac31664b93bfc12069aa06fbd350cf15aa9cb6c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page