r2d_component¶
- class pyrecodes.component.r2d_component.R2DBridge¶
Bases:
R2DTransportationComponent
Subclass used to identify R2D Bridges in a system. For now that’s the only purpose.
TODO: Add specific bridge methods and attributes. Future work.
- class pyrecodes.component.r2d_component.R2DBuilding¶
Bases:
R2DComponent
Class used to represent buildings in a system when using the R2D files as inputs.
- update_r2d_dict()¶
Extend the parent method to update the ratio of the population in the building at a time step in the R2D dictionary based on the functionality level. The population ratio is used by SimCenter infrastructure simulators (residual demand) to calculate the demand for resources.
- class pyrecodes.component.r2d_component.R2DComponent¶
Bases:
StandardiReCoDeSComponent
Class used to simulate components created using R2D outputs.
Note that SimCenter’s infrastructure simulators (REWET, residual demand) only work with R2DComponent objects.
- update(time_step: int) None ¶
Extend the parent method to update the R2D dictionary used to interface pyrecodes with SimCenter’s infrastructure simulators.
- update_r2d_dict(demand_types=['OperationDemand', 'RecoveryDemand']) None ¶
Update the R2D dictionary with the current resource demand of the component. SimCenter’s infrastructure simulators get component’s demand from this dictionary.
- class pyrecodes.component.r2d_component.R2DPipe¶
Bases:
R2DComponent
Subclass representing pipes in a water distribution system defined using the R2D files as inputs.
- update_r2d_dict() None ¶
Extend the parent method to update the functionality parameter of an R2DPipe in the R2D dictionary based on its functionality level.
- class pyrecodes.component.r2d_component.R2DRoadway¶
Bases:
R2DTransportationComponent
Subclass used to identify R2D Roadways in a system. For now that’s the only purpose.
TODO: Add specific roadway methods and attributes. Future work.
- class pyrecodes.component.r2d_component.R2DTransportationComponent¶
Bases:
R2DComponent
Subclass used to identify transportation components in a system. For now that’s the only purpose.
- update_r2d_dict() None ¶
Update the resource-to-damage dictionary based on the current damage level of the pipe.
- class pyrecodes.component.r2d_component.R2DTunnel¶
Bases:
R2DTransportationComponent
Subclass used to identify R2D Tunnels in a system. For now that’s the only purpose.
TODO: Add specific tunnel methods and attributes. Future work.