forked from PyPSA/PyPSA
-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/pypsa 13 fork #13
Open
ClaraBuettner
wants to merge
149
commits into
dev
Choose a base branch
from
feature/pypsa_13_fork
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
First argument changed from "csv_folder_name" to "import_name". Whether it is a CSV folder or HDF5 is recognised based on the name.
s_max_pu is the maximum allowed absolute flow per unit of s_nom for the OPF. | flow | \leq s_max_pu * s_nom For lines this can represent an n-1 contingency factor or it can be time-varying to represent weather-dependent dynamic line rating.
Also add sub-network description so that components.csv renders on github.
Because for MILP problems under certain circumstances CPLEX records the "Lower bound" as the relaxed value. "Upper bound" is correctly recorded as the integer objective value. See Issue PyPSA#20.
pandas 0.21.0 changes sum() behavior so that the result of applying sum over an empty DataFrame is NaN. See pandas-dev/pandas#9422 for context. The work-around introduces a zsum function on pd.Series, which returns 0 on an empty Series. Fixes PyPSA#26.
pandas 0.21.0 deprecated reindex_axis.
Pandas 0.21.0 changed the sum of the empty series to nan.
Hyperlinked release notes can be found here: https://pypsa.org/doc/release_notes.html#pypsa-0-12-0-30th-november-2017 This release contains new features and bug fixes. * Support for Pyomo’s persistent solver interface, so if you’re making small changes to an optimisation model (e.g. tweaking a parameter), you don’t have to rebuild the model every time. To enable this, network_lopf has been internally split into build_model, prepare_solver and solve to allow more fine-grained control of the solving steps. Currently the new Pyomo PersistentSolver interface is not in the main Pyomo branch, see the pull request; you can obtain it with pip install git+https://github.com/Pyomo/pyomo@persistent_interfaces * Lines and transformers (i.e. passive branches) have a new attribute s_max_pu to restrict the flow in the OPF, just like p_max_pu for generators and links. It works by restricting the absolute value of the flow per unit of the nominal rating abs(flow) <= s_max_pu*s_nom. For lines this can represent an n-1 contingency factor or it can be time-varying to represent weather-dependent dynamic line rating. * The marginal_cost attribute of generators, storage units, stores and links can now be time dependent. * When initialising the Network object, i.e. network = pypsa.Network(), the first keyword argument is now import_name instead of csv_folder_name. With import_name PyPSA recognises whether it is a CSV folder or an HDF5 file based on the file name ending and deals with it appropriately. Example usage: nw1 = pypsa.Network("my_store.h5") and nw2 = pypsa.Network("/my/folder"). The keyword argument csv_folder_name is still there but is deprecated. * The value network.objective is now read from the Pyomo results attribute Upper Bound instead of Lower Bound. This is because for MILP problems under certain circumstances CPLEX records the Lower bound as the relaxed value. Upper bound is correctly recorded as the integer objective value. * Bug fix due to changes in pandas 0.21.0: A bug affecting various places in the code, including causing network.lopf to fail with GLPK, is fixed. This is because in pandas 0.21.0 the sum of an empty Series/DataFrame returns NaN, whereas before it returned zero. This is a subtle bug; we hope we’ve fixed all instances of it, but get in touch if you notice NaNs creeping in where they shouldn’t be. All our tests run fine. * Bug fix due to changes in scipy 2.0.0: For the new version of scipy, csgraph has to be imported explicit. * Bug fix: A bug whereby logging level was not always correctly being seen by the OPF results printout is fixed. * Bug fix: The storage unit spillage had a bug in the LOPF, whereby it was not respecting network.snapshot_weightings properly. We thank René Garcia Rosas, João Gorenstein Dedecca, Marko Kolenc, Matteo De Felice and Florian Kühnlenz for promptly notifying us about issues.
Also fix release notes bug from scipy 2.0.0 to 1.0.0.
The support for freeing the pyomo datastructures during pyomos solving phase was removed from pypsa in commit #5ac1325, since it proved to be too slow for productive use.
- Includes conda requirements files - Loosely based on calliope from https://github.com/calliope-project/calliope
Also fix typo in README.rst
Raise an error, if any types are missing.
Worksaround the terminal problems conda is having with travis. See also: conda/conda#6468
It says "pip install -U pandas" instead of "... pypsa"
Corrected an error in "Upgrading PyPSA"
Fix pandas deprecation warnings
Especially useful for using the lengths as weight, since the length is not defined for transformers.
The constant factor 1e5 improves the numerical stability of the interior point algorithm.
It is called after solving and results are extracted. It can be used to get the values of shadow prices for constraints not normally extracted.
…ble customization of strategies
unicode is not the same as str in Python 2.7
Also add other examples to website examples list.
For features that are unlikely to be developed in PyPSA directly, we have linked to comparable software with this functionality. Scare warning about heavy development has been removed.
…egenerators p_nom_max has special treatment, in that if it is set to np.min, p_nom_max is divided by the weighting first.
Hyperlinked release notes can be found here: https://pypsa.org/doc/release_notes.html#pypsa-0-13-2-10th-january-2019 This minor release contains small new features and fixes. * Optimisation now works with Pyomo >= 5.6 (there was a Pyomo update that affected the opt.py LConstraint object). * New functional argument can be passed to Network.lopf: extra_postprocessing(network,snapshots,duals), which is called after solving and results are extracted. It can be used to get the values of shadow prices for constraints that are not normally extracted by PyPSA. * In the lopf kirchhoff formulation, the cycle constraint is rescaled by a factor 1e5, which improves the numerical stability of the interior point algorithm (since the coefficients in the constraint matrix were very small). * Updates and fixes to networkclustering, io, plot. We thank Soner Candas of TUM for reporting the problem with the most recent version of Pyomo and providing the fix.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.