From 0a38db623a8e8f8d6044cc739437719e7a92a9d5 Mon Sep 17 00:00:00 2001 From: romainsacchi Date: Tue, 30 Jul 2024 14:50:36 +0000 Subject: [PATCH] Black reformating --- premise/wind_turbines.py | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/premise/wind_turbines.py b/premise/wind_turbines.py index c55e3b39..80c72b7c 100644 --- a/premise/wind_turbines.py +++ b/premise/wind_turbines.py @@ -37,16 +37,16 @@ def _update_wind_turbines(scenario, version, system_model): def relink( - dataset, + dataset, ) -> dict: """ Relink technosphere exchanges to the new datasets. """ for exc in ws.technosphere( - dataset, + dataset, ws.equals("unit", "unit"), - ws.exclude(ws.contains("name", "connection")) + ws.exclude(ws.contains("name", "connection")), ): exc["name"] += ", direct drive" @@ -106,13 +106,8 @@ def create_direct_drive_turbines(self): new_datasets, processed = [], [] for dataset in ws.get_many( self.database, - ws.either( - *[ - ws.contains("name", tech) - for tech in datasets_terms - ] - ), - ws.exclude(ws.contains("name", "direct drive")) + ws.either(*[ws.contains("name", tech) for tech in datasets_terms]), + ws.exclude(ws.contains("name", "direct drive")), ): if dataset["code"] not in processed: dataset_copy = self.create_dataset_copy(dataset, "direct drive")