Skip to content

Commit

Permalink
Added code_maintenance.py
Browse files Browse the repository at this point in the history
git-svn-id: https://pymc.googlecode.com/svn/trunk@1158 15d7aa0b-6f1a-0410-991a-d59f85d14984
  • Loading branch information
anand.prabhakar.patil committed Jan 15, 2009
1 parent 615819c commit a760a0b
Show file tree
Hide file tree
Showing 62 changed files with 1,136 additions and 1,118 deletions.
58 changes: 29 additions & 29 deletions DEVELOPERS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,73 +4,73 @@ Developer Cheat Sheet

The setup.py file
~~~~~~~~~~~~~~~~~
The setup.py script describes how to build the software, and what is
needed to build the software is also what is included in the source
distribution.
The setup.py script describes how to build the software, and what is
needed to build the software is also what is included in the source
distribution.

To include other files, such as documentation, specify the names or
pattern in :file:`MANIFEST.in`.
To include other files, such as documentation, specify the names or
pattern in :file:`MANIFEST.in`.

Before uploading a package to PyPi, make sure you have the correct version
number defined in setup.py.
number defined in setup.py.



Creating source and binary distributions:

* Source::

python setup.py sdist

* Windows::

python setup.py bdist_wininst

* POSIX::

python setup.py bdist


To upload to PyPi::

python setup.py sdist upload

To simply change the information about the package on the PyPi page (as defined in setup.py)::

python setup.py register

To upload to GoogleCode download section::

python setup.py upload2google --src (or --windows)


To tag the 2.1.1 release::

svn cp https://pymc.googlecode.com/svn/trunk \
https://pymc.googlecode.com/svn/tags/2.1.1 \
-m "Tagging the 2.1.1 release."
Conventions:


Conventions:

* alpha release (a) -- Not everything is implemented, this is generally for internal testers. PyMC is not likely to need alpha releases any time soon.

* beta release (b) -- Everything is implemented, and the code is released to experienced users.

* release candidate (rc1) -- Released to a wider audience to make sure there are no installation issues and tests pass on more platforms than those used by the devs.

* Major release (2.0) -- Release where some API breaking is allowed.
* Minor release (2.1) -- Release introducing new features, but no API breaks.
* Bug fix release (2.1.1) -- Duh.

* Minor release (2.1) -- Release introducing new features, but no API breaks.

* Bug fix release (2.1.1) -- Duh.



Buildind the docs
~~~~~~~~~~~~~~~~~
The docs are currently written in LaTeX and are stored in the docs/ directory. Some of the files (README.tex, INSTALL.tex and database.tex) are automatically generated from README.txt, INSTALL.txt and pymc/database/README.txt using rst2latex. The build process is coded in builddocs and is quite obfuscated. The plan is to move the documentation to Sphinx, since this is fast becoming the standard for Python projects. This will simplify synchronising docstrings and the documentation.

The docs are currently written in LaTeX and are stored in the docs/ directory. Some of the files (README.tex, INSTALL.tex and database.tex) are automatically generated from README.txt, INSTALL.txt and pymc/database/README.txt using rst2latex. The build process is coded in builddocs and is quite obfuscated. The plan is to move the documentation to Sphinx, since this is fast becoming the standard for Python projects. This will simplify synchronising docstrings and the documentation.



Expand All @@ -80,5 +80,5 @@ Trunk stability
The trunk/ should always be stable; meaning that it should pass the test
suite at all time. This means developers should always run pymc.test()
before committing their changes. If a change breaks something that was
not covered by the test suite, then it's a good idea to write a
regression test to make sure that doesn't happen again.
not covered by the test suite, then it's a good idea to write a
regression test to make sure that doesn't happen again.
108 changes: 54 additions & 54 deletions INSTALL.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,71 +8,71 @@ PyMC Installation Instructions
:Web site: http://code.google.com/p/pymc/
:Copyright: This document has been placed in the public domain.

PyMC is known to run on Mac OS X, Linux and Windows, but in theory should be
PyMC is known to run on Mac OS X, Linux and Windows, but in theory should be
able to work on just about any platform for which Python, a Fortran compiler
and the NumPy module are available. However, installing some extra
depencies can greatly improve PyMC's performance and versatility.
The following describes the required and optional dependencies and takes you
through the installation process.
and the NumPy module are available. However, installing some extra
depencies can greatly improve PyMC's performance and versatility.
The following describes the required and optional dependencies and takes you
through the installation process.



Dependencies
============

PyMC requires some prerequisite packages to be present on the system.
Fortunately, there are currently only a few dependencies, and all are
PyMC requires some prerequisite packages to be present on the system.
Fortunately, there are currently only a few dependencies, and all are
freely available online.

* `Python`_ version 2.5.
* `Python`_ version 2.5.

* `NumPy`_ (1.2 or newer): The fundamental scientific programming package, it provides a
multidimensional array type and many useful functions for numerical analysis.
* `NumPy`_ (1.2 or newer): The fundamental scientific programming package, it provides a
multidimensional array type and many useful functions for numerical analysis.

* `Matplotlib`_ (optional): 2D plotting library which produces publication
* `Matplotlib`_ (optional): 2D plotting library which produces publication
quality figures in a variety of image formats and interactive environments

* `pyTables`_ (optional): Package for managing hierarchical datasets and
* `pyTables`_ (optional): Package for managing hierarchical datasets and
designed to efficiently and easily cope with extremely large amounts of data.
Requires the `HDF5`_ library.
Requires the `HDF5`_ library.

* `pydot`_ (optional): Python interface to Graphviz's Dot language, it allows
PyMC to create both directed and non-directed graphical representations of models.
Requires the `Graphviz`_ library.
Requires the `Graphviz`_ library.

* `SciPy`_ (optional): Library of algorithms for mathematics, science
* `SciPy`_ (optional): Library of algorithms for mathematics, science
and engineering.

* `IPython`_ (optional): An enhanced interactive Python shell and an
architecture for interactive parallel computing.
* `IPython`_ (optional): An enhanced interactive Python shell and an
architecture for interactive parallel computing.

* `nose`_ (optional): A test discovery-based unittest extension (required
to run the test suite).


There are prebuilt distributions that include all required dependencies. For
Mac OSX users, we recommend the `MacPython`_ distribution, the
`Enthought Python Distribution`_, or Python 2.5.1 that ships with
OSX 10.5 (Leopard). Windows users should download and install the
`Enthought Python Distribution`_. The Enthought Python Distribution comes
There are prebuilt distributions that include all required dependencies. For
Mac OSX users, we recommend the `MacPython`_ distribution, the
`Enthought Python Distribution`_, or Python 2.5.1 that ships with
OSX 10.5 (Leopard). Windows users should download and install the
`Enthought Python Distribution`_. The Enthought Python Distribution comes
bundled with these prerequisites. Note that depending on the currency of these
distributions, some packages may need to be updated manually.

If instead of installing the prebuilt binaries you prefer (or have) to build
If instead of installing the prebuilt binaries you prefer (or have) to build
``pymc`` yourself, make sure you have a Fortran and a C compiler. There are free
compilers (gfortran, gcc) available on all platforms. Other compilers have not been
tested with PyMC but may work nonetheless.
tested with PyMC but may work nonetheless.


.. _`Python`: http://www.python.org/.
.. _`Python`: http://www.python.org/.

.. _`NumPy`: http://www.scipy.org/NumPy

.. _`Matplotlib`: http://matplotlib.sourceforge.net/

.. _`MacPython`: http://www.activestate.com/Products/ActivePython/

.. _`Enthought Python Distribution`:
.. _`Enthought Python Distribution`:
http://www.enthought.com/products/epddownload.php

.. _`SciPy`: http://www.scipy.org/
Expand All @@ -95,10 +95,10 @@ The easiest way to install PyMC is to type in a terminal::

easy_install pymc

Provided `EasyInstall`_ (part of the `setuptools`_ module) is installed
and in your path, this should fetch and install the package from the
`Python Package Index`_. Make sure you have the appropriate administrative
privileges to install software on your computer.
Provided `EasyInstall`_ (part of the `setuptools`_ module) is installed
and in your path, this should fetch and install the package from the
`Python Package Index`_. Make sure you have the appropriate administrative
privileges to install software on your computer.

.. _`Python Package Index`: http://pypi.python.org/pypi

Expand All @@ -112,12 +112,12 @@ Installing from pre-built binaries
Pre-built binaries are available for Windows XP and Mac OS X. There are at least
two ways to install these:

1. Download the installer for your platform from `PyPI`_.
1. Download the installer for your platform from `PyPI`_.

2. Double-click the executable installation package, then follow the
2. Double-click the executable installation package, then follow the
on-screen instructions.

For other platforms, you will need to build the package yourself from source.
For other platforms, you will need to build the package yourself from source.
Fortunately, this should be relatively straightforward.

.. _`PyMC site`: pymc.googlecode.com
Expand All @@ -126,27 +126,27 @@ Fortunately, this should be relatively straightforward.
Compiling the source code
=========================

First download the source code tarball from `PyPI`_ and unpack it. Then move
First download the source code tarball from `PyPI`_ and unpack it. Then move
into the unpacked directory and follow the platform specific instructions.

Windows
-------

One way to compile PyMC on Windows is to install `MinGW`_ and `MSYS`_. MinGW is
the GNU Compiler Collection (GCC) augmented with Windows specific headers and
libraries. MSYS is a POSIX-like console (bash) with UNIX command line tools.
Download the `Automated MinGW Installer`_ and double-click on it to launch
the installation process. You will be asked to select which
components are to be installed: make sure the g77 compiler is selected and
proceed with the instructions. Then download and install `MSYS-1.0.exe`_,
launch it and again follow the on-screen instructions.

Once this is done, launch the MSYS console, change into the PyMC directory and
libraries. MSYS is a POSIX-like console (bash) with UNIX command line tools.
Download the `Automated MinGW Installer`_ and double-click on it to launch
the installation process. You will be asked to select which
components are to be installed: make sure the g77 compiler is selected and
proceed with the instructions. Then download and install `MSYS-1.0.exe`_,
launch it and again follow the on-screen instructions.

Once this is done, launch the MSYS console, change into the PyMC directory and
type::

python setup.py install

This will build the C and Fortran extension and copy the libraries and python
This will build the C and Fortran extension and copy the libraries and python
modules in the C:/Python25/Lib/site-packages/pymc directory.


Expand All @@ -166,8 +166,8 @@ In a terminal, type::
python setup.py build
sudo python setup.py install

The `sudo` command is required to install PyMC into the Python ``site-packages``
directory if it has restricted privileges. You will be prompted for a password,
The `sudo` command is required to install PyMC into the Python ``site-packages``
directory if it has restricted privileges. You will be prompted for a password,
and provided you have superuser privileges, the installation will proceed.


Expand All @@ -180,12 +180,12 @@ and provided you have superuser privileges, the installation will proceed.
Development version
===================

You can check out the bleeding edge version of the code from the `subversion`_
You can check out the bleeding edge version of the code from the `subversion`_
repository::

svn checkout http://pymc.googlecode.com/svn/trunk/ pymc
Previous versions are available in the ``/tags`` directory.

Previous versions are available in the ``/tags`` directory.

.. _`subversion`: http://subversion.tigris.org/

Expand All @@ -195,15 +195,15 @@ Running the test suite

``pymc`` comes with a set of tests that verify that the critical components
of the code work as expected. To run these tests, users must have `nose`_
installed. The tests are launched from a python shell::
installed. The tests are launched from a python shell::

import pymc
pymc.test()

In case of failures, messages detailing the nature of these failures will
In case of failures, messages detailing the nature of these failures will
appear. In case this happens (it shouldn't), please report
the problems on the `issue tracker`_, specifying the version you are using and
the environment.
the problems on the `issue tracker`_, specifying the version you are using and
the environment.

.. _`nose`: http://somethingaboutorange.com/mrl/projects/nose/

Expand All @@ -213,8 +213,8 @@ the environment.
Bugs and feature requests
=========================

Report problems with the installation, bugs in the code or feature request at
the `issue tracker`_. Comments and questions are welcome and should be
Report problems with the installation, bugs in the code or feature request at
the `issue tracker`_. Comments and questions are welcome and should be
addressed to PyMC's `mailing list`_.


Expand Down
Loading

0 comments on commit a760a0b

Please sign in to comment.