From 4f9e71f2b47c0f68e834913eeb7f920653af2c23 Mon Sep 17 00:00:00 2001 From: romainsacchi Date: Thu, 17 Mar 2022 10:14:45 +0000 Subject: [PATCH] Black reformating --- carculator/hot_emissions.py | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/carculator/hot_emissions.py b/carculator/hot_emissions.py index ad7979b7..4c79b25f 100644 --- a/carculator/hot_emissions.py +++ b/carculator/hot_emissions.py @@ -5,8 +5,8 @@ from typing import List, Union import numpy as np -import xarray as xr import pandas as pd +import xarray as xr from . import DATA_DIR @@ -24,7 +24,12 @@ def get_hot_emission_factors() -> xr.DataArray: """ filepath = DATA_DIR / "hot.csv" - hot = pd.read_csv(filepath).groupby(["variable", "powertrain", "euro_class", "component"])["hot"].mean().to_xarray() + hot = ( + pd.read_csv(filepath) + .groupby(["variable", "powertrain", "euro_class", "component"])["hot"] + .mean() + .to_xarray() + ) return hot @@ -35,7 +40,12 @@ def get_non_hot_emission_factors() -> xr.DataArray: """ filepath = DATA_DIR / "non_hot.csv" - non_hot = pd.read_csv(filepath).groupby(["powertrain", "euro_class", "type", "Component"])["hot"].mean().to_xarray() + non_hot = ( + pd.read_csv(filepath) + .groupby(["powertrain", "euro_class", "type", "Component"])["hot"] + .mean() + .to_xarray() + ) return non_hot