diff --git a/co2calculator/data_handlers.py b/co2calculator/data_handlers.py index a698e0d..ec87472 100644 --- a/co2calculator/data_handlers.py +++ b/co2calculator/data_handlers.py @@ -1,7 +1,7 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -"""Reader class to retrieve co2 factors from database""" -import warnings +"""Data handler class to handle and validate emission factors from csv file""" + from pathlib import Path import pandas as pd from .exceptions import ConversionFactorNotFound @@ -28,7 +28,7 @@ def get(self, parameters: dict): selected_factors = self.emission_factors for k, v in parameters.items(): - # shortterm hack to make it work until co2 factors are updated + # TODO: shortterm hack to make it work until occupancy is removed from emission factors if not isinstance(v, int): v = str(v.value) if v is None or k not in self.column_names: diff --git a/co2calculator/exceptions.py b/co2calculator/exceptions.py index e097960..752ff91 100644 --- a/co2calculator/exceptions.py +++ b/co2calculator/exceptions.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -"""__description__""" +"""Exceptions for the co2calculator package""" __author__ = "Christina Ludwig, GIScience Research Group, Heidelberg University" __email__ = "christina.ludwig@uni-heidelberg.de" diff --git a/co2calculator/parameters.py b/co2calculator/parameters.py index 4618b77..8ba3a7e 100644 --- a/co2calculator/parameters.py +++ b/co2calculator/parameters.py @@ -1,8 +1,8 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -"""__description__""" +"""Base classes to handle and validate parameters for emission calculations""" -from pydantic import BaseModel, validator, root_validator +from pydantic import BaseModel, validator from .constants import ( TransportationMode, Size,