Table of Contents¶
t3co/energy_models/fastsim_model/fastsim_wrapper¶
RunFastsim Objects¶
__new__¶
Creates a new instance of the RunFastsim class.
load_vehicle¶
Python
def load_vehicle(veh_no: int,
veh_input_path: Union[str, Path],
use_rust: bool = True) -> fastsim.vehicle.Vehicle
Loads vehicle object from vehicle number and input CSV filepath.
Arguments:
veh_no
int - Vehicle selection number.veh_input_path
Union[str, Path] - Vehicle model assumptions input CSV file path.
Returns:
fastsim.vehicle.Vehicle
- FASTSim vehicle object.
load_design_cycle_from_scenario¶
Python
def load_design_cycle_from_scenario(
scenario: Scenario,
cyc_file_path: Union[str, Path] = gl.CYCLES_FOLDER,
return_rustcycle: bool = True
) -> Union[fastsim.cycle.Cycle, List[fastsim.cycle.Cycle]]
Loads the design cycle used for mpgge and range determination.
Arguments:
scenario
Scenario - Scenario object for current selection.cyc_file_path
Union[str, Path], optional - Drive cycle input file path. Defaults to gl.CYCLES_FOLDER.
Returns:
Union[fastsim.cycle.Cycle, List[fastsim.cycle.Cycle]]: FASTSim cycle object for current Scenario object.
load_design_cycle_from_path¶
Python
def load_design_cycle_from_path(
cyc_file_path: Union[str, Path],
return_rustcycle: bool = True
) -> Union[fastsim.cycle.RustCycle, fastsim.cycle.Cycle]
Loads the Cycle object from the drive cycle filepath.
Arguments:
cyc_file_path
Union[str, Path] - Drive cycle input file path.
Returns:
fastsim.cycle.Cycle
- FASTSim cycle object for current Scenario object.
get_simdrive¶
Creates a SimDrive object for the given cycle and vehicle.
Arguments:
cycle
fastsim.cycle.Cycle - The drive cycle.
Returns:
fastsim.fastsimrust.RustSimDrive
- The RustSimDrive object.
get_range¶
Calculates the range of the vehicle based on its type and energy storage.