You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
a) I tried to use the sector tutorial with a larger number of clusters and changed the value from 5 to 'all'.
Then I get the error below. Maybe you want to use tools like pylint etc. to check for number of arguments.
INFO:pypsa.io:Imported network elec_s.nc has buses, carriers, generators, lines, loads, shapes
ERROR:root:Uncaught exception
Traceback (most recent call last):
File "/home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmpnlfyn0go.cluster_network.py", line 528, in
clustering = pypsa.clustering.spatial.Clustering(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: Clustering.init() takes 4 positional arguments but 6 were given
RuleException:
CalledProcessError in file /home/projekt-resilient03/pypsa-eur/rules/build_electricity.smk, line 511:
Command 'set -euo pipefail; /home/projekt-resilient03/conda/envs/pypsa-eur/bin/python3.11 /home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmpnlfyn0go.cluster_network.py' returned non-zero exit status 1.
[Fri Jul 12 10:11:45 2024]
b) After removing some of the arguments I got another error:
INFO:main:Using biomass potentials for 2030.
Traceback (most recent call last):
File "/home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmp9so9_wsv.build_shipping_demand.py", line 60, in
nodal_demand = demand.loc[countries].fillna(0.0)
~~~~~~~~~~^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1191, in getitem
return self._getitem_axis(maybe_callable, axis=axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1420, in _getitem_axis
return self._getitem_iterable(key, axis=axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1360, in _getitem_iterable
keyarr, indexer = self._get_listlike_indexer(key, axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1558, in _get_listlike_indexer
keyarr, indexer = ax._get_indexer_strict(key, axis_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexes/base.py", line 6200, in _get_indexer_strict
self._raise_if_missing(keyarr, indexer, axis_name)
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexes/base.py", line 6249, in _raise_if_missing
raise KeyError(f"None of [{key}] are in the [{axis_name}]")
KeyError: "None of [Index(['50', '50', '74'], dtype='object', name='name')] are in the [index]"
a) I tried to use the sector tutorial with a larger number of
clusters
and changed the value from 5 to 'all'.Then I get the error below. Maybe you want to use tools like pylint etc. to check for number of arguments.
INFO:pypsa.io:Imported network elec_s.nc has buses, carriers, generators, lines, loads, shapes
ERROR:root:Uncaught exception
Traceback (most recent call last):
File "/home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmpnlfyn0go.cluster_network.py", line 528, in
clustering = pypsa.clustering.spatial.Clustering(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: Clustering.init() takes 4 positional arguments but 6 were given
RuleException:
CalledProcessError in file /home/projekt-resilient03/pypsa-eur/rules/build_electricity.smk, line 511:
Command 'set -euo pipefail; /home/projekt-resilient03/conda/envs/pypsa-eur/bin/python3.11 /home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmpnlfyn0go.cluster_network.py' returned non-zero exit status 1.
[Fri Jul 12 10:11:45 2024]
b) After removing some of the arguments I got another error:
INFO:main:Using biomass potentials for 2030.
Traceback (most recent call last):
File "/home/projekt-resilient03/pypsa-eur/.snakemake/scripts/tmp9so9_wsv.build_shipping_demand.py", line 60, in
nodal_demand = demand.loc[countries].fillna(0.0)
~~~~~~~~~~^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1191, in getitem
return self._getitem_axis(maybe_callable, axis=axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1420, in _getitem_axis
return self._getitem_iterable(key, axis=axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1360, in _getitem_iterable
keyarr, indexer = self._get_listlike_indexer(key, axis)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexing.py", line 1558, in _get_listlike_indexer
keyarr, indexer = ax._get_indexer_strict(key, axis_name)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexes/base.py", line 6200, in _get_indexer_strict
self._raise_if_missing(keyarr, indexer, axis_name)
File "/home/projekt-resilient03/conda/envs/pypsa-eur/lib/python3.11/site-packages/pandas/core/indexes/base.py", line 6249, in _raise_if_missing
raise KeyError(f"None of [{key}] are in the [{axis_name}]")
KeyError: "None of [Index(['50', '50', '74'], dtype='object', name='name')] are in the [index]"
Related:
#1149
Checklist
master
branch or the latest release. Please indicate.pypsa-eur
environment. Update viaconda env update -f envs/environment.yaml
.The text was updated successfully, but these errors were encountered: