Skip to content

Table of Contents

t3co/input_data/vehicle

Vehicle Objects

Python
@dataclass
class Vehicle()

__new__

Python
def __new__(cls, *args, **kwargs)

Creates a new instance of the OpportunityCosts class.

from_config

Python
@classmethod
def from_config(cls, selection: int, config: Config) -> Self

Creates a Vehicle instance from the configuration.

Arguments:

  • selection int - The selection index.
  • config Config - The configuration instance.

Returns:

  • Self - An instance of the Vehicle class.

from_db

Python
@classmethod
def from_db(cls, selection: int, vehicle_db_file: Union[str, Path]) -> Self

Creates a Vehicle instance from the vehicle database file.

Arguments:

  • selection int - The selection index.
  • vehicle_db_file Union[str, Path] - The vehicle database file path.

Returns:

  • Self - An instance of the Vehicle class.

set_veh_kg

Python
def set_veh_kg() -> None

Sets the vehicle weight in kilograms.

delete_dataframes

Python
def delete_dataframes() -> None

Deletes DataFrame attributes from the Vehicle instance.