Skip to content
Permalink
Browse files
Automatic multi-file rename: tevpy -> gammapy
  • Loading branch information
cdeil committed Aug 19, 2013
1 parent e75e0db commit 7e955ff
Show file tree
Hide file tree
Showing 47 changed files with 147 additions and 147 deletions.
@@ -44,6 +44,6 @@ MANIFEST

*.ipynb_checkpoints

tevpy/tevpy.cfg
gammapy/gammapy.cfg

docs/_generated
@@ -1,7 +1,7 @@
include README.rst

include distribute_setup.py
recursive-include tevpy *.pyx *.c
recursive-include gammapy *.pyx *.c

recursive-include docs *
recursive-include licenses *
@@ -1,10 +1,10 @@
tevpy
gammapy
=====

TeV gamma-ray astronomy high-level data analysis Python package

* Code: https://github.com/gammapy/tevpy
* Docs: https://tevpy.readthedocs.org/
* Code: https://github.com/gammapy/gammapy
* Docs: https://gammapy.readthedocs.org/

.. image:: https://travis-ci.org/gammapy/tevpy.png
:target: https://travis-ci.org/gammapy/tevpy
.. image:: https://travis-ci.org/gammapy/gammapy.png
:target: https://travis-ci.org/gammapy/gammapy
@@ -46,19 +46,19 @@
# -- Project information ------------------------------------------------------

# This does not *have* to match the package name, but typically does
project = u'tevpy'
author = u'The tevpy Developers'
project = u'gammapy'
author = u'The gammapy Developers'
copyright = u'2012, ' + author

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.

import tevpy
import gammapy
# The short X.Y version.
version = tevpy.__version__.split('-', 1)[0]
version = gammapy.__version__.split('-', 1)[0]
# The full version, including alpha/beta/rc tags.
release = tevpy.__version__
release = gammapy.__version__


# -- Options for HTML output ---------------------------------------------------
@@ -95,7 +95,7 @@

# First TeV gamma-ray image: the supernova remnant RX J1713 with HESS
# http://apod.nasa.gov/apod/ap041105.html
html_favicon = '_static/tevpy_logo.ico'
html_favicon = '_static/gammapy_logo.ico'

# TODO: set this image also in the title bar
# (html_logo is not the right option)
@@ -134,8 +134,8 @@

# Don't import the module as "version" or it will override the
# "version" configuration parameter
from tevpy import version as versionmod
edit_on_github_project = "gammapy/tevpy"
from gammapy import version as versionmod
edit_on_github_project = "gammapy/gammapy"
if versionmod.release:
edit_on_github_branch = "v" + versionmod.version
else:
@@ -7,7 +7,7 @@ this package is here:
.. toctree::
:maxdepth: 2

tevpy/index.rst
gammapy/index.rst

.. note:: Do not edit this page - instead, place all documentation for the
affiliated package inside ``packagename/``
@@ -1,13 +1,13 @@
**********************************************************
Astrophysical source and population models (`tevpy.astro`)
Astrophysical source and population models (`gammapy.astro`)
**********************************************************

.. currentmodule:: tevpy.astro
.. currentmodule:: gammapy.astro

Introduction
============

`tevpy.astro` implements some common astrophysical source and population models.
`gammapy.astro` implements some common astrophysical source and population models.

TODO: describe

@@ -19,5 +19,5 @@ TODO: describe
Reference/API
=============

.. automodapi:: tevpy.astro
.. automodapi:: gammapy.astro
:no-inheritance-diagram:
@@ -1,18 +1,18 @@
********************************************************
Background estimation and modeling (`tevpy.background`)
Background estimation and modeling (`gammapy.background`)
********************************************************

.. currentmodule:: tevpy.background
.. currentmodule:: gammapy.background

Introduction
============

`tevpy.background` contains methods to estimate and model background.
`gammapy.background` contains methods to estimate and model background.

At the moment it also contains a lot of image-processing related functionality
that maybe should be split into a separate `image` package.

The main data structure is the `~tevpy.background.maps.Maps` container ... TODO
The main data structure is the `~gammapy.background.maps.Maps` container ... TODO

Most of the methods implemented are described in [Berge2007]_.
Section 7.3 "Background subtraction"
@@ -25,6 +25,6 @@ Getting Started

TODO

.. automodapi:: tevpy.background
.. automodapi:: gammapy.background
:no-inheritance-diagram:

