[ ] I am using the current main branch or the latest release. Please indicate.
[ ] I am running on an up-to-date pypsa-africa environment. Update via conda env update -f envs/environment.yaml.
Describe the Bug
'NA' interpreted as NaN
Error Message
If applicable, paste any terminal output to help illustrating your problem.In some cases it may also be useful to share your list of installed packages: conda list.
Traceback (most recent call last):
File "/mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/.snakemake/scripts/tmpki94c8ih.build_population_layouts.py", line 108, in <module>
rural_fraction_ct = 1 - urban_fraction[ct]
File "/home/aca39878/anaconda3/envs/pypsa-earth/lib/python3.10/site-packages/pandas/core/series.py", line 1040, in __getitem__
return self._get_value(key)
File "/home/aca39878/anaconda3/envs/pypsa-earth/lib/python3.10/site-packages/pandas/core/series.py", line 1156, in _get_value
loc = self.index.get_loc(label)
File "/home/aca39878/anaconda3/envs/pypsa-earth/lib/python3.10/site-packages/pandas/core/indexes/base.py", line 3798, in get_loc
raise KeyError(key) from err
KeyError: 'NA'
[Sun Feb 4 02:09:27 2024]
INFO:snakemake.logging:[Sun Feb 4 02:09:27 2024]
Error in rule build_population_layouts:
jobid: 11
input: /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/pypsa-earth/resources/shapes/gadm_shapes.geojson, data/urban_percent.csv, /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/pypsa-earth/cutouts/cutout-2013-era5.nc
output: resources/population_shares/pop_layout_total.nc, resources/population_shares/pop_layout_urban.nc, resources/population_shares/pop_layout_rural.nc, resources/gdp_shares/gdp_layout.nc
ERROR:snakemake.logging:Error in rule build_population_layouts:
jobid: 11
input: /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/pypsa-earth/resources/shapes/gadm_shapes.geojson, data/urban_percent.csv, /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/pypsa-earth/cutouts/cutout-2013-era5.nc
output: resources/population_shares/pop_layout_total.nc, resources/population_shares/pop_layout_urban.nc, resources/population_shares/pop_layout_rural.nc, resources/gdp_shares/gdp_layout.nc
RuleException:
CalledProcessError in file /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/Snakefile, line 350:
Command 'set -euo pipefail; /home/aca39878/anaconda3/envs/pypsa-earth/bin/python3.10 /mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/.snakemake/scripts/tmpki94c8ih.build_population_layouts.py' returned non-zero exit status 1.
File "/mnt/c/Users/aca39878/Documents/Git/Namibia/pypsa-earth-sec/Snakefile", line 350, in __rule_build_population_layouts
File "/home/aca39878/anaconda3/envs/pypsa-earth/lib/python3.10/concurrent/futures/thread.py", line 58, in run```
Checklist
main
branch or the latest release. Please indicate.pypsa-africa
environment. Update viaconda env update -f envs/environment.yaml
.Describe the Bug
'NA' interpreted as NaN
Error Message
If applicable, paste any terminal output to help illustrating your problem. In some cases it may also be useful to share your list of installed packages:
conda list
.