From 5f08dca2fd47c737c0eca2f8ce289e136f0244b1 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Sat, 10 Sep 2022 15:31:43 +0200 Subject: [PATCH 1/5] prepare release 0.6.0 --- CITATION.cff | 2 +- config.20220727.yaml | 371 ++++++++++++++++++++++++++++++++++++ config.default.yaml | 2 +- config.tutorial.yaml | 2 +- doc/conf.py | 4 +- doc/release_notes.rst | 24 ++- envs/environment.fixed.yaml | 150 ++++++++++++--- envs/environment.yaml | 12 +- test/config.test1.yaml | 2 +- 9 files changed, 529 insertions(+), 40 deletions(-) create mode 100755 config.20220727.yaml diff --git a/CITATION.cff b/CITATION.cff index 089c924f5..e54f14caf 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -6,7 +6,7 @@ cff-version: 1.1.0 message: "If you use this package, please cite the corresponding manuscript in Energy Strategy Reviews." title: "PyPSA-Eur: An open optimisation model of the European transmission system" repository: https://github.com/pypsa/pypsa-eur -version: 0.5.0 +version: 0.6.0 license: MIT journal: Energy Strategy Reviews doi: 10.1016/j.esr.2018.08.012 diff --git a/config.20220727.yaml b/config.20220727.yaml new file mode 100755 index 000000000..61621153c --- /dev/null +++ b/config.20220727.yaml @@ -0,0 +1,371 @@ +# SPDX-FileCopyrightText: : 2017-2020 The PyPSA-Eur Authors +# +# SPDX-License-Identifier: CC0-1.0 + +version: 0.4.0 +tutorial: false + +logging: + level: INFO + format: '%(levelname)s:%(name)s:%(message)s' + +scenario: + simpl: [''] + ll: ['copt'] + clusters: [37, 128, 256, 512, 1024] + opts: [Co2L-3H] + +countries: ['AL', 'AT', 'BA', 'BE', 'BG', 'CH', 'CZ', 'DE', 'DK', 'EE', 'ES', 'FI', 'FR', 'GB', 'GR', 'HR', 'HU', 'IE', 'IT', 'LT', 'LU', 'LV', 'ME', 'MK', 'NL', 'NO', 'PL', 'PT', 'RO', 'RS', 'SE', 'SI', 'SK'] + +snapshots: + start: "2013-01-01" + end: "2014-01-01" + closed: 'left' # end is not inclusive + +enable: + prepare_links_p_nom: false + retrieve_databundle: true + retrieve_cost_data: true + build_cutout: false + retrieve_cutout: true + build_natura_raster: false + retrieve_natura_raster: true + custom_busmap: false + +electricity: + voltages: [220., 300., 380.] + gaslimit: false # global gas usage limit of X MWh_th + co2limit: 7.75e+7 # 0.05 * 3.1e9*0.5 + co2base: 1.487e+9 + agg_p_nom_limits: data/agg_p_nom_minmax.csv + + operational_reserve: # like https://genxproject.github.io/GenX/dev/core/#Reserves + activate: false + epsilon_load: 0.02 # share of total load + epsilon_vres: 0.02 # share of total renewable supply + contingency: 4000 # fixed capacity in MW + + max_hours: + battery: 6 + H2: 168 + + extendable_carriers: + Generator: [solar, onwind, offwind-ac, offwind-dc, OCGT] + StorageUnit: [] # battery, H2 + Store: [battery, H2] + Link: [] # H2 pipeline + + # use pandas query strings here, e.g. Country not in ['Germany'] + powerplants_filter: (DateOut >= 2022 or DateOut != DateOut) + # use pandas query strings here, e.g. Country in ['Germany'] + custom_powerplants: false + + conventional_carriers: [nuclear, oil, OCGT, CCGT, coal, lignite, geothermal, biomass] + renewable_carriers: [solar, onwind, offwind-ac, offwind-dc, hydro] + + estimate_renewable_capacities: + enable: true + # Add capacities from OPSD data + from_opsd: true + # Renewable capacities are based on existing capacities reported by IRENA + year: 2020 + # Artificially limit maximum capacities to factor * (IRENA capacities), + # i.e. 110% of 's capacities => expansion_limit: 1.1 + # false: Use estimated renewable potentials determine by the workflow + expansion_limit: false + technology_mapping: + # Wind is the Fueltype in powerplantmatching, onwind, offwind-{ac,dc} the carrier in PyPSA-Eur + Offshore: [offwind-ac, offwind-dc] + Onshore: [onwind] + PV: [solar] + +atlite: + nprocesses: 4 + cutouts: + # use 'base' to determine geographical bounds and time span from config + # base: + # module: era5 + europe-2013-era5: + module: era5 # in priority order + x: [-12., 35.] + y: [33., 72] + dx: 0.3 + dy: 0.3 + time: ['2013', '2013'] + europe-2013-sarah: + module: [sarah, era5] # in priority order + x: [-12., 45.] + y: [33., 65] + dx: 0.2 + dy: 0.2 + time: ['2013', '2013'] + sarah_interpolate: false + sarah_dir: + features: [influx, temperature] + + +renewable: + onwind: + cutout: europe-2013-era5 + resource: + method: wind + turbine: Vestas_V112_3MW + capacity_per_sqkm: 3 # ScholzPhd Tab 4.3.1: 10MW/km^2 + # correction_factor: 0.93 + corine: + # Scholz, Y. (2012). Renewable energy based electricity supply at low costs: + # development of the REMix model and application for Europe. ( p.42 / p.28) + grid_codes: [12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, + 24, 25, 26, 27, 28, 29, 31, 32] + distance: 1000 + distance_grid_codes: [1, 2, 3, 4, 5, 6] + natura: true + potential: simple # or conservative + clip_p_max_pu: 1.e-2 + offwind-ac: + cutout: europe-2013-era5 + resource: + method: wind + turbine: NREL_ReferenceTurbine_5MW_offshore + capacity_per_sqkm: 2 + correction_factor: 0.8855 + # proxy for wake losses + # from 10.1016/j.energy.2018.08.153 + # until done more rigorously in #153 + corine: [44, 255] + natura: true + max_depth: 50 + max_shore_distance: 30000 + potential: simple # or conservative + clip_p_max_pu: 1.e-2 + offwind-dc: + cutout: europe-2013-era5 + resource: + method: wind + turbine: NREL_ReferenceTurbine_5MW_offshore + # ScholzPhd Tab 4.3.1: 10MW/km^2 + capacity_per_sqkm: 2 + correction_factor: 0.8855 + # proxy for wake losses + # from 10.1016/j.energy.2018.08.153 + # until done more rigorously in #153 + corine: [44, 255] + natura: true + max_depth: 50 + min_shore_distance: 30000 + potential: simple # or conservative + clip_p_max_pu: 1.e-2 + solar: + cutout: europe-2013-sarah + resource: + method: pv + panel: CSi + orientation: + slope: 35. + azimuth: 180. + capacity_per_sqkm: 1.7 # ScholzPhd Tab 4.3.1: 170 MW/km^2 + # Correction factor determined by comparing uncorrected area-weighted full-load hours to those + # published in Supplementary Data to + # Pietzcker, Robert Carl, et al. "Using the sun to decarbonize the power + # sector: The economic potential of photovoltaics and concentrating solar + # power." Applied Energy 135 (2014): 704-720. + # This correction factor of 0.854337 may be in order if using reanalysis data. + # for discussion refer to https://github.com/PyPSA/pypsa-eur/pull/304 + # correction_factor: 0.854337 + corine: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, + 14, 15, 16, 17, 18, 19, 20, 26, 31, 32] + natura: true + potential: simple # or conservative + clip_p_max_pu: 1.e-2 + hydro: + cutout: europe-2013-era5 + carriers: [ror, PHS, hydro] + PHS_max_hours: 6 + hydro_max_hours: "energy_capacity_totals_by_country" # one of energy_capacity_totals_by_country, estimate_by_large_installations or a float + clip_min_inflow: 1.0 + +conventional: + nuclear: + p_max_pu: "data/nuclear_p_max_pu.csv" # float of file name + +lines: + types: + 220.: "Al/St 240/40 2-bundle 220.0" + 300.: "Al/St 240/40 3-bundle 300.0" + 380.: "Al/St 240/40 4-bundle 380.0" + s_max_pu: 0.7 + s_nom_max: .inf + length_factor: 1.25 + under_construction: 'zero' # 'zero': set capacity to zero, 'remove': remove, 'keep': with full capacity + +links: + p_max_pu: 1.0 + p_nom_max: .inf + include_tyndp: true + under_construction: 'zero' # 'zero': set capacity to zero, 'remove': remove, 'keep': with full capacity + +transformers: + x: 0.1 + s_nom: 2000. + type: '' + +load: + power_statistics: True # only for files from <2019; set false in order to get ENTSOE transparency data + interpolate_limit: 3 # data gaps up until this size are interpolated linearly + time_shift_for_large_gaps: 1w # data gaps up until this size are copied by copying from + manual_adjustments: true # false + scaling_factor: 1.0 + +costs: + year: 2030 + version: v0.1.0 + rooftop_share: 0.14 # based on the potentials, assuming (0.1 kW/m2 and 10 m2/person) + fill_values: + FOM: 0 + VOM: 0 + efficiency: 1 + fuel: 0 + investment: 0 + lifetime: 25 + "CO2 intensity": 0 + "discount rate": 0.07 + marginal_cost: + solar: 0.01 + onwind: 0.015 + offwind: 0.015 + hydro: 0. + H2: 0. + electrolysis: 0. + fuel cell: 0. + battery: 0. + battery inverter: 0. + emission_prices: # in currency per tonne emission, only used with the option Ep + co2: 0. + +clustering: + simplify_network: + to_substations: false # network is simplified to nodes with positive or negative power injection (i.e. substations or offwind connections) + algorithm: kmeans # choose from: [hac, kmeans] + feature: solar+onwind-time # only for hac. choose from: [solar+onwind-time, solar+onwind-cap, solar-time, solar-cap, solar+offwind-cap] etc. + cluster_network: + algorithm: kmeans + feature: solar+onwind-time + aggregation_strategies: + generators: + p_nom_max: sum # use "min" for more conservative assumptions + p_nom_min: sum + p_min_pu: mean + marginal_cost: mean + committable: any + ramp_limit_up: max + ramp_limit_down: max + efficiency: mean + +solving: + options: + formulation: kirchhoff + load_shedding: false + noisy_costs: true + min_iterations: 4 + max_iterations: 6 + clip_p_max_pu: 0.01 + skip_iterations: false + track_iterations: false + #nhours: 10 + solver: + name: gurobi + threads: 4 + method: 2 # barrier + crossover: 0 + BarConvTol: 1.e-5 + FeasibilityTol: 1.e-6 + AggFill: 0 + PreDual: 0 + GURO_PAR_BARDENSETHRESH: 200 + # solver: + # name: cplex + # threads: 4 + # lpmethod: 4 # barrier + # solutiontype: 2 # non basic solution, ie no crossover + # barrier.convergetol: 1.e-5 + # feasopt.tolerance: 1.e-6 + +plotting: + map: + figsize: [7, 7] + boundaries: [-10.2, 29, 35, 72] + p_nom: + bus_size_factor: 5.e+4 + linewidth_factor: 3.e+3 + + costs_max: 800 + costs_threshold: 1 + + energy_max: 15000. + energy_min: -10000. + energy_threshold: 50. + + vre_techs: ["onwind", "offwind-ac", "offwind-dc", "solar", "ror"] + conv_techs: ["OCGT", "CCGT", "Nuclear", "Coal"] + storage_techs: ["hydro+PHS", "battery", "H2"] + load_carriers: ["AC load"] + AC_carriers: ["AC line", "AC transformer"] + link_carriers: ["DC line", "Converter AC-DC"] + tech_colors: + "onwind" : "#235ebc" + "onshore wind" : "#235ebc" + 'offwind' : "#6895dd" + 'offwind-ac' : "#6895dd" + 'offshore wind' : "#6895dd" + 'offshore wind ac' : "#6895dd" + 'offwind-dc' : "#74c6f2" + 'offshore wind dc' : "#74c6f2" + "hydro" : "#08ad97" + "hydro+PHS" : "#08ad97" + "PHS" : "#08ad97" + "hydro reservoir" : "#08ad97" + 'hydroelectricity' : '#08ad97' + "ror" : "#4adbc8" + "run of river" : "#4adbc8" + 'solar' : "#f9d002" + 'solar PV' : "#f9d002" + 'solar thermal' : '#ffef60' + 'biomass' : '#0c6013' + 'solid biomass' : '#06540d' + 'biogas' : '#23932d' + 'waste' : '#68896b' + 'geothermal' : '#ba91b1' + "OCGT" : "#d35050" + "gas" : "#d35050" + "natural gas" : "#d35050" + "CCGT" : "#b20101" + "nuclear" : "#ff9000" + "coal" : "#707070" + "lignite" : "#9e5a01" + "oil" : "#262626" + "H2" : "#ea048a" + "hydrogen storage" : "#ea048a" + "battery" : "#b8ea04" + "Electric load" : "#f9d002" + "electricity" : "#f9d002" + "lines" : "#70af1d" + "transmission lines" : "#70af1d" + "AC-AC" : "#70af1d" + "AC line" : "#70af1d" + "links" : "#8a1caf" + "HVDC links" : "#8a1caf" + "DC-DC" : "#8a1caf" + "DC link" : "#8a1caf" + nice_names: + OCGT: "Open-Cycle Gas" + CCGT: "Combined-Cycle Gas" + offwind-ac: "Offshore Wind (AC)" + offwind-dc: "Offshore Wind (DC)" + onwind: "Onshore Wind" + solar: "Solar" + PHS: "Pumped Hydro Storage" + hydro: "Reservoir & Dam" + battery: "Battery Storage" + H2: "Hydrogen Storage" + lines: "Transmission Lines" + ror: "Run of River" diff --git a/config.default.yaml b/config.default.yaml index 83f1cfd81..0050a505d 100755 --- a/config.default.yaml +++ b/config.default.yaml @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: CC0-1.0 -version: 0.5.0 +version: 0.6.0 tutorial: false logging: diff --git a/config.tutorial.yaml b/config.tutorial.yaml index ed2f9bf0e..7edbdc27d 100755 --- a/config.tutorial.yaml +++ b/config.tutorial.yaml @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: CC0-1.0 -version: 0.5.0 +version: 0.6.0 tutorial: true logging: diff --git a/doc/conf.py b/doc/conf.py index 2a3398fb2..a09f836ba 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -74,9 +74,9 @@ # built documents. # # The short X.Y version. -version = u'0.3' +version = u'0.6' # The full version, including alpha/beta/rc tags. -release = u'0.4.0' +release = u'0.6.0' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/doc/release_notes.rst b/doc/release_notes.rst index dcf423558..db1068648 100644 --- a/doc/release_notes.rst +++ b/doc/release_notes.rst @@ -10,9 +10,29 @@ Release Notes Upcoming Release ================ -* Add functionality to consider shipping routes when calculating the available area for offshore technologies. Data for the shipping density comes from the `Global Shipping Traffic Density dataset ` +* new feature + + +PyPSA-Eur 0.6.0 (10th September 2022) +===================================== + +* Functionality to consider shipping routes when calculating the available area + for offshore technologies were added. Data for the shipping density comes from + the `Global Shipping Traffic Density dataset + `_. + +* When transforming all transmission lines to a unified voltage level of 380kV, + the workflow now preserves the transmission capacity rather than electrical + impedance and reactance. + +* Memory resources are now specified for all rules. + +* Filtering of power plant data was adjusted to new versions of + ``powerplantmatching``. + +* The resolution of land exclusion calculation is now a configurable option. See + setting ``excluder_resolution``. -* When fixing line voltages to 380kV, the workflow now preserves the transmission capacity instead of the electrical impedance and reactance. PyPSA-Eur 0.5.0 (27th July 2022) ===================================== diff --git a/envs/environment.fixed.yaml b/envs/environment.fixed.yaml index ee6a5035c..cde31ba26 100644 --- a/envs/environment.fixed.yaml +++ b/envs/environment.fixed.yaml @@ -1,7 +1,3 @@ -# SPDX-FileCopyrightText: : 2017-2022 The PyPSA-Eur Authors -# -# SPDX-License-Identifier: CC0-1.0 - name: pypsa-eur channels: - bioconda @@ -11,17 +7,33 @@ channels: dependencies: - _libgcc_mutex=0.1 - _openmp_mutex=4.5 + - abseil-cpp=20210324.2 - affine=2.3.1 - alsa-lib=1.2.3.2 + - altair=4.2.0 + - ampl-mp=3.1.0 - amply=0.1.5 + - anyio=3.6.1 - appdirs=1.4.4 + - argon2-cffi=21.3.0 + - argon2-cffi-bindings=21.2.0 + - arrow-cpp=8.0.0 - asttokens=2.0.5 - - atlite=0.2.7 + - atlite=0.2.9 - attrs=21.4.0 + - aws-c-cal=0.5.11 + - aws-c-common=0.6.2 + - aws-c-event-stream=0.2.7 + - aws-c-io=0.10.5 + - aws-checksums=0.1.11 + - aws-sdk-cpp=1.8.186 + - babel=2.10.3 - backcall=0.2.0 - backports=1.0 - backports.functools_lru_cache=1.6.4 - beautifulsoup4=4.11.1 + - bleach=5.0.1 + - blinker=1.4 - blosc=1.21.1 - bokeh=2.4.3 - boost-cpp=1.74.0 @@ -32,16 +44,17 @@ dependencies: - brotlipy=0.7.0 - bzip2=1.0.8 - c-ares=1.18.1 - - ca-certificates=2022.6.15 + - ca-certificates=2022.6.15.1 + - cachetools=5.0.0 - cairo=1.16.0 - cartopy=0.20.1 - cdsapi=0.5.1 - - certifi=2022.6.15 + - certifi=2022.6.15.1 - cffi=1.15.1 - cfitsio=4.0.0 - cftime=1.6.1 - charset-normalizer=2.1.0 - - click=8.1.3 + - click=8.0.4 - click-plugins=1.1.1 - cligj=0.7.2 - cloudpickle=2.1.0 @@ -52,6 +65,8 @@ dependencies: - coin-or-utils=2.11.6 - coincbc=2.10.8 - colorama=0.4.5 + - colorcet=3.0.0 + - commonmark=0.9.1 - configargparse=1.5.3 - connection_pool=0.0.3 - country_converter=0.7.4 @@ -59,23 +74,28 @@ dependencies: - curl=7.83.1 - cycler=0.11.0 - cytoolz=0.12.0 - - dask=2022.7.1 - - dask-core=2022.7.1 + - dask=2022.7.0 + - dask-core=2022.7.0 + - dataclasses=0.8 - datrie=0.8.2 - dbus=1.13.6 + - debugpy=1.6.0 - decorator=5.1.1 + - defusedxml=0.7.1 - deprecation=2.1.0 - descartes=1.1.0 - - distributed=2022.7.1 + - distributed=2022.7.0 - distro=1.6.0 - docutils=0.19 - dpath=2.0.6 + - entrypoints=0.4 - entsoe-py=0.5.4 - et_xmlfile=1.0.1 - - executing=0.9.1 + - executing=0.8.3 - expat=2.4.8 - filelock=3.7.1 - fiona=1.8.20 + - flit-core=3.7.1 - folium=0.12.1.post1 - font-ttf-dejavu-sans-mono=2.37 - font-ttf-inconsolata=3.000 @@ -88,38 +108,58 @@ dependencies: - freetype=2.10.4 - freexl=1.0.6 - fsspec=2022.5.0 + - future=0.18.2 - gdal=3.3.3 - geographiclib=1.52 - geojson-rewind=1.0.2 - - geopandas=0.11.1 - - geopandas-base=0.11.1 + - geopandas=0.11.0 + - geopandas-base=0.11.0 - geopy=2.2.0 - geos=3.10.0 - geotiff=1.7.0 - gettext=0.19.8.1 + - gflags=2.2.2 - giflib=5.2.1 - gitdb=4.0.9 - gitpython=3.1.27 + - glog=0.6.0 + - glpk=5.0 + - gmp=6.2.1 - graphite2=1.3.13 + - grpc-cpp=1.45.2 - gst-plugins-base=1.18.5 - gstreamer=1.18.5 - harfbuzz=2.9.1 - hdf4=4.2.15 - hdf5=1.12.1 - heapdict=1.0.1 + - holoviews=1.15.0 + - hvplot=0.8.0 - icu=68.2 - idna=3.3 - importlib-metadata=4.11.4 - - importlib_resources=5.9.0 + - importlib_metadata=4.11.4 + - importlib_resources=5.8.0 - iniconfig=1.1.1 + - ipopt=3.14.8 + - ipykernel=6.15.1 - ipython=8.4.0 + - ipython_genutils=0.2.0 + - ipywidgets=7.7.1 - jedi=0.18.1 - jinja2=3.1.2 - joblib=1.1.0 - jpeg=9e - json-c=0.15 + - json5=0.9.5 - jsonschema=4.7.2 - - jupyter_core=4.11.1 + - jupyter_client=7.3.4 + - jupyter_core=4.10.0 + - jupyter_server=1.18.1 + - jupyterlab=3.4.3 + - jupyterlab_pygments=0.2.2 + - jupyterlab_server=2.15.0 + - jupyterlab_widgets=1.1.1 - kealib=1.4.15 - keyutils=1.6.1 - kiwisolver=1.4.4 @@ -133,6 +173,7 @@ dependencies: - libbrotlienc=1.0.9 - libcblas=3.9.0 - libclang=11.1.0 + - libcrc32c=1.1.2 - libcurl=7.83.1 - libdap4=3.20.6 - libdeflate=1.12 @@ -146,6 +187,7 @@ dependencies: - libgfortran5=12.1.0 - libglib=2.72.1 - libgomp=12.1.0 + - libgoogle-cloud=1.40.2 - libiconv=1.16 - libkml=1.3.0 - liblapack=3.9.0 @@ -159,16 +201,20 @@ dependencies: - libopus=1.3.1 - libpng=1.6.37 - libpq=13.5 + - libprotobuf=3.20.1 - librttopo=1.1.0 + - libsodium=1.0.18 - libspatialindex=1.9.3 - libspatialite=5.0.1 - libssh2=1.10.0 - libstdcxx-ng=12.1.0 + - libthrift=0.16.0 - libtiff=4.4.0 + - libutf8proc=2.7.0 - libuuid=2.32.1 - libvorbis=1.3.7 - - libwebp=1.2.3 - - libwebp-base=1.2.3 + - libwebp=1.2.2 + - libwebp-base=1.2.2 - libxcb=1.13 - libxkbcommon=1.0.3 - libxml2=2.9.12 @@ -181,21 +227,34 @@ dependencies: - lz4-c=1.9.3 - lzo=2.10 - mapclassify=2.4.3 + - markdown=3.4.1 - markupsafe=2.1.1 - matplotlib=3.5.2 - matplotlib-base=3.5.2 - matplotlib-inline=0.1.3 - memory_profiler=0.60.0 + - metis=5.1.0 + - mistune=0.8.4 - msgpack-python=1.0.4 + - mumps-include=5.2.1 + - mumps-seq=5.2.1 - munch=2.5.0 - munkres=1.1.4 - mysql-common=8.0.29 - mysql-libs=8.0.29 + - nbclassic=0.4.3 + - nbclient=0.6.6 + - nbconvert=6.5.0 + - nbconvert-core=6.5.0 + - nbconvert-pandoc=6.5.0 - nbformat=5.4.0 - ncurses=6.3 + - nest-asyncio=1.5.5 - netcdf4=1.6.0 - - networkx=2.8.5 + - networkx=2.8.4 - nomkl=1.0 + - notebook=6.4.12 + - notebook-shim=0.1.0 - nspr=4.32 - nss=3.78 - numexpr=2.8.3 @@ -204,8 +263,14 @@ dependencies: - openjpeg=2.4.0 - openpyxl=3.0.9 - openssl=1.1.1q + - orc=1.7.5 - packaging=21.3 - pandas=1.4.3 + - pandoc=2.18 + - pandocfilters=1.5.0 + - panel=0.13.1 + - param=1.12.2 + - parquet-cpp=1.5.1 - parso=0.8.3 - partd=1.2.0 - patsy=0.5.2 @@ -213,27 +278,35 @@ dependencies: - pexpect=4.8.0 - pickleshare=0.7.5 - pillow=9.2.0 - - pip=22.2 + - pip=22.1.2 - pixman=0.40.0 - plac=1.3.5 + - plotly=5.9.0 - pluggy=1.0.0 - ply=3.11 - poppler=21.09.0 - poppler-data=0.4.11 - postgresql=13.5 - - powerplantmatching=0.5.3 + - powerplantmatching=0.5.4 - progressbar2=4.0.0 - proj=8.1.1 + - prometheus_client=0.14.1 - prompt-toolkit=3.0.30 + - protobuf=3.20.1 - psutil=5.9.1 - pthread-stubs=0.4 - ptyprocess=0.7.0 - pulp=2.6.0 - pure_eval=0.2.2 - py=1.11.0 + - pyarrow=8.0.0 - pycountry=20.7.3 - pycparser=2.21 + - pyct=0.4.6 + - pyct-core=0.4.6 + - pydeck=0.7.1 - pygments=2.12.0 + - pympler=0.9 - pyomo=6.4.1 - pyopenssl=22.0.0 - pyparsing=3.0.9 @@ -252,22 +325,32 @@ dependencies: - python=3.9.13 - python-dateutil=2.8.2 - python-fastjsonschema=2.16.1 + - python-tzdata=2022.1 - python-utils=3.3.3 - python_abi=3.9 - pytz=2022.1 + - pytz-deprecation-shim=0.1.0.post0 + - pyviz_comms=2.2.0 - pyxlsb=1.0.9 - pyyaml=6.0 + - pyzmq=23.2.0 - qt=5.12.9 - rasterio=1.2.9 - ratelimiter=1.2.0 + - re2=2022.06.01 - readline=8.1.2 - requests=2.28.1 - retry=0.9.2 + - rich=12.5.1 - rtree=1.0.0 + - s2n=1.0.10 - scikit-learn=1.1.1 - scipy=1.8.1 + - scotch=6.0.9 - seaborn=0.11.2 - seaborn-base=0.11.2 + - semver=2.13.0 + - send2trash=1.8.0 - setuptools=63.2.0 - setuptools-scm=7.0.5 - setuptools_scm=7.0.5 @@ -275,21 +358,27 @@ dependencies: - six=1.16.0 - smart_open=6.0.0 - smmap=3.0.5 - - snakemake-minimal=7.9.0 + - snakemake-minimal=7.8.5 - snappy=1.1.9 + - sniffio=1.2.0 - snuggs=1.4.7 - sortedcontainers=2.4.0 - - soupsieve=2.3.2.post1 - - sqlite=3.39.2 + - soupsieve=2.3.1 + - sqlite=3.39.1 - stack_data=0.3.0 - statsmodels=0.13.2 - stopit=1.1.2 + - streamlit=1.10.0 - tabula-py=2.2.0 - tabulate=0.8.10 - tblib=1.7.0 + - tenacity=8.0.1 + - terminado=0.15.0 - threadpoolctl=3.1.0 - tiledb=2.3.4 + - tinycss2=1.1.1 - tk=8.6.12 + - toml=0.10.2 - tomli=2.0.1 - toolz=0.12.0 - toposort=1.7 @@ -300,13 +389,20 @@ dependencies: - typing_extensions=4.3.0 - tzcode=2022a - tzdata=2022a + - tzlocal=4.2 - unicodedata2=14.0.0 - unidecode=1.3.4 - - urllib3=1.26.11 + - unixodbc=2.3.10 + - urllib3=1.26.10 + - validators=0.18.2 + - watchdog=2.1.9 - wcwidth=0.2.5 + - webencodings=0.5.1 + - websocket-client=1.3.3 - wheel=0.37.1 + - widgetsnbextension=3.6.1 - wrapt=1.14.1 - - xarray=2022.6.0 + - xarray=2022.3.0 - xerces-c=3.2.3 - xlrd=2.0.1 - xorg-fixesproto=5.0 @@ -330,11 +426,13 @@ dependencies: - xz=5.2.5 - yaml=0.2.5 - yte=1.5.1 + - zeromq=4.3.4 - zict=2.2.0 - zipp=3.8.0 - zlib=1.2.12 - zstd=1.5.2 - pip: - countrycode==0.2 + - gurobipy==9.5.2 - tsam==2.1.0 - vresutils==0.3.1 \ No newline at end of file diff --git a/envs/environment.yaml b/envs/environment.yaml index 3330a698e..41fd6c866 100644 --- a/envs/environment.yaml +++ b/envs/environment.yaml @@ -7,11 +7,11 @@ channels: - conda-forge - bioconda dependencies: - - python>=3.8 + - python==3.9 - pip - pypsa>=0.20 - - atlite>=0.2.6 + - atlite>=0.2.9 - dask # Dependencies of the workflow itself @@ -24,7 +24,7 @@ dependencies: - yaml - pytables - lxml - - powerplantmatching>=0.5.3 + - powerplantmatching>=0.5.4 - numpy - pandas - geopandas>=0.11.0 @@ -32,19 +32,19 @@ dependencies: - netcdf4 - networkx - scipy - - shapely + - shapely<2.0 # need to address deprecations - progressbar2 - pyomo - matplotlib - proj - - fiona <= 1.18.20 # Till issue https://github.com/Toblerity/Fiona/issues/1085 is not solved + - fiona # <= 1.18.20 # Till issue https://github.com/Toblerity/Fiona/issues/1085 is not solved - country_converter # Keep in conda environment when calling ipython - ipython # GIS dependencies: - - cartopy + - cartopy>=0.16 - descartes - rasterio<=1.2.9 # 1.2.10 creates error https://github.com/PyPSA/atlite/issues/238 diff --git a/test/config.test1.yaml b/test/config.test1.yaml index 2f25b6eb6..abb417233 100755 --- a/test/config.test1.yaml +++ b/test/config.test1.yaml @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: CC0-1.0 -version: 0.5.0 +version: 0.6.0 tutorial: true logging: level: INFO From 4799b411f8527a0591854374018d933b237ab2a6 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Sat, 10 Sep 2022 15:32:26 +0200 Subject: [PATCH 2/5] remove accidental config file additions --- config.20220727.yaml | 371 ------------------------------------------- 1 file changed, 371 deletions(-) delete mode 100755 config.20220727.yaml diff --git a/config.20220727.yaml b/config.20220727.yaml deleted file mode 100755 index 61621153c..000000000 --- a/config.20220727.yaml +++ /dev/null @@ -1,371 +0,0 @@ -# SPDX-FileCopyrightText: : 2017-2020 The PyPSA-Eur Authors -# -# SPDX-License-Identifier: CC0-1.0 - -version: 0.4.0 -tutorial: false - -logging: - level: INFO - format: '%(levelname)s:%(name)s:%(message)s' - -scenario: - simpl: [''] - ll: ['copt'] - clusters: [37, 128, 256, 512, 1024] - opts: [Co2L-3H] - -countries: ['AL', 'AT', 'BA', 'BE', 'BG', 'CH', 'CZ', 'DE', 'DK', 'EE', 'ES', 'FI', 'FR', 'GB', 'GR', 'HR', 'HU', 'IE', 'IT', 'LT', 'LU', 'LV', 'ME', 'MK', 'NL', 'NO', 'PL', 'PT', 'RO', 'RS', 'SE', 'SI', 'SK'] - -snapshots: - start: "2013-01-01" - end: "2014-01-01" - closed: 'left' # end is not inclusive - -enable: - prepare_links_p_nom: false - retrieve_databundle: true - retrieve_cost_data: true - build_cutout: false - retrieve_cutout: true - build_natura_raster: false - retrieve_natura_raster: true - custom_busmap: false - -electricity: - voltages: [220., 300., 380.] - gaslimit: false # global gas usage limit of X MWh_th - co2limit: 7.75e+7 # 0.05 * 3.1e9*0.5 - co2base: 1.487e+9 - agg_p_nom_limits: data/agg_p_nom_minmax.csv - - operational_reserve: # like https://genxproject.github.io/GenX/dev/core/#Reserves - activate: false - epsilon_load: 0.02 # share of total load - epsilon_vres: 0.02 # share of total renewable supply - contingency: 4000 # fixed capacity in MW - - max_hours: - battery: 6 - H2: 168 - - extendable_carriers: - Generator: [solar, onwind, offwind-ac, offwind-dc, OCGT] - StorageUnit: [] # battery, H2 - Store: [battery, H2] - Link: [] # H2 pipeline - - # use pandas query strings here, e.g. Country not in ['Germany'] - powerplants_filter: (DateOut >= 2022 or DateOut != DateOut) - # use pandas query strings here, e.g. Country in ['Germany'] - custom_powerplants: false - - conventional_carriers: [nuclear, oil, OCGT, CCGT, coal, lignite, geothermal, biomass] - renewable_carriers: [solar, onwind, offwind-ac, offwind-dc, hydro] - - estimate_renewable_capacities: - enable: true - # Add capacities from OPSD data - from_opsd: true - # Renewable capacities are based on existing capacities reported by IRENA - year: 2020 - # Artificially limit maximum capacities to factor * (IRENA capacities), - # i.e. 110% of 's capacities => expansion_limit: 1.1 - # false: Use estimated renewable potentials determine by the workflow - expansion_limit: false - technology_mapping: - # Wind is the Fueltype in powerplantmatching, onwind, offwind-{ac,dc} the carrier in PyPSA-Eur - Offshore: [offwind-ac, offwind-dc] - Onshore: [onwind] - PV: [solar] - -atlite: - nprocesses: 4 - cutouts: - # use 'base' to determine geographical bounds and time span from config - # base: - # module: era5 - europe-2013-era5: - module: era5 # in priority order - x: [-12., 35.] - y: [33., 72] - dx: 0.3 - dy: 0.3 - time: ['2013', '2013'] - europe-2013-sarah: - module: [sarah, era5] # in priority order - x: [-12., 45.] - y: [33., 65] - dx: 0.2 - dy: 0.2 - time: ['2013', '2013'] - sarah_interpolate: false - sarah_dir: - features: [influx, temperature] - - -renewable: - onwind: - cutout: europe-2013-era5 - resource: - method: wind - turbine: Vestas_V112_3MW - capacity_per_sqkm: 3 # ScholzPhd Tab 4.3.1: 10MW/km^2 - # correction_factor: 0.93 - corine: - # Scholz, Y. (2012). Renewable energy based electricity supply at low costs: - # development of the REMix model and application for Europe. ( p.42 / p.28) - grid_codes: [12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 31, 32] - distance: 1000 - distance_grid_codes: [1, 2, 3, 4, 5, 6] - natura: true - potential: simple # or conservative - clip_p_max_pu: 1.e-2 - offwind-ac: - cutout: europe-2013-era5 - resource: - method: wind - turbine: NREL_ReferenceTurbine_5MW_offshore - capacity_per_sqkm: 2 - correction_factor: 0.8855 - # proxy for wake losses - # from 10.1016/j.energy.2018.08.153 - # until done more rigorously in #153 - corine: [44, 255] - natura: true - max_depth: 50 - max_shore_distance: 30000 - potential: simple # or conservative - clip_p_max_pu: 1.e-2 - offwind-dc: - cutout: europe-2013-era5 - resource: - method: wind - turbine: NREL_ReferenceTurbine_5MW_offshore - # ScholzPhd Tab 4.3.1: 10MW/km^2 - capacity_per_sqkm: 2 - correction_factor: 0.8855 - # proxy for wake losses - # from 10.1016/j.energy.2018.08.153 - # until done more rigorously in #153 - corine: [44, 255] - natura: true - max_depth: 50 - min_shore_distance: 30000 - potential: simple # or conservative - clip_p_max_pu: 1.e-2 - solar: - cutout: europe-2013-sarah - resource: - method: pv - panel: CSi - orientation: - slope: 35. - azimuth: 180. - capacity_per_sqkm: 1.7 # ScholzPhd Tab 4.3.1: 170 MW/km^2 - # Correction factor determined by comparing uncorrected area-weighted full-load hours to those - # published in Supplementary Data to - # Pietzcker, Robert Carl, et al. "Using the sun to decarbonize the power - # sector: The economic potential of photovoltaics and concentrating solar - # power." Applied Energy 135 (2014): 704-720. - # This correction factor of 0.854337 may be in order if using reanalysis data. - # for discussion refer to https://github.com/PyPSA/pypsa-eur/pull/304 - # correction_factor: 0.854337 - corine: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, - 14, 15, 16, 17, 18, 19, 20, 26, 31, 32] - natura: true - potential: simple # or conservative - clip_p_max_pu: 1.e-2 - hydro: - cutout: europe-2013-era5 - carriers: [ror, PHS, hydro] - PHS_max_hours: 6 - hydro_max_hours: "energy_capacity_totals_by_country" # one of energy_capacity_totals_by_country, estimate_by_large_installations or a float - clip_min_inflow: 1.0 - -conventional: - nuclear: - p_max_pu: "data/nuclear_p_max_pu.csv" # float of file name - -lines: - types: - 220.: "Al/St 240/40 2-bundle 220.0" - 300.: "Al/St 240/40 3-bundle 300.0" - 380.: "Al/St 240/40 4-bundle 380.0" - s_max_pu: 0.7 - s_nom_max: .inf - length_factor: 1.25 - under_construction: 'zero' # 'zero': set capacity to zero, 'remove': remove, 'keep': with full capacity - -links: - p_max_pu: 1.0 - p_nom_max: .inf - include_tyndp: true - under_construction: 'zero' # 'zero': set capacity to zero, 'remove': remove, 'keep': with full capacity - -transformers: - x: 0.1 - s_nom: 2000. - type: '' - -load: - power_statistics: True # only for files from <2019; set false in order to get ENTSOE transparency data - interpolate_limit: 3 # data gaps up until this size are interpolated linearly - time_shift_for_large_gaps: 1w # data gaps up until this size are copied by copying from - manual_adjustments: true # false - scaling_factor: 1.0 - -costs: - year: 2030 - version: v0.1.0 - rooftop_share: 0.14 # based on the potentials, assuming (0.1 kW/m2 and 10 m2/person) - fill_values: - FOM: 0 - VOM: 0 - efficiency: 1 - fuel: 0 - investment: 0 - lifetime: 25 - "CO2 intensity": 0 - "discount rate": 0.07 - marginal_cost: - solar: 0.01 - onwind: 0.015 - offwind: 0.015 - hydro: 0. - H2: 0. - electrolysis: 0. - fuel cell: 0. - battery: 0. - battery inverter: 0. - emission_prices: # in currency per tonne emission, only used with the option Ep - co2: 0. - -clustering: - simplify_network: - to_substations: false # network is simplified to nodes with positive or negative power injection (i.e. substations or offwind connections) - algorithm: kmeans # choose from: [hac, kmeans] - feature: solar+onwind-time # only for hac. choose from: [solar+onwind-time, solar+onwind-cap, solar-time, solar-cap, solar+offwind-cap] etc. - cluster_network: - algorithm: kmeans - feature: solar+onwind-time - aggregation_strategies: - generators: - p_nom_max: sum # use "min" for more conservative assumptions - p_nom_min: sum - p_min_pu: mean - marginal_cost: mean - committable: any - ramp_limit_up: max - ramp_limit_down: max - efficiency: mean - -solving: - options: - formulation: kirchhoff - load_shedding: false - noisy_costs: true - min_iterations: 4 - max_iterations: 6 - clip_p_max_pu: 0.01 - skip_iterations: false - track_iterations: false - #nhours: 10 - solver: - name: gurobi - threads: 4 - method: 2 # barrier - crossover: 0 - BarConvTol: 1.e-5 - FeasibilityTol: 1.e-6 - AggFill: 0 - PreDual: 0 - GURO_PAR_BARDENSETHRESH: 200 - # solver: - # name: cplex - # threads: 4 - # lpmethod: 4 # barrier - # solutiontype: 2 # non basic solution, ie no crossover - # barrier.convergetol: 1.e-5 - # feasopt.tolerance: 1.e-6 - -plotting: - map: - figsize: [7, 7] - boundaries: [-10.2, 29, 35, 72] - p_nom: - bus_size_factor: 5.e+4 - linewidth_factor: 3.e+3 - - costs_max: 800 - costs_threshold: 1 - - energy_max: 15000. - energy_min: -10000. - energy_threshold: 50. - - vre_techs: ["onwind", "offwind-ac", "offwind-dc", "solar", "ror"] - conv_techs: ["OCGT", "CCGT", "Nuclear", "Coal"] - storage_techs: ["hydro+PHS", "battery", "H2"] - load_carriers: ["AC load"] - AC_carriers: ["AC line", "AC transformer"] - link_carriers: ["DC line", "Converter AC-DC"] - tech_colors: - "onwind" : "#235ebc" - "onshore wind" : "#235ebc" - 'offwind' : "#6895dd" - 'offwind-ac' : "#6895dd" - 'offshore wind' : "#6895dd" - 'offshore wind ac' : "#6895dd" - 'offwind-dc' : "#74c6f2" - 'offshore wind dc' : "#74c6f2" - "hydro" : "#08ad97" - "hydro+PHS" : "#08ad97" - "PHS" : "#08ad97" - "hydro reservoir" : "#08ad97" - 'hydroelectricity' : '#08ad97' - "ror" : "#4adbc8" - "run of river" : "#4adbc8" - 'solar' : "#f9d002" - 'solar PV' : "#f9d002" - 'solar thermal' : '#ffef60' - 'biomass' : '#0c6013' - 'solid biomass' : '#06540d' - 'biogas' : '#23932d' - 'waste' : '#68896b' - 'geothermal' : '#ba91b1' - "OCGT" : "#d35050" - "gas" : "#d35050" - "natural gas" : "#d35050" - "CCGT" : "#b20101" - "nuclear" : "#ff9000" - "coal" : "#707070" - "lignite" : "#9e5a01" - "oil" : "#262626" - "H2" : "#ea048a" - "hydrogen storage" : "#ea048a" - "battery" : "#b8ea04" - "Electric load" : "#f9d002" - "electricity" : "#f9d002" - "lines" : "#70af1d" - "transmission lines" : "#70af1d" - "AC-AC" : "#70af1d" - "AC line" : "#70af1d" - "links" : "#8a1caf" - "HVDC links" : "#8a1caf" - "DC-DC" : "#8a1caf" - "DC link" : "#8a1caf" - nice_names: - OCGT: "Open-Cycle Gas" - CCGT: "Combined-Cycle Gas" - offwind-ac: "Offshore Wind (AC)" - offwind-dc: "Offshore Wind (DC)" - onwind: "Onshore Wind" - solar: "Solar" - PHS: "Pumped Hydro Storage" - hydro: "Reservoir & Dam" - battery: "Battery Storage" - H2: "Hydrogen Storage" - lines: "Transmission Lines" - ror: "Run of River" From ed6d93f6f7b04fcb5964c1ba156c4acad294e801 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Sat, 10 Sep 2022 15:36:01 +0200 Subject: [PATCH 3/5] add missing SPDX license identifier --- envs/environment.fixed.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/envs/environment.fixed.yaml b/envs/environment.fixed.yaml index cde31ba26..723392199 100644 --- a/envs/environment.fixed.yaml +++ b/envs/environment.fixed.yaml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: : 2017-2022 The PyPSA-Eur Authors +# +# SPDX-License-Identifier: CC0-1.0 + name: pypsa-eur channels: - bioconda From c13d3a520c5fc65f3634c04d2bb9d9070c129677 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Sat, 10 Sep 2022 15:38:30 +0200 Subject: [PATCH 4/5] settle envs/environment.yaml --- envs/environment.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/envs/environment.yaml b/envs/environment.yaml index 41fd6c866..8cb8e565f 100644 --- a/envs/environment.yaml +++ b/envs/environment.yaml @@ -7,7 +7,7 @@ channels: - conda-forge - bioconda dependencies: - - python==3.9 + - python>=3.8 - pip - pypsa>=0.20 @@ -37,14 +37,14 @@ dependencies: - pyomo - matplotlib - proj - - fiona # <= 1.18.20 # Till issue https://github.com/Toblerity/Fiona/issues/1085 is not solved + - fiona <= 1.18.20 # Till issue https://github.com/Toblerity/Fiona/issues/1085 is not solved - country_converter # Keep in conda environment when calling ipython - ipython # GIS dependencies: - - cartopy>=0.16 + - cartopy - descartes - rasterio<=1.2.9 # 1.2.10 creates error https://github.com/PyPSA/atlite/issues/238 From 61f4f397e4a37d58badd7dfc2e6456c9e99aa178 Mon Sep 17 00:00:00 2001 From: Fabian Neumann Date: Sat, 10 Sep 2022 15:41:21 +0200 Subject: [PATCH 5/5] remove non-essential packages --- envs/environment.fixed.yaml | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/envs/environment.fixed.yaml b/envs/environment.fixed.yaml index 723392199..b818ce720 100644 --- a/envs/environment.fixed.yaml +++ b/envs/environment.fixed.yaml @@ -127,7 +127,6 @@ dependencies: - gitdb=4.0.9 - gitpython=3.1.27 - glog=0.6.0 - - glpk=5.0 - gmp=6.2.1 - graphite2=1.3.13 - grpc-cpp=1.45.2 @@ -137,15 +136,12 @@ dependencies: - hdf4=4.2.15 - hdf5=1.12.1 - heapdict=1.0.1 - - holoviews=1.15.0 - - hvplot=0.8.0 - icu=68.2 - idna=3.3 - importlib-metadata=4.11.4 - importlib_metadata=4.11.4 - importlib_resources=5.8.0 - iniconfig=1.1.1 - - ipopt=3.14.8 - ipykernel=6.15.1 - ipython=8.4.0 - ipython_genutils=0.2.0 @@ -160,10 +156,6 @@ dependencies: - jupyter_client=7.3.4 - jupyter_core=4.10.0 - jupyter_server=1.18.1 - - jupyterlab=3.4.3 - - jupyterlab_pygments=0.2.2 - - jupyterlab_server=2.15.0 - - jupyterlab_widgets=1.1.1 - kealib=1.4.15 - keyutils=1.6.1 - kiwisolver=1.4.4 @@ -272,8 +264,6 @@ dependencies: - pandas=1.4.3 - pandoc=2.18 - pandocfilters=1.5.0 - - panel=0.13.1 - - param=1.12.2 - parquet-cpp=1.5.1 - parso=0.8.3 - partd=1.2.0 @@ -285,7 +275,6 @@ dependencies: - pip=22.1.2 - pixman=0.40.0 - plac=1.3.5 - - plotly=5.9.0 - pluggy=1.0.0 - ply=3.11 - poppler=21.09.0 @@ -437,6 +426,5 @@ dependencies: - zstd=1.5.2 - pip: - countrycode==0.2 - - gurobipy==9.5.2 - tsam==2.1.0 - vresutils==0.3.1 \ No newline at end of file