Skip to content

Commit 07ee9e7

Browse files
committed
risk readme
1 parent 880f3b5 commit 07ee9e7

File tree

2 files changed

+194
-0
lines changed

2 files changed

+194
-0
lines changed

configs/oq.yml

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
name: oq
2+
channels:
3+
- conda-forge
4+
- defaults
5+
dependencies:
6+
- _libgcc_mutex=0.1=conda_forge
7+
- _openmp_mutex=4.5=2_gnu
8+
- asttokens=2.4.1=pyhd8ed1ab_0
9+
- bzip2=1.0.8=h4bc722e_7
10+
- ca-certificates=2024.8.30=hbcca054_0
11+
- comm=0.2.2=pyhd8ed1ab_0
12+
- debugpy=1.8.7=py311hfdbb021_0
13+
- decorator=5.1.1=pyhd8ed1ab_0
14+
- exceptiongroup=1.2.2=pyhd8ed1ab_0
15+
- executing=2.1.0=pyhd8ed1ab_0
16+
- ipykernel=6.29.5=pyh3099207_0
17+
- ipython=8.28.0=pyh707e725_0
18+
- jedi=0.19.1=pyhd8ed1ab_0
19+
- jupyter_client=8.6.3=pyhd8ed1ab_0
20+
- jupyter_core=5.7.2=pyh31011fe_1
21+
- keyutils=1.6.1=h166bdaf_0
22+
- krb5=1.21.3=h659f571_0
23+
- ld_impl_linux-64=2.43=h712a8e2_2
24+
- libedit=3.1.20191231=he28a2e2_2
25+
- libexpat=2.6.3=h5888daf_0
26+
- libffi=3.4.2=h7f98852_5
27+
- libgcc=14.2.0=h77fa898_1
28+
- libgcc-ng=14.2.0=h69a702a_1
29+
- libgomp=14.2.0=h77fa898_1
30+
- libnsl=2.0.1=hd590300_0
31+
- libsodium=1.0.20=h4ab18f5_0
32+
- libsqlite=3.47.0=hadc24fc_0
33+
- libstdcxx=14.2.0=hc0a3c3a_1
34+
- libstdcxx-ng=14.2.0=h4852527_1
35+
- libuuid=2.38.1=h0b41bf4_0
36+
- libxcrypt=4.4.36=hd590300_1
37+
- libzlib=1.3.1=hb9d3cd8_2
38+
- matplotlib-inline=0.1.7=pyhd8ed1ab_0
39+
- ncurses=6.5=he02047a_1
40+
- nest-asyncio=1.6.0=pyhd8ed1ab_0
41+
- openssl=3.3.2=hb9d3cd8_0
42+
- parso=0.8.4=pyhd8ed1ab_0
43+
- pexpect=4.9.0=pyhd8ed1ab_0
44+
- pickleshare=0.7.5=py_1003
45+
- pip=24.2=pyh8b19718_1
46+
- platformdirs=4.3.6=pyhd8ed1ab_0
47+
- prompt-toolkit=3.0.48=pyha770c72_0
48+
- ptyprocess=0.7.0=pyhd3deb0d_0
49+
- pure_eval=0.2.3=pyhd8ed1ab_0
50+
- pygments=2.18.0=pyhd8ed1ab_0
51+
- python=3.11.10=hc5c86c4_3_cpython
52+
- python_abi=3.11=5_cp311
53+
- readline=8.2=h8228510_1
54+
- six=1.16.0=pyh6c4a22f_0
55+
- stack_data=0.6.2=pyhd8ed1ab_0
56+
- tk=8.6.13=noxft_h4845f30_101
57+
- tornado=6.4.1=py311h9ecbd09_1
58+
- traitlets=5.14.3=pyhd8ed1ab_0
59+
- typing_extensions=4.12.2=pyha770c72_0
60+
- wcwidth=0.2.13=pyhd8ed1ab_0
61+
- wheel=0.44.0=pyhd8ed1ab_0
62+
- xz=5.2.6=h166bdaf_0
63+
- zeromq=4.3.5=h3b0a872_6
64+
- pip:
65+
- alpha-shapes==1.1.0
66+
- asgiref==3.7.2
67+
- attrs==23.1.0
68+
- certifi==2023.11.17
69+
- chardet==5.2.0
70+
- charset-normalizer==3.3.2
71+
- click==8.1.7
72+
- click-plugins==1.1.1
73+
- cligj==0.7.2
74+
- coloredlogs==15.0.1
75+
- contourpy==1.2.0
76+
- cycler==0.12.1
77+
- django==4.2.10
78+
- django-appconf==1.0.6
79+
- django-cookie-consent==0.6.0
80+
- django-cors-headers==4.3.1
81+
- django-pam==2.1.2
82+
- docutils==0.20.1
83+
- fiona==1.9.5
84+
- flake8==6.1.0
85+
- flatbuffers==23.5.26
86+
- fonttools==4.39.0
87+
- gdal==3.7.3
88+
- h5py==3.10.0
89+
- humanfriendly==10.0
90+
- idna==3.6
91+
- importlib-metadata==7.0.0
92+
- iniconfig==2.0.0
93+
- kiwisolver==1.4.5
94+
- llvmlite==0.41.1
95+
- matplotlib==3.8.2
96+
- mccabe==0.7.0
97+
- mpmath==1.3.0
98+
- munch==4.0.0
99+
- networkx==3.2.1
100+
- numba==0.58.1
101+
- numpy==1.26.2
102+
- onnxruntime==1.16.3
103+
- openquake-engine==3.22.0
104+
- packaging==23.2
105+
- pandas==2.0.3
106+
- pbr==6.0.0
107+
- pillow==10.1.0
108+
- pluggy==1.5.0
109+
- protobuf==4.25.1
110+
- psutil==5.9.6
111+
- pycodestyle==2.11.1
112+
- pyflakes==3.1.0
113+
- pyparsing==3.1.1
114+
- pyproj==3.6.1
115+
- pyreadline3==3.4.1
116+
- pyshp==2.3.1
117+
- pytest==8.3.3
118+
- python-dateutil==2.8.2
119+
- python-pam==2.0.2
120+
- pytz==2023.3
121+
- pyzmq==26.0.3
122+
- requests==2.31.0
123+
- scipy==1.11.4
124+
- setproctitle==1.3.3
125+
- setuptools==69.0.2
126+
- shapely==2.0.2
127+
- sqlparse==0.4.4
128+
- sympy==1.12
129+
- toml==0.10.2
130+
- tzdata==2023.3
131+
- urllib3==2.1.0
132+
- zipp==3.17.0
133+
prefix: /home/naveen.raguramalinga/opt/miniconda3/envs/oq

