Skip to content

Commit 59876cc

Browse files
committed
Merge branch 'release_branch'
2 parents b363c63 + 08204a3 commit 59876cc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+6946
-1030
lines changed

.coveragerc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[run]
2+
omit = tests/*
3+
source = windpowerlib

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
1-
Contributor Agreement
1+
Fixes # .
2+
3+
Changes proposed in this pull request:
4+
-
5+
-
6+
-
7+

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ pip-delete-this-directory.txt
3636

3737
# Doc
3838
doc/temp/
39+
.doctrees
40+
.buildinfo
3941

4042
# Unit test / coverage reports
4143
htmlcov/
@@ -91,3 +93,6 @@ ENV/
9193

9294
# Rope project settings
9395
.ropeproject
96+
97+
# tests
98+
.pytest_cache

.travis.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
language: python
2+
3+
matrix:
4+
include:
5+
- python: 3.5
6+
- python: 3.6
7+
- python: 3.7
8+
dist: xenial
9+
sudo: true
10+
11+
# command to install dependencies
12+
#before_install:
13+
# - sudo apt-get install coinor-cbc
14+
15+
install:
16+
- pip install .
17+
- pip install coveralls sphinx nbformat pytest-cov jupyter
18+
19+
# command to run tests
20+
script:
21+
- coverage run --rcfile=.coveragerc --source windpowerlib -m py.test
22+
- coverage report
23+
24+
after_success:
25+
- coveralls

README.rst

Lines changed: 54 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,13 @@
1+
.. image:: https://travis-ci.org/wind-python/windpowerlib.svg?branch=dev
2+
:target: https://travis-ci.org/wind-python/windpowerlib
3+
.. image:: https://coveralls.io/repos/github/wind-python/windpowerlib/badge.svg?branch=dev
4+
:target: https://coveralls.io/github/wind-python/windpowerlib?branch=dev
5+
16
Introduction
27
=============
38

49
The windpowerlib is a library that provides a set of functions and classes to calculate the power output of wind turbines. It was originally part of the
5-
`feedinlib <https://github.com/oemof/feedinlib>`_ (windpower and pv) but was taken out to build up a community concentrating on wind power models.
10+
`feedinlib <https://github.com/oemof/feedinlib>`_ (windpower and photovoltaic) but was taken out to build up a community concentrating on wind power models.
611

712
For a quick start see the `Examples and basic usage <http://windpowerlib.readthedocs.io/en/stable/getting_started.html#examplereference-label>`_ section.
813

@@ -19,14 +24,16 @@ Go to the `download page <http://readthedocs.org/projects/windpowerlib/downloads
1924
Installation
2025
============
2126

22-
If you have a working Python3 environment, use pypi to install the latest windpowerlib version.
27+
If you have a working Python 3 environment, use pypi to install the latest windpowerlib version. We highly recommend to use virtual environments.
2328

2429
::
2530

26-
pip3 install windpowerlib
31+
pip install windpowerlib
32+
33+
The windpowerlib is designed for Python 3 and tested on Python >= 3.5.
34+
Please see the `installation page <http://oemof.readthedocs.io/en/stable/installation_and_setup.html>`_ of the oemof documentation for complete instructions on how to install python and a virtual environment on your operating system.
2735

28-
So far, the windpowerlib is mainly tested on python 3.4 but seems to work down to 2.7.
29-
Please see the `installation page <http://oemof.readthedocs.io/en/stable/installation_and_setup.html>`_ of the oemof documentation for complete instructions on how to install python on your operating system.
36+
For retrieving power (coefficient) curves from the OpenEnergy Database (oedb) the python package requests will be installed with your windpowerlib installation. The windpowerlib was tested with requests version 2.20.1 but might work with lower versions.
3037

3138
Optional Packages
3239
~~~~~~~~~~~~~~~~~
@@ -40,27 +47,62 @@ Matplotlib can be installed using pip3 though some Linux users reported that it
4047
Examples and basic usage
4148
=========================
4249

43-
The basic usage of the windpowerlib is shown `here <http://windpowerlib.readthedocs.io/en/stable/basic_example_notebook.html>`_. The presented example is available as jupyter notebook and python script. You can download them along with example weather data:
50+
The basic usage of the windpowerlib is shown in the `modelchain_example <http://windpowerlib.readthedocs.io/en/stable/modelchain_example_notebook.html>`_. The presented example is available as jupyter notebook and python script. You can download them along with example weather data:
4451

45-
* `Python script <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/basic_example.py>`_
46-
* `Jupyter notebook <https://raw.githubusercontent.com/wind-python/windpowerlib/features/revise_example/example/basic_example.ipynb>`_
52+
* `ModelChain example (Python script) <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/modelchain_example.py>`_
53+
* `ModelChain example (Jupyter notebook) <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/modelchain_example.ipynb>`_
4754
* `Example data file <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/weather.csv>`_
4855

49-
5056
To run the examples you first have to install the windpowerlib. To run the notebook you also need to install notebook using pip3. To launch jupyter notebook type ``jupyter notebook`` in terminal.
5157
This will open a browser window. Navigate to the directory containing the notebook to open it. See the jupyter notebook quick start guide for more information on `how to install <http://jupyter-notebook-beginner-guide.readthedocs.io/en/latest/install.html>`_ and
5258
`how to run <http://jupyter-notebook-beginner-guide.readthedocs.io/en/latest/execute.html>`_ jupyter notebooks.
5359

60+
Further functionalities, like the modelling of wind farms and wind turbine clusters, are shown in the `turbine_cluster_modelchain_example <http://windpowerlib.readthedocs.io/en/stable/turbine_cluster_modelchain_example_notebook.html>`_. As the ModelChain example it is available as jupyter notebook and as python script. The weather data in this example is the same as in the example above.
61+
62+
* `TurbineClusterModelChain example (Python script) <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/turbine_cluster_modelchain_example.py>`_
63+
* `TurbineClusterModelChain example (Jupyter notebook) <https://raw.githubusercontent.com/wind-python/windpowerlib/master/example/turbine_cluster_modelchain_example.ipynb>`_
5464

5565
Contributing
5666
==============
5767

58-
Clone/Fork: https://github.com/wind-python/windpowerlib
68+
We are warmly welcoming all who want to contribute to the windpowerlib. If you are interested in wind models and want to help improving the existing model do not hesitate to contact us via github or email (windpowerlib@rl-institut.de).
5969

60-
If you are interested in wind models and want to help improve the existing model do not hesitate to contact us.
61-
As the windpowerlib started with contributors from the `oemof developer group <https://github.com/orgs/oemof/teams/oemof-developer-group>`_ we use the same
70+
Clone: https://github.com/wind-python/windpowerlib and install the cloned repository using pip:
71+
72+
.. code:: bash
73+
74+
pip install -e /path/to/the/repository
75+
76+
As the windpowerlib started with contributors from the `oemof developer group <https://github.com/orgs/oemof/teams/oemof-developer-group>`_ we use the same
6277
`developer rules <http://oemof.readthedocs.io/en/stable/developing_oemof.html>`_.
6378

79+
**How to create a pull request:**
80+
81+
* `Fork <https://help.github.com/articles/fork-a-repo>`_ the windpowerlib repository to your own github account.
82+
* Change, add or remove code.
83+
* Commit your changes.
84+
* Create a `pull request <https://guides.github.com/activities/hello-world/>`_ and describe what you will do and why.
85+
* Wait for approval.
86+
87+
**Generally the following steps are required when changing, adding or removing code:**
88+
89+
* Add new tests if you have written new functions/classes.
90+
* Add/change the documentation (new feature, API changes ...).
91+
* Add a whatsnew entry and your name to Contributors.
92+
* Check if all tests still work by simply executing pytest in your windpowerlib directory:
93+
94+
.. role:: bash(code)
95+
:language: bash
96+
97+
.. code:: bash
98+
99+
pytest
100+
101+
102+
Citing the windpowerlib
103+
========================
104+
105+
We use the zenodo project to get a DOI for each version. `Search zenodo for the right citation of your windpowerlib version <https://zenodo.org/search?page=1&size=20&q=windpowerlib>`_.
64106

65107
License
66108
============

0 commit comments

Comments
 (0)