source: trunk/python/__init__.py@ 1830

Last change on this file since 1830 was 1824, checked in by Malte Marquarding, 14 years ago

Refactoring of init.py. Moved functionality into separate modules. Some minor fixes to make unit test work under 'standard asap'.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.8 KB
Line 
1"""
2This is the ATNF Single Dish Analysis package.
3
4"""
5import os
6import sys
7
8# first import!
9from asap.env import *
10# second import!
11from asap.logging import *
12from asap.parameters import *
13from asap.utils import *
14# explicitly import 'hidden' functions
15from asap.utils import _n_bools, _is_sequence_or_number, _to_list
16
17
18if is_ipython():
19 from ipysupport import *
20
21# use rc parameter to enable/disable logging
22asaplog.enable(rcParams['verbose'])
23
24setup_env()
25
26# anything which uses matplotlib has to be imported after this!!!
27if rcParams['useplotter']:
28 try:
29 gui = os.environ.has_key('DISPLAY') and rcParams['plotter.gui']
30 if gui:
31 import matplotlib
32 if 'matplotlib.backends' not in matplotlib.sys.modules:
33 matplotlib.use("TkAgg")
34 from asapplotter import asapplotter
35 from matplotlib import pylab
36 xyplotter = pylab
37 plotter = asapplotter(gui)
38 except ImportError:
39 asaplog.post( "Matplotlib not installed. No plotting available")
40 print_log('WARN')
41
42from asapreader import reader
43from selector import selector
44from asapmath import *
45from scantable import scantable
46from linecatalog import linecatalog
47from asaplinefind import linefinder
48from simplelinefinder import simplelinefinder
49from interactivemask import interactivemask
50from asapfitter import fitter
51from opacity import skydip
52from opacity import model as opacity_model
53
54__date__ = '$Date: 2010-08-02 09:40:09 +0000 (Mon, 02 Aug 2010) $'.split()[1]
55__version__ = 'trunk'
56__revision__ = get_revision()
57
58def welcome():
59 return """Welcome to ASAP v%s (%s) - the ATNF Spectral Analysis Package
60
61Please report any bugs via:
62http://svn.atnf.csiro.au/trac/asap/simpleticket
63
64[IMPORTANT: ASAP is 0-based]
65Type commands() to get a list of all available ASAP commands.""" % (__version__,
66 __date__)
Note: See TracBrowser for help on using the repository browser.