Skip to content

Commit

Permalink
Merge pull request #25 from kaklise/master
Browse files Browse the repository at this point in the history
Minor updates to documentation and tests
  • Loading branch information
kaklise authored Sep 27, 2019
2 parents 2c9a43c + 04fcec8 commit 802b252
Show file tree
Hide file tree
Showing 14 changed files with 38 additions and 123 deletions.
95 changes: 6 additions & 89 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,89 +1,6 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
env/
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
*.egg-info/
.installed.cfg
*.egg

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*,cover
.hypothesis/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
documentation/_build/

# PyBuilder
target/

# IPython Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# dotenv
.env

# virtualenv
venv/
ENV/

# Spyder project settings
.spyderproject

# Rope project settings
.ropeproject
/.project
/.coverage
*.pyc
chama.egg-info/
_build/
chama/tests/*.png
22 changes: 16 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,24 @@ sudo: false # if false, use TravisCI's container based build

matrix:
include:
- python: 2.7
env: CONDA_ENV=py27-min
- python: 2.7
env: CONDA_ENV=py27
- python: 3.4
env: CONDA_ENV=py34
services:
- xvfb
- python: 3.5
env: CONDA_ENV=py35
services:
- xvfb
- python: 3.6
env: CONDA_ENV=py36
services:
- xvfb
- python: 3.7
dist: xenial
services:
- xvfb
sudo: true
env: CONDA_ENV=py37

addons:
apt:
Expand All @@ -30,8 +38,10 @@ cache:

before_script:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
- sleep 3 # give xvfb some time to start
- if [[ "$CONDA_ENV" != "py37" ]]; then
source /etc/init.d/xvfb start;
sleep 3;
fi

# setup miniconda for numpy, scipy, pandas
before_install:
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
License Notice==============Copyright 2016-2017 National Technology & Engineering Solutions of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S. Government retains certain rights in this software.This software is distributed under the Revised BSD License.Chama also leverages a variety of third-party software packages, whichhave separate licensing policies. Revised BSD License-------------------Redistribution and use in source and binary forms, with or withoutmodification, are permitted provided that the following conditionsare met:* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.* Neither the name of Sandia National Laboratories, nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOTLIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FORA PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHTOWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITEDTO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ORPROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDINGNEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THISSOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
License Notice==============Copyright 2016-2019 National Technology & Engineering Solutions of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S. Government retains certain rights in this software.This software is distributed under the Revised BSD License.Chama also leverages a variety of third-party software packages, whichhave separate licensing policies. Revised BSD License-------------------Redistribution and use in source and binary forms, with or withoutmodification, are permitted provided that the following conditionsare met:* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.* Neither the name of Sandia National Laboratories, nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOTLIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FORA PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHTOWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITEDTO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, ORPROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDINGNEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THISSOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Expand Down
2 changes: 1 addition & 1 deletion chama/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

__version__ = '0.1.2'

__copyright__ = """Copyright 2016-2017 National Technology & Engineering
__copyright__ = """Copyright 2016-2019 National Technology & Engineering
Solutions of Sandia, LLC (NTESS). Under the terms of Contract
DE-NA0003525 with NTESS, the U.S. Government retains certain rights
in this software."""
Expand Down
14 changes: 0 additions & 14 deletions ci/requirements-py27-min.yml

This file was deleted.

2 changes: 1 addition & 1 deletion ci/requirements-py34.yml → ci/requirements-py37.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ channels:
- defaults
- https://anaconda.org/conda-forge/pyomo
dependencies:
- python=3.4
- python=3.7
- numpy
- scipy
- pandas
Expand Down
7 changes: 4 additions & 3 deletions documentation/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,12 @@
'sphinx.ext.mathjax',
'sphinx.ext.viewcode',
'sphinx.ext.autosummary',
'numpydoc',
'sphinx.ext.napoleon',
'sphinx.ext.intersphinx',
]

viewcode_import = True
napoleon_use_rtype = False
viewcode_follow_imported_members = True
numpydoc_show_class_members = True
numpydoc_class_members_toctree = False
autodoc_member_order = 'bysource'
Expand All @@ -65,7 +66,7 @@

# General information about the project.
project = u'Chama'
copyright = u'2016-2017 National Technology & Engineering Solutions of Sandia, LLC (NTESS)'
copyright = u'2016-2019, National Technology & Engineering Solutions of Sandia, LLC (NTESS)'
author = u'Sandia National Laboratories'

# The version info for the project you're documenting, acts as replacement for
Expand Down
2 changes: 1 addition & 1 deletion documentation/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ channels:
- conda-forge
- defaults
dependencies:
- python=3.6
- python=3.7
- numpy
- scipy
- pandas
Expand Down
2 changes: 1 addition & 1 deletion documentation/impact.rst
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ pairs containing S1 in the new_scenario DataFrame.

Convert input for the Impact Formulation to the Coverage Formulation
--------------------------------------------------------------------
Users can also convert the input DataFrame for the :ref:`imapctform`
Users can also convert the input DataFrame for the :ref:`impactform`
to the input DataFrame for the :ref:`coverageform`. This is
especially convenient in cases where the user is solving optimization
problems using both solver classes and the DataFrame for the impact
Expand Down
2 changes: 1 addition & 1 deletion documentation/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Installation
======================================

Chama requires Python (2.7, 3.4, 3.5, or 3.6) along with several Python package dependencies.
Chama requires Python (2.7, 3.5, 3.6, or 3.7) along with several Python package dependencies.
Information on installing and using Python can be found at
https://www.python.org/.
Python distributions, such as Anaconda, are recommended to manage the Python interface.
Expand Down
2 changes: 1 addition & 1 deletion documentation/license.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Copyright
------------
.. code-block:: none
Copyright 2016-2017 National Technology & Engineering Solutions of Sandia,
Copyright 2016-2019 National Technology & Engineering Solutions of Sandia,
LLC (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S.
Government retains certain rights in this software.
Expand Down
2 changes: 1 addition & 1 deletion documentation/whatsnew/v0.1.0.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
v0.1.0 (October 9, 2017)
-----------------------
------------------------

This is the first release of Chama. Features include basic functionality to:

Expand Down
5 changes: 3 additions & 2 deletions documentation/whatsnew/v0.1.2.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
v0.1.2 (master)
-----------------------
v0.1.2 (September 27, 2019)
----------------------------

* Added grouping constraints to the Coverage formulation
* Dropped Python 3.4 tests, added Python 3.7 tests
* Updated documentation
2 changes: 1 addition & 1 deletion readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
conda:
file: documentation/environment.yml
python:
version: 2
version: 3.7
setup_py_install: true

0 comments on commit 802b252

Please sign in to comment.