Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Adapted losses class for
single_link_losses
and `single_link_…
…redundancy`. Included jupyter notebook example. (#383) * chore: shockwave related variables and functions are removed * chore: shockwave related variables and functions are removed * chore: shockwave related variables and functions are removed * chore: losses input parameter name updated * chore: losses input parameter name updated * doc&chore: init of losses are modified and Jupyter notebook is updated * chore: shockwave variables are remove from analysis reader * chore: Type change (to Path) of the input files required in the analysis.ini or config * chore: analysis ini is updated * chore: NetworkSection added for the __init__ of the Losses * chore: NetworkSection related error is resolved * feat: Losses class we developed is renamed and adjusted to single_link_losses. Now single_link_redundancy run is included. Previously developed single_link_losses is renamed to _single_link_losses * feat: Previously developed single_link_losses is renamed to _single_link_losses * chore: Losses import is removed * chore: single_link_losses input files are set as Path() * feat: single_link_redundancy tested in the single_link_losses * chore: separato link_type_hazard_intensity is changed from _ to - * feat: criticality_analysis is passed to the single_link_losses calculation * feat: criticality_analysis is used instead of self.network * chore: previously developed single_link_losses module is deleted * feat: added link_id to AnalysisSectionIndirect * feat: self.link_id added from AnalysisSectionIndirect.link_id * feat: traffic intensity file is checked to have link_id consistent with the input graph (generated in the redundancy analysis) * doc: comment added for link_id * feat: file_id in the config_data.network is used to keep the file_id in the to-be-generated graph * doc: typo's * doc: test-case config update * doc: test-case config update * feat: link_id is added to be parametrically defined * chore: One losses class is made. * feat: link_id linked to the NetworkSection. Also analysis_config is added to be used for the link_id and HazardOverlay() * feat: link_type column added to the losses module and vector_network_wrapper. * feat: link_type column added to the losses module and the criticality_analysis is verified. Also self._check_validity_df() extended to check on the link_id column in the traffic intensities * feat: link_type column replaced in losses.py to become a linked parameter to the NetworkSection. * feat: Losses execution is updated. * feat/chore: csv validation added (geometry is not allowed). Hyphens and underscores are corrected. One workflow is created (previouse to this commmit two workflows were there for multiple and single losses). The criticality gdf has to have EVi_x * feat/filter out rows not exposed to hazard for vlh * feat: trip purposes enum made and added to the reader * feat: trip purposes enum made and added to the reader * feat: trip purposes enum created earlier added to the losses.py. vlh_calc made per row. * feat: calc_vlh updated. * doc: formatting * feat: vehicle_loss_hours converted to GeoDataFrame * feat: execute returns GeoDataFrame * feat: allow using the harardoverlay and its use in the losses.py * doc: example updated * feat: hour_per_day added + more information from the criticality analysis is added to the losses results * feat: remove duplicate ID column in the criticality analysis + _calculate_production_loss_per_capita created * doc: example_losses.ipynb is updated * feat: filtering disrupted and non_disrupted criticality results is converted to a function + all links are included in the results * chore: minor * feat and doc: minor multi_link_losses update and example files and notebook update * fix tests under test_losses.py * fix test losses 1&2 * fix test losses 3 * chore: Small refactoring after merge * chore: link_id turned into an object's variable with the same name. * chore: Corrected analysis config data reader as it was parsing paths where it should not * chore: resolving failed test_losses, updated the test inputs * chore: resolving failed test_losses, updated the check validity of input data and a test * chore: resolving failed test_examples losses, string converted to path * chore: analysis losses removed from the Enum indirect analysis + analysis input files are checked to not to be None * chore: test_analysis_collection updated to return ValueError when no analysis input file is introduced * chore: absolute variable path to ini files * chore: absolute variable path to ini files * doc: input_analysis_data added to example data multi_link_losses + example notebook is updated * doc: example notebook is updated because modify_ini parameters were passed wrongly * chore: Corrected retrieving of network edges with invalid column 'fid' * chore: Small correction to avoid dropping columns when they do not exist * chore: List to tuple to be used as indices and the rest of the code is updated to handle a tuple of links (and their types) when these links are simplified + resilience_curve is updated * chore: test_losses updated based + losses updated for controlling self.criticality_non_disrupted length * doc: AnalysisConfig files to None * doc: example_losses.ipynb updated to only contain teh single_link_losses --------- Co-authored-by: MatthiasHauth <[email protected]> Co-authored-by: Carles S. Soriano Perez <[email protected]>
- Loading branch information