[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
This commit is contained in:
pre-commit-ci[bot] 2024-03-26 15:25:46 +00:00
parent d7fedc6235
commit 435350e07b
2 changed files with 1 additions and 5 deletions

View File

@ -23,13 +23,11 @@ from _helpers import (
logger = logging.getLogger(__name__) logger = logging.getLogger(__name__)
def build_nodal_transport_data(fn, pop_layout, year): def build_nodal_transport_data(fn, pop_layout, year):
# get numbers of car and fuel efficiency per country # get numbers of car and fuel efficiency per country
transport_data = pd.read_csv(fn, index_col=[0, 1]) transport_data = pd.read_csv(fn, index_col=[0, 1])
transport_data = transport_data.xs(min(2015, year), level="year") transport_data = transport_data.xs(min(2015, year), level="year")
# break number of cars down to nodal level based on population density # break number of cars down to nodal level based on population density
nodal_transport_data = transport_data.loc[pop_layout.ct].fillna(0.0) nodal_transport_data = transport_data.loc[pop_layout.ct].fillna(0.0)
nodal_transport_data.index = pop_layout.index nodal_transport_data.index = pop_layout.index

View File

@ -23,15 +23,13 @@ from _helpers import (
update_config_from_wildcards, update_config_from_wildcards,
) )
from add_electricity import calculate_annuity, sanitize_carriers, sanitize_locations from add_electricity import calculate_annuity, sanitize_carriers, sanitize_locations
from build_transport_demand import transport_degree_factor
from build_energy_totals import ( from build_energy_totals import (
build_co2_totals, build_co2_totals,
build_eea_co2, build_eea_co2,
build_eurostat, build_eurostat,
build_eurostat_co2, build_eurostat_co2,
) )
from build_transport_demand import transport_degree_factor
from networkx.algorithms import complement from networkx.algorithms import complement
from networkx.algorithms.connectivity.edge_augmentation import k_edge_augmentation from networkx.algorithms.connectivity.edge_augmentation import k_edge_augmentation
from prepare_network import maybe_adjust_costs_and_potentials from prepare_network import maybe_adjust_costs_and_potentials