nrel.hive.initialization.initialize_ops
Module Contents
Functions
|
creates an immutable map that contains all of the fleet ids associated with the appropriate entity ids |
|
- nrel.hive.initialization.initialize_ops.process_fleet_file(fleet_file: str, entity_type: str) nrel.hive.util.typealiases.MembershipMap[source]
creates an immutable map that contains all of the fleet ids associated with the appropriate entity ids
- Parameters:
fleet_file – the file to load memberships from
entity_type – the category the entity falls under, such as vehicles, bases, or stations
- Returns:
an immutable map mapping all entity ids with the appropriate memberships
- Raises:
Exception – from KEYErrors parsing the fleets file
- nrel.hive.initialization.initialize_ops.read_fleet_ids_from_file(fleet_file: str) FrozenSet[nrel.hive.util.typealiases.EntityId][source]
- Parameters:
fleet_file – the file containing fleet information
- Returns:
the list of base-level keys in the fleet file, which should be fleet ids
- Raises:
IOError if fleet_file does not exist or is not a yaml file