risk/README.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# Tsunami Risk Calculation using OpenQuake
2+
3+
This repository contains the implementation of tsunami loss calculation using OpenQuake. It is used to perform a benchmarking exercise comparing results from input hazard data generated by HPC-based simulations and different ML emulators trained with varying data sizes(number of events).
4+
5+
## Folder Structure
6+
7+
The repository is organized as follows:
8+
9+
```
10+
├── exposure
11+
│ ├── Admin_units
12+
│ ├── CT_Building_Footprint.gpkg
13+
│ └── exposure_prep.ipynb
14+
├── hazard
15+
│ ├── log
16+
│ └── hazard_prep.ipynb
17+
├── loss
18+
│ ├── log
19+
│ └── hazard_prep.ipynb
20+
├── plots
21+
│ ├── configs
22+
│ ├── hazard_compare
23+
│ └── risk_compare
24+
├── results
25+
│ ├── configs
26+
│ ├── log
27+
│ └── risk_calc
28+
├── temp
29+
├── vulnerability
30+
```
31+
32+
- `exposure/`: Contains input exposure data, scripts for the preparatin of the exposure input to OQ.
33+
- `vulnerability/`: Script and outputs for vulnerability model.
34+
- `hazard/`: Includes scripts for hazard file preparation, needs the input files - event_id, dask files with hazard info, site info with the location of hazard.
35+
- `loss/`: Includes files,scripts for OQ risk calculcations - job.ini, hazard as hdf5, xml and csv files for exposure and vul inputs.
36+
- `results/`: Stores the output results from the risk calculations extracted using ipynb notebooks.
37+
- `plots/`: Jupyter notebooks for analysis and visualization of the results.
38+
39+
40+
## Command to run the OQ risk calculation
41+
42+
```sh
43+
conda activate oq
44+
oq engine --run job_hdf5_simulation.ini
45+
```
46+
47+
## Requirements
48+
49+
- OpenQuake with some edits to the source code for ebr analysis - see repo: https://github.com/naveenragur/OQ-Tsunami.git
50+
- Python 3.11
51+
- Jupyter Notebook or ipython
52+
53+
## Installation
54+
55+
To install the required dependencies, check yml file:
56+
- ML4SicilyTsunami/configs/oq.yml
57+
58+
## Contributing
59+
60+
Contributions are welcome! Please submit a pull request or open an issue to discuss any changes.
61+

0 commit comments

Comments
 (0)