@@ -31,7 +31,7 @@ Usually it has many more columns with information about each run::
Run,Telescope_Pattern,Date,Duration,GLON,GLAT,Target,Zenith
1234,24,2013-03-22 14:32,1832,83.7,-5.2,Crab Nebula,32

Special column names that the `tevpy` analysis tools understand:
Special column names that the `gammapy` analysis tools understand:

* `Run` --- Run number (int)
* `Telescope_Pattern` --- Binary pattern describing which telescopes participated in the run
@@ -1,17 +1,17 @@
***********************
Datasets (`tevpy.data`)
Datasets (`gammapy.data`)
***********************

.. currentmodule:: tevpy.data
.. currentmodule:: gammapy.data

Introduction
============

`tevpy.data` holds a few datasets used in the examples and tests.
Some are included with `tevpy`, some are downloaded from the web via
`gammapy.data` holds a few datasets used in the examples and tests.
Some are included with `gammapy`, some are downloaded from the web via

>>> import tevpy.data
>>> tevpy.data.download_datasets()
>>> import gammapy.data
>>> gammapy.data.download_datasets()

TODO: Give summary table of available datasets here.

@@ -31,5 +31,5 @@ TODO: give an example.
Reference/API
=============

.. automodapi:: tevpy.data
.. automodapi:: gammapy.data
:no-inheritance-diagram:
@@ -1,13 +1,13 @@
***************************************
Source detection tools (`tevpy.detect`)
Source detection tools (`gammapy.detect`)
***************************************

.. currentmodule:: tevpy.detect
.. currentmodule:: gammapy.detect

Introduction
============

`tevpy.detect` holds source detection methods that turn event lists or images or cubes
`gammapy.detect` holds source detection methods that turn event lists or images or cubes
into source catalogs.

* TODO: Describe references: [Stewart2009]_
@@ -24,21 +24,21 @@ Getting Started
Reference/API
=============

.. automodapi:: tevpy.detect.blob
.. automodapi:: gammapy.detect.blob
:no-inheritance-diagram:

.. automodapi:: tevpy.detect.cwt
.. automodapi:: gammapy.detect.cwt
:no-inheritance-diagram:

.. automodapi:: tevpy.detect.matched_filter
.. automodapi:: gammapy.detect.matched_filter
:no-inheritance-diagram:

.. automodapi:: tevpy.detect.sex
.. automodapi:: gammapy.detect.sex
:no-inheritance-diagram:

.. automodapi:: tevpy.detect.test_statistic
.. automodapi:: gammapy.detect.test_statistic
:no-inheritance-diagram:

.. automodapi:: tevpy.detect.utils
.. automodapi:: gammapy.detect.utils
:no-inheritance-diagram:

@@ -1,17 +1,17 @@
***************************************************
Image processing and analysis tools (`tevpy.image`)
Image processing and analysis tools (`gammapy.image`)
***************************************************

.. currentmodule:: tevpy.image
.. currentmodule:: gammapy.image

Introduction
============

`tevpy.image` contains image processing and analysis methods that are
`gammapy.image` contains image processing and analysis methods that are
not readily found (yet) in `scipy.ndimage`, `scikit-image`, `astropy` or `photutils`:

* `tevpy.image.profile`: Compute 1D profiles from 2D images
* `tevpy.image.measure`: Measure source properties in labeled regions
* `gammapy.image.profile`: Compute 1D profiles from 2D images
* `gammapy.image.measure`: Measure source properties in labeled regions


Getting Started
@@ -22,5 +22,5 @@ TODO
Reference/API
=============

.. automodapi:: tevpy.image
.. automodapi:: gammapy.image
:no-inheritance-diagram:
@@ -1,22 +1,22 @@
`tevpy`
`gammapy`
=======

What is it?
-----------

`tevpy` is an open source (BSD licensed) TeV gamma-ray astronomy high-level data analysis Python package.
`gammapy` is an open source (BSD licensed) TeV gamma-ray astronomy high-level data analysis Python package.

It contains some analysis methods,
but it's main purpose is to be the glue between the many
existing data formats and other tools.

* Code / Bug reports / Feature requests / Development: https://github.com/gammapy/tevpy
* Docs: https://tevpy.readthedocs.org/
* Code / Bug reports / Feature requests / Development: https://github.com/gammapy/gammapy
* Docs: https://gammapy.readthedocs.org/
* Mailing list: http://groups.google.com/group/gammapy
* License: BSD-3-Clause


Using `tevpy`
Using `gammapy`
-------------

Start by reading the :ref:`introduction`.
@@ -50,5 +50,5 @@ Contact

Found a bug or missing feature?

Make an issue or pull request on `GitHub <https://github.com/gammapy/tevpy>`_.
Make an issue or pull request on `GitHub <https://github.com/gammapy/gammapy>`_.

@@ -3,22 +3,22 @@
Installation
============

To install the latest `tevpy` stable version the easiest way is using the `pip <http://www.pip-installer.org/>`_ installer::
To install the latest `gammapy` stable version the easiest way is using the `pip <http://www.pip-installer.org/>`_ installer::

pip install tevpy
pip install gammapy

To install the latest developer version of `tevpy`, use::
To install the latest developer version of `gammapy`, use::

git clone https://github.com/gammapy/tevpy.git
git clone https://github.com/gammapy/gammapy.git
cd astropy
python setup.py install

To check if `tevpy` is correctly installed, start up python or ipython, import `tevpy` and run the unit tests::
To check if `gammapy` is correctly installed, start up python or ipython, import `gammapy` and run the unit tests::

>>> import tevpy
>>> tevpy.test()
>>> import gammapy
>>> gammapy.test()

To check if the `tevpy` command line tools are on your `$PATH` try this::
To check if the `gammapy` command line tools are on your `$PATH` try this::

$ tev-lookup-map-values --help

@@ -43,7 +43,7 @@ Optional dependencies (imported and used only where needed):
* `imfun`_ for a trous wavelet decomposition

.. note:: I didn't put any effort into minimizing the number of dependencies,
since `tevpy` is a prototype. Should it develop into a package that is actually used
since `gammapy` is a prototype. Should it develop into a package that is actually used
by a few people I'll limit the optional packages to what is actually necessary.

.. _scikit-image: http://scikit-image.org
@@ -6,36 +6,36 @@ Introduction
Show me some code!
------------------

`tevpy` gives you easy access to some frequently used methods in TeV gamma-ray astronomy from Python.
`gammapy` gives you easy access to some frequently used methods in TeV gamma-ray astronomy from Python.

What's the statistical significance when 10 events have been observed with a known background level of 4.2
according to [LiMa1983]_?
`tevpy.stats` knows::
`gammapy.stats` knows::

>>> from tevpy.stats import significance
>>> from gammapy.stats import significance
>>> significance(n_observed=10, mu_background=4.2, method='lima')
2.3979181291475453

What's the differential gamma-ray flux and spectral index of the Crab nebula at 3 TeV
according to [Meyer2010]_?
`tevpy.spec` knows::
`gammapy.spec` knows::

>>> from tevpy.spec import crab
>>> from gammapy.spec import crab
>>> energy = 3
>>> crab.diff_flux(energy, ref='meyer')
1.8993523278650278e-12
>>> crab.spectral_index(energy, ref='meyer')
2.6763224503600429

All functionality is in subpackages (e.g. `tevpy.stats` or `tevpy.spec`) ...
All functionality is in subpackages (e.g. `gammapy.stats` or `gammapy.spec`) ...
browse their docs (see list below) to see if it contains the methods you want.

But I don't know how to code in Python!
---------------------------------------

Hmm ... OK.

Some of the `tevpy` functionality can be called from command line tools.
Some of the `gammapy` functionality can be called from command line tools.

But, to be honest, if you're an astronomer, you should learn to code in Python.
Start at http://python4astronomers.github.io or `here <http://www.astropy.org>`_
@@ -65,11 +65,11 @@ Other related packages
There are several other great open source packages for
TeV data analysis (alphabetical order):

* `act-analysis`_ --- a similar package as ``tevpy`` by Karl Kosack
* `act-analysis`_ --- a similar package as ``gammapy`` by Karl Kosack
* `gammafits`_ --- an SED modeling and fitting package by Victor Zabalza
* `gammalib`_ and `ctools`_ --- Gamma-ray data analysis library and tools by Jürgen Knödlseder
* `gamma-speed`_ --- benchmarking of TeV data analysis tools by Andrei Ignat
* `PyFACT`_ --- a similar package as ``tevpy`` by Martin Raue
* `PyFACT`_ --- a similar package as ``gammapy`` by Martin Raue

.. _act-analysis: https://bitbucket.org/kosack/act-analysis
.. _PyFACT: http://pyfact.readthedocs.org

0 comments on commit 7e955ff

Please sign in to comment.