Skip to content

Commit

Permalink
Black reformating
Browse files Browse the repository at this point in the history
  • Loading branch information
romainsacchi committed Mar 17, 2022
1 parent 618adab commit 4f9e71f
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions carculator/hot_emissions.py
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand All @@ -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

Expand All @@ -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

Expand Down

0 comments on commit 4f9e71f

Please sign in to comment.