Skip to content

Commit

Permalink
Restructured pmmif package to make it so it can be built by setuptools.
Browse files Browse the repository at this point in the history
  • Loading branch information
simonbrownsb committed Jan 25, 2017
1 parent 9505a97 commit 93ac9ee
Show file tree
Hide file tree
Showing 21 changed files with 67 additions and 99 deletions.
File renamed without changes.
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
include README.md
include LICENSE.txt
20 changes: 19 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,20 @@
# pmmif
Predictive Modelling Metadata Interchange Format
================================================

Python support for dataset metadata for predictive modelling and data analysis.

The `pmmif` package provides two levels of support.

.pmm Metadata Files
--------------------

Classes for reading and writing extended metadata to .pmm JSON files.


Pandas DataFrame Support
------------------------

Classes for associating Pandas DataFrames with additional `type` and
`tags` annotation metadata, including support for persisting additional
metadata alongside `feather` datafiles.

75 changes: 0 additions & 75 deletions dist.sh

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 6 additions & 0 deletions pmmif/version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
from __future__ import print_function

version = '0.1.03'

if __name__ == '__main__':
print(version)
2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[metadata]
description-file = README.md
50 changes: 38 additions & 12 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,43 @@
import os
from setuptools import setup, find_packages

from pmmif.version import version as __version__

def read(fname):
# read contents of file
return open(os.path.join(os.path.dirname(__file__), fname)).read()

def data(path, pathitems):
# build list of additional files to package up from a subdirectory
names = []
for relpath in pathitems:
subpath = path + [relpath]
dirname = os.path.join(*subpath)
for name in os.listdir(dirname):
pathname = os.path.join(relpath, name)
fullpathname = os.path.join(dirname, name)
if os.path.isdir(fullpathname):
names.extend(data(path, [pathname]))
else:
names.append(pathname)
return names

setup(
name = 'pmmif',
version = '@@VERSION@@',
author = 'Stochastic Solutions Limited',
description = 'Predictive Modelling Metadata Interchange Format',
license = 'MIT',
url = 'http://www.tdda.info',
keywords = 'predictive modelling metadata',
namespace_packages = ['pmmif'],
packages = find_packages(),
package_data = {
'': [ 'data/*.*', 'doc/Makefile', 'doc/source/*.*'],
name='pmmif',
version=__version__,
author='Stochastic Solutions Limited',
author_email='info@StochasticSolutions.com',
description='Predictive Modelling Metadata Interchange Format',
long_description=read('README.md'),
license='MIT',
url='http://www.tdda.info',
download_url='https://github.com/tdda/pmmif',
keywords='predictive modelling metadata',
packages=find_packages(),
package_data={
'pmmif': ['README.md', 'LICENSE.txt'] + data(['pmmif'],
['doc', 'data']),
},
zip_safe=False,
install_requires = ['numpy>=1.9'],
install_requires=['numpy>=1.9'],
)
11 changes: 0 additions & 11 deletions version.py

This file was deleted.

0 comments on commit 93ac9ee

Please sign in to comment.