Skip to content

Commit

Permalink
Merge pull request #428 from IN-CORE/release-4.14.0
Browse files Browse the repository at this point in the history
Release 4.14.0
  • Loading branch information
longshuicy authored Oct 24, 2024
2 parents cd283f4 + fd748f1 commit 89ac639
Show file tree
Hide file tree
Showing 13 changed files with 1,366 additions and 51 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,16 @@ All notable changes to the INCORE documents generated by Sphinx package will be
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## [4.14.0] - 2024-10-23

### Added
- API documentation for project service [#423](https://github.com/IN-CORE/incore-docs/issues/423)
- Documentation for Equity Metric Analysis [#425](https://github.com/IN-CORE/incore-docs/issues/425)
- ML Enabled Joplin CGE notebook [#429](https://github.com/IN-CORE/incore-docs/issues/429)

### Changed
- Update docs according to support Interdependent recovery analysis [#417](https://github.com/IN-CORE/incore-docs/issues/417)

## [4.13.0] - 2024-08-21

### Changed
Expand Down
2 changes: 1 addition & 1 deletion manual_jb/content/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ project: "IN-CORE Manual"
author: IN-CORE Community
copyright: "2023" # Copyright year to be placed in the footer
logo: images/resilience-logo.png
version: "4.13.0" # Version is not part of JB config, we use it for autobuild of incore-docs
version: "4.14.0" # Version is not part of JB config, we use it for autobuild of incore-docs
exclude_patterns: [_build, .DS_Store, "**.ipynb_checkpoints"]

repository:
Expand Down
3 changes: 3 additions & 0 deletions manual_jb/content/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ chapters:
- file: analyses/epf_repair_cost
- file: analyses/epf_restoration
- file: analyses/epn_functionality
- file: analyses/equity_metric
- file: analyses/galveston_cge
- file: analyses/gas_facility_damage
- file: analyses/housing_household_recovery
Expand All @@ -41,6 +42,8 @@ chapters:
- file: analyses/joplin_empirical_restoration
- file: analyses/mean_dmg
- file: analyses/mc_limit_state_prob
- file: analyses/ml_joplin_cge
- file: analyses/ml_slc_cge
- file: analyses/multi_retrofit_optimization
- file: analyses/nci_functionality
- file: analyses/pipeline_dmg
Expand Down
66 changes: 34 additions & 32 deletions manual_jb/content/analyses.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,35 +17,37 @@
15. [Electric power facility repair cost](analyses/epf_repair_cost)
16. [Electric power facility restoration](analyses/epf_restoration)
17. [Electric power network functionality](analyses/epn_functionality)
18. [Galveston Computable General Equilibrium (CGE)](analyses/galveston_cge.md)
19. [Gas facility damage](analyses/gas_facility_damage)
20. [Household-level housing sequential recovery](analyses/housing_household_recovery)
21. [Housing recovery](analyses/housing_recovery)
22. [Housing unit allocation](analyses/housingunitallocation)
23. [Interdependent Network Design Problem](analyses/indp)
24. [Joplin Computable General Equilibrium (CGE)](analyses/joplin_cge)
25. [Joplin empirical building restoration](analyses/joplin_empirical_building_restoration)
26. [Machine Learning Enabled Computable General Equilibrium (CGE) - Salt Lake City](analyses/ml_slc_cge.md)
27. [Mean damage](analyses/mean_dmg)
28. [Monte Carlo limit state probability](analyses/mc_limit_state_prob)
29. [Multi-objective retrofit optimization](analyses/multi_retrofit_optimization)
30. [Network cascading interdependency functionality](analyses/nci_functionality)
31. [Pipeline damage](analyses/pipeline_dmg)
32. [Pipeline damage with repair rate](analyses/pipeline_dmg_w_repair_rate)
33. [Pipeline functionality](analyses/pipeline_functionality)
34. [Pipeline repair cost](analyses/pipeline_repair_cost)
35. [Pipeline restoration](analyses/pipeline_restoration)
36. [Population dislocation](analyses/populationdislocation)
37. [Residential building recovery](analyses/residential_building_recovery)
38. [Road damage](analyses/road_dmg)
39. [Salt Lake City Computable General Equilibrium (CGE)](analyses/slc_cge.md)
40. [Seaside Computable General Equilibrium (CGE)](analyses/seaside_cge)
41. [Social Vulnerability](analyses/social_vulnerability)
42. [Social Vulnerability Score](analyses/social_vulnerability_score)
43. [Tornado electric power network (EPN) damage](analyses/tornadoepn_dmg)
44. [Traffic flow recovery](analyses/traffic_flow_recovery)
45. [Transportation recovery](analyses/transportation_recovery)
46. [Water facility damage](analyses/waterfacility_dmg)
47. [Water network functionality](analyses/wfn_functionality)
48. [Water facility repair cost](analyses/water_facility_repair_cost)
49. [Water facility restoration](analyses/water_facility_restoration)
18. [Equity Metric](analyses/equity_metric)
19. [Galveston Computable General Equilibrium (CGE)](analyses/galveston_cge.md)
20. [Gas facility damage](analyses/gas_facility_damage)
21. [Household-level housing sequential recovery](analyses/housing_household_recovery)
22. [Housing recovery](analyses/housing_recovery)
23. [Housing unit allocation](analyses/housingunitallocation)
24. [Interdependent Network Design Problem](analyses/indp)
25. [Joplin Computable General Equilibrium (CGE)](analyses/joplin_cge)
26. [Joplin empirical building restoration](analyses/joplin_empirical_building_restoration)
27. [Machine Learning Enabled Computable General Equilibrium (CGE) - Joplin](analyses/ml_joplin_cge.md)
28. [Machine Learning Enabled Computable General Equilibrium (CGE) - Salt Lake City](analyses/ml_slc_cge.md)
29. [Mean damage](analyses/mean_dmg)
30. [Monte Carlo limit state probability](analyses/mc_limit_state_prob)
31. [Multi-objective retrofit optimization](analyses/multi_retrofit_optimization)
32. [Network cascading interdependency functionality](analyses/nci_functionality)
33. [Pipeline damage](analyses/pipeline_dmg)
34. [Pipeline damage with repair rate](analyses/pipeline_dmg_w_repair_rate)
35. [Pipeline functionality](analyses/pipeline_functionality)
36. [Pipeline repair cost](analyses/pipeline_repair_cost)
37. [Pipeline restoration](analyses/pipeline_restoration)
38. [Population dislocation](analyses/populationdislocation)
39. [Residential building recovery](analyses/residential_building_recovery)
40. [Road damage](analyses/road_dmg)
41. [Salt Lake City Computable General Equilibrium (CGE)](analyses/slc_cge.md)
42. [Seaside Computable General Equilibrium (CGE)](analyses/seaside_cge)
43. [Social Vulnerability](analyses/social_vulnerability)
44. [Social Vulnerability Score](analyses/social_vulnerability_score)
45. [Tornado electric power network (EPN) damage](analyses/tornadoepn_dmg)
46. [Traffic flow recovery](analyses/traffic_flow_recovery)
47. [Transportation recovery](analyses/transportation_recovery)
48. [Water facility damage](analyses/waterfacility_dmg)
49. [Water network functionality](analyses/wfn_functionality)
50. [Water facility repair cost](analyses/water_facility_repair_cost)
51. [Water facility restoration](analyses/water_facility_restoration)
84 changes: 84 additions & 0 deletions manual_jb/content/analyses/equity_metric.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
# Equity Metric

**Description**

The algorithm computes equity metrics to characterize the inequity present in the infrastructure service provision
between two groups of concerns’ (e.g., low income vs. non-low income, minority vs non-minority, etc.). The metrics are
built upon Theil’s T, which is a common metric to compute the inequality present in the dispersion of a scarce
resource (e.g., income). The metrics could also be implemented to assess inequity in different scenarios with other
scarce resources of concern.

To compute the metrics, a scarce resource should be formulated and calculated for an infrastructure application. The
scarce resource for infrastructure can be taken as any user defined relevant values, such as a resilience score (i.e.,
probability of service provision) or recovery time. We've included a companion utility class where we define and
prepare recovery time as a scarce resource. Other scarce resources can and could be explored if provided by the user.

The equity metric allows for an equity assessment of the current infrastructure service provision. It also enables the
assessment of equity gains for a given retrofit plan and can be integrated into an overall decision-making process..
The output metrics tell the following information 1) Theil's T - overall amount of inequality in scarce resource's
dispersion across a community (distributional inequity) 2) Between Zone Inequality (BZI) - amount of inequality
attributed to scarce resource differences between groups (restorative inequity), and 3) Within Zone Inequality (WZI) -
amount of inequality due to resource differences among singular groups.

**Contributors**

- Science: Abigail L. Beck, Ph.D, Eun Jeong Cha, Ph.D, Walter Peacock, Ph.D
- Implementation: NCSA IN-CORE Dev Team

**Related publications**

- Beck, A.L., Cha, E.J. & Peacock, W.G. "Incorporation of Equity into Infrastructure Decision-Making: Development of an
Equity Metric for Infrastructure Retrofitting," The 14th International Conference on Applications of Statistics and
Probability in Civil Engineering (ICASP14), Dublin, Ireland, July, 2023. http://hdl.handle.net/2262/103309

**Input parameters**

key name | type | name | description
-----------------------------------------|-------|-------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
`result_name` <sup>*</sup> | `str` | Result name | Name of the result dataset.
`division_decision_column` <sup>*</sup> | `str` | Division decision column name | Column name of a binary variable associated with each household used to group it into two groups (e.g. low income vs non low income, minority vs non-minority, social vulnerability)

**Input datasets**

key name | type | name | description
----------------------------------------|---------------------------------------------------------------------------------------------------------------------|--------------------|------------------------------------------------------------------------
`housing_unit_allocation` <sup>*</sup> | [`incore:housingUnitAllocation`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:housingUnitAllocation) | Housing allocation | A housing unit allocation dataset.
`scarce_resource` <sup>*</sup> | [`incore:scarceResource`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:scarceResource) | Scarce resource | Scarce resource dataset e.g. probability of service, return time, etc.

**Output datasets**

key name | type | parent key | name | description
------------------------------|---------------------------------------------------------------------------------------------------|------------|---------------|-------------------------------------------------------------------------------------------------------
`equity_metric` <sup>*</sup> | [`incore:equityMetric`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:equityMetric) | | Equity Metric | CSV file of equity metric, including Theil’s T Value, Between Zone Inequality, Within Zone Inequality

<small>(* required)</small>

**Execution**

code snippet:

```
client = IncoreClient()
datasvc = DataService(client)
# Example of preparing scarce resource
repair_time_df = Dataset.from_data_service(housing_recovery_id, datasvc).get_dataframe_from_csv()
scarce_resource_df = EquityMetricUtil.prepare_return_time_as_scarce_resource(
repair_time_df
)
scarce_resource = Dataset.from_dataframe(
scarce_resource_df, "scarce_resource", data_type="incore:scarceResource"
)
# Example of running equity metric analysis
equity_metric = EquityMetric(client)
equity_metric.set_parameter("result_name", "Galveston_recovery_time")
equity_metric.set_parameter("division_decision_column", "SVI")
equity_metric.load_remote_input_dataset(
"housing_unit_allocation", housing_unit_allocation_id
)
equity_metric.set_input_dataset("scarce_resource", scarce_resource)
equity_metric.run_analysis()
```

full analysis: [equity_metric.ipynb](https://github.com/IN-CORE/incore-docs/blob/main/notebooks/equity_metric.ipynb)
28 changes: 16 additions & 12 deletions manual_jb/content/analyses/housing_household_recovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,26 +23,30 @@ The output of the computation is the history of housing recovery changes for eac

**Input parameters**

key name | type | name | description
--- | --- | --- | ---
`result_name` <sup>*</sup> | `str` | Result name | Name of the result dataset.
`seed` <sup>*</sup> | `int` | Seed | Initial value to seed the random number generator to ensure replication of the Markov Chain path'<br>in connection with Population Dislocation.
`t_delta` <sup>*</sup> | `float` | Time step | A size of the analysis time step.
`t_final` <sup>*</sup> | `float` | Time duration | Total duration.
key name | type | name | description
--- | --- |----------------| ---
`result_name` <sup>*</sup> | `str` | Result name | Name of the result dataset.
`seed` <sup>*</sup> | `int` | Seed | Initial value to seed the random number generator to ensure replication of the Markov Chain path'<br>in connection with Population Dislocation.
`t_delta` <sup>*</sup> | `float` | Time step | A size of the analysis time step.
`t_final` <sup>*</sup> | `float` | Time duration | Total duration.
`num_cpu` | `int` | Number of CPUs | If using parallel execution, the number of cpus to request.

**Input datasets**

key name | type | name | description
--- | --- | --- | ---
`population_dislocation_block` <sup>*</sup> | [`incore:popDislocation`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:popDislocation) | Population dislocation | Population dislocation results.
`tpm` <sup>*</sup> | [`incore:houseRecTransitionProbMatrix`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecTransitionProbMatrix) | Probability matrix | A transition probability matrix that specifies<br>the corresponding Markov chain per social vulnerability level.
`initial_stage_probability` <sup>*</sup> | [`incore:houseRecInitialStageFactors`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecInitialStageFactors) | Mass probability | Initial mass probability function for stage 0 of the Markov Chain.
key name | type | name | description
--- | --- |-----------------------------| ---
`population_dislocation_block` <sup>*</sup> | [`incore:popDislocation`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:popDislocation) | Population dislocation | Population dislocation results.
`tpm` <sup>*</sup> | [`incore:houseRecTransitionProbMatrix`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecTransitionProbMatrix) | Probability matrix | A transition probability matrix that specifies<br>the corresponding Markov chain per social vulnerability level.
`initial_stage_probabilities` <sup>*</sup> | [`incore:houseRecInitialStageFactors`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecInitialStageFactors) | Mass probability | Initial mass probability function for stage 0 of the Markov Chain.
`sv_result` | [`incore:socialVulnerabilityScore`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:popDislocation) | Social vulnerability result | A csv file with zones containing demographic factors.
`zone_def_sv` | [`incore:zoneDefinitionsSocialVulnerability`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecTransitionProbMatrix) | Zone Definition: social vulnerability | A json file with thresholds and definitions per zone based on social vulnerability analysis.
`zone_def_hhinc` | [`incore:zoneDefinitionsHouseholdIncome`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:houseRecInitialStageFactors) | Zone Definition: household income | A json file with thresholds and definitions per zone based on household income.

**Output datasets**

key name | type | parent key | name | description
--- | --- | --- | --- | ---
`result` <sup>*</sup> | [`incore:housingRecoveryHistory`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:housingRecoveryHistory) | `housing_recovery_block` | Results | A dataset containing results (format: CSV)<br>with housing recovery sequences at the individual household level.
`ds_result` <sup>*</sup> | [`incore:housingRecoveryHistory`](https://incore.ncsa.illinois.edu/semantics/api/types/incore:housingRecoveryHistory) | `housing_recovery_block` | Results | A dataset containing results (format: CSV)<br>with housing recovery sequences at the individual household level.

<small>(* required)</small>

Expand Down
Loading

0 comments on commit 89ac639

Please sign in to comment.