Skip to content

Commit

Permalink
odes test travis upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Mukesh Mithrakumar committed Jul 7, 2019
1 parent 9242ff4 commit ecb6f87
Show file tree
Hide file tree
Showing 16 changed files with 740 additions and 50 deletions.
6 changes: 6 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[run]
omit =
tensorflow_scientific\quantum\*
tensorflow_scientific\solvers\*
C:\Users\Mukesh\AppData\Roaming\Python\Python36\*
*\__init__.py
54 changes: 54 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# http://flake8.pycqa.org/en/latest/user/options.html
# http://flake8.pycqa.org/en/latest/user/error-codes.html
# http://pycodestyle.readthedocs.io/en/latest/intro.html#error-codes

[flake8]

# Increase the verbosity of Flake8’s output.
verbose = 0
# Decrease the verbosity of Flake8’s output.
# quiet = 0

# Print the total number of errors.
count = True

# Print the source code generating the error/warning in question.
show-source = True

# Count the number of occurrences of each error/warning code and print a report.
statistics = True

# Redirect all output to the specified file.
output-file = .flake8.log

# Also print output to stdout if output-file has been configured.
tee = True

# Provide a comma-separated list of glob patterns to exclude from checks.
exclude =
.git,
__pycache__,
.venv,
.tox,
dist,
doc,
build,
*.egg

# Provide a comma-separate list of glob patterns to include for checks.
filename =
*.py

# Report all errors, even if it is on the same line as a `# NOQA` comment.
disable-noqa = False

# Set the maximum length that any line (with some exceptions) may be.
max-line-length = 120

# Specify a list of codes to ignore.
ignore =
W503,
E731

# Enable PyFlakes syntax checking of doctests in docstrings.
doctests = True
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,8 @@ check.py
/tensorflow_scientific/solvers
/tensorflow_scientific/quantum
.cache
.pytest_cache
.*log
.coverage
.benchmarks
.tox
28 changes: 28 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
dist: xenial
language: python

python:
- "3.5"
- "3.6"
- "3.7"

install:
- python setup.py -q install
- pip install -r test-requirements.txt

script:
- echo "Running Tests ..."
- pytest
- pytest -v --cov
- flake8
- coverage run --source=tensorflow_scientific -m pytest

after_success:
- coveralls

notifications:
email:
recipients:
- [email protected]
on_success: never
on_failure: always
3 changes: 3 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[pytest]
filterwarnings =
ignore::DeprecationWarning
1 change: 0 additions & 1 deletion requirements.txt

This file was deleted.

2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[bdist_wheel]
universal = 1
34 changes: 25 additions & 9 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2019 The TensorFlow Authors. All Rights Reserved.
# Copyright 2019, Mukesh Mithrakumar. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -24,39 +24,55 @@

from setuptools import find_packages
from setuptools import setup
import os
import sys

# To enable importing version.py directly, we add its path to sys.path.
version_path = os.path.join(os.path.dirname(__file__), 'tensorflow_scientific')
sys.path.append(version_path)
from version import __version__ # noqa: E402


project_name = 'tensorflow-scientific'
project_version = '1.0.0-beta0'
project_version = '0.1.0-dev'

REQUIRED_PACKAGES = [
'six >= 1.10.0',
'tensorflow==2.0.0-beta0'
]

with open('README.md', 'r') as fh:
long_description = fh.read()

setup(
name=project_name,
version=project_version.replace('-', ''),
version=__version__,
description='Scientific modeling in TensorFlow',
long_description=long_description,
long_description_content_type='text/markdown',
author='Mukesh Mithrakumar',
author_email='[email protected]',
packages=find_packages(),
author_email='[email protected]',
url='https://github.com/mukeshmithrakumar/scientific',
packages=find_packages(exclude=['tests']),
install_requires=REQUIRED_PACKAGES,
include_package_data=True,
zip_safe=False,
classifiers=[
'Development Status :: 0 - Alpha',
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'Intended Audience :: Education',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Topic :: Scientific/Engineering :: Mathematics',
'Topic :: Software Development :: Libraries :: Python Modules',
'Topic :: Software Development :: Libraries',
],
project_urls={
'Source': 'https://github.com/mukeshmithrakumar/scientific'
},
license='Apache 2.0',
keywords='tensorflow scientific',
keywords=('tensorflow', 'scientific')
)
22 changes: 22 additions & 0 deletions tensorflow_scientific/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Copyright 2019, The TensorFlow Scientific Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ==============================================================================
"""A scientific extension for TensorFlow."""

from __future__ import absolute_import
from __future__ import division
from __future__ import print_function

# flake8: noqa: F401
from tensorflow_scientific.integrate import odes
7 changes: 4 additions & 3 deletions tensorflow_scientific/integrate/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright 2019 The TensorFlow Authors. All Rights Reserved.
# Copyright 2019, Mukesh Mithrakumar. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -12,10 +12,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# ==============================================================================
"""A module containing Integration and ODE solvers for TensorFlow."""
"""Integration and ODE solver."""

from __future__ import absolute_import
from __future__ import division
from __future__ import print_function

# flake8: noqa
# flake8: noqa : F403, F401
from tensorflow_scientific.integrate.odes import *
Loading

0 comments on commit ecb6f87

Please sign in to comment.