| Travis Oliphant | c8b5a7e | 2006-01-06 02:12:50 | [diff] [blame] | 1 | """NumPy: array processing for numbers, strings, records, and objects. |
| Travis Oliphant | da9c6da | 2006-01-04 17:31:07 | [diff] [blame] | 2 | |
| Travis Oliphant | c8b5a7e | 2006-01-06 02:12:50 | [diff] [blame] | 3 | NumPy is a general-purpose array-processing package designed to |
| Travis Oliphant | da9c6da | 2006-01-04 17:31:07 | [diff] [blame] | 4 | efficiently manipulate large multi-dimensional arrays of arbitrary |
| 5 | records without sacrificing too much speed for small multi-dimensional |
| Travis Oliphant | c8b5a7e | 2006-01-06 02:12:50 | [diff] [blame] | 6 | arrays. NumPy is built on the Numeric code base and adds features |
| Travis Oliphant | da9c6da | 2006-01-04 17:31:07 | [diff] [blame] | 7 | introduced by numarray as well as an extended C-API and the ability to |
| 8 | create arrays of arbitrary type. |
| 9 | |
| 10 | There are also basic facilities for discrete fourier transform, |
| 11 | basic linear algebra and random number generation. |
| 12 | """ |
| 13 | |
| 14 | DOCLINES = __doc__.split("\n") |
| Pearu Peterson | c415fd1 | 2002-11-18 22:39:31 | [diff] [blame] | 15 | |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 16 | import os |
| 17 | import sys |
| Pearu Peterson | c415fd1 | 2002-11-18 22:39:31 | [diff] [blame] | 18 | |
| Travis Oliphant | da9c6da | 2006-01-04 17:31:07 | [diff] [blame] | 19 | CLASSIFIERS = """\ |
| 20 | Development Status :: 4 - Beta |
| 21 | Intended Audience :: Science/Research |
| 22 | Intended Audience :: Developers |
| 23 | License :: OSI Approved |
| 24 | Programming Language :: C |
| 25 | Programming Language :: Python |
| 26 | Topic :: Software Development |
| 27 | Topic :: Scientific/Engineering |
| 28 | Operating System :: Microsoft :: Windows |
| 29 | Operating System :: POSIX |
| 30 | Operating System :: Unix |
| 31 | Operating System :: MacOS |
| 32 | """ |
| 33 | |
| Pearu Peterson | 471196b | 2006-03-31 08:59:36 | [diff] [blame] | 34 | def configuration(parent_package='',top_path=None): |
| 35 | from numpy.distutils.misc_util import Configuration |
| 36 | |
| Pearu Peterson | 17d7cfe | 2006-04-04 12:26:14 | [diff] [blame] | 37 | config = Configuration(None, parent_package, top_path) |
| Pearu Peterson | 471196b | 2006-03-31 08:59:36 | [diff] [blame] | 38 | config.set_options(ignore_setup_xxx_py=True, |
| 39 | assume_default_configuration=True, |
| 40 | delegate_options_to_subpackages=True, |
| 41 | quiet=True) |
| 42 | |
| 43 | config.add_subpackage('numpy') |
| Pearu Peterson | 17d7cfe | 2006-04-04 12:26:14 | [diff] [blame] | 44 | |
| Pearu Peterson | 471196b | 2006-03-31 08:59:36 | [diff] [blame] | 45 | config.add_data_files(('numpy',['*.txt','COMPATIBILITY', |
| 46 | 'scipy_compatibility'])) |
| Pearu Peterson | 17d7cfe | 2006-04-04 12:26:14 | [diff] [blame] | 47 | |
| 48 | config.get_version('numpy/version.py') # sets config.version |
| Pearu Peterson | 471196b | 2006-03-31 08:59:36 | [diff] [blame] | 49 | |
| 50 | return config |
| 51 | |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 52 | def setup_package(): |
| Travis Oliphant | 14db419 | 2005-09-14 22:08:46 | [diff] [blame] | 53 | |
| Travis Oliphant | da9c6da | 2006-01-04 17:31:07 | [diff] [blame] | 54 | from numpy.distutils.core import setup |
| Travis Oliphant | 14db419 | 2005-09-14 22:08:46 | [diff] [blame] | 55 | |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 56 | old_path = os.getcwd() |
| Pearu Peterson | d190674 | 2003-11-24 22:50:40 | [diff] [blame] | 57 | local_path = os.path.dirname(os.path.abspath(sys.argv[0])) |
| 58 | os.chdir(local_path) |
| Travis Oliphant | 14db419 | 2005-09-14 22:08:46 | [diff] [blame] | 59 | sys.path.insert(0,local_path) |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 60 | |
| 61 | try: |
| Pearu Peterson | 17d7cfe | 2006-04-04 12:26:14 | [diff] [blame] | 62 | from numpy.version import version |
| 63 | setup( |
| 64 | name = 'numpy', |
| 65 | version = version, # will be overwritten by configuration version |
| 66 | maintainer = "NumPy Developers", |
| 67 | maintainer_email = "numpy-discussion@lists.sourceforge.net", |
| 68 | description = DOCLINES[0], |
| 69 | long_description = "\n".join(DOCLINES[2:]), |
| 70 | url = "http://numeric.scipy.org", |
| cookedm | 2276bf7 | 2006-04-21 16:15:12 | [diff] [blame] | 71 | download_url = "http://sourceforge.net/project/showfiles.php?group_id=1369&package_id=175103", |
| Pearu Peterson | 17d7cfe | 2006-04-04 12:26:14 | [diff] [blame] | 72 | license = 'BSD', |
| 73 | classifiers=filter(None, CLASSIFIERS.split('\n')), |
| 74 | author = "Travis E. Oliphant, et.al.", |
| 75 | author_email = "oliphant@ee.byu.edu", |
| 76 | platforms = ["Windows", "Linux", "Solaris", "Mac OS-X", "Unix"], |
| 77 | configuration=configuration ) |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 78 | finally: |
| 79 | del sys.path[0] |
| 80 | os.chdir(old_path) |
| Travis Oliphant | 14db419 | 2005-09-14 22:08:46 | [diff] [blame] | 81 | return |
| Pearu Peterson | c415fd1 | 2002-11-18 22:39:31 | [diff] [blame] | 82 | |
| Travis Oliphant | 14db419 | 2005-09-14 22:08:46 | [diff] [blame] | 83 | if __name__ == '__main__': |
| Pearu Peterson | e8fa013 | 2003-03-07 18:08:28 | [diff] [blame] | 84 | setup_package() |