Skip to content

Commit 562fc57

Browse files
committed
Updating Hatteras scripts, developed pipelines for road and island offset
1 parent 2d94299 commit 562fc57

File tree

601 files changed

+5944
-14428
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

601 files changed

+5944
-14428
lines changed

data/hatteras_init/Hatteras-CASCADE-parameters.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ GrowthParamStart: false
2020
HdDiffu: 0.75
2121
Ki: 7.5e-06
2222
Kr: 7.5e-05
23-
LShoreface: 524.1959986328857
23+
LShoreface: 524.6532522894681
2424
MHW: 0.46
2525
MaxShrubHeight: 5.3
2626
MaxUpSlope: 0.25
@@ -39,14 +39,14 @@ Sandbag_elevation: 1.9
3939
SeededRNG: true
4040
Seedmax: 1000.0
4141
Seedmin: 100.0
42-
ShorefaceToe: 1099.9999999999995
42+
ShorefaceToe: 1452.7454838709673
4343
ShrubEl_max: 2.3
4444
ShrubEl_min: 1.2
4545
Shrub_ON: 0
4646
SprayDist: 170
4747
StormSeries: []
4848
StormStart: 2
49-
TMAX: 20
49+
TMAX: 19
5050
TideAmp: 1.2
5151
TimeFruit: 5.0
5252
UprootLimit: -0.2
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
BarrierLength: 500
2+
BayDepth: 3.0
3+
BermEl: 1.9
4+
BurialLimit: 0.75
5+
C1: 8.8
6+
C2: 4.6
7+
Cbb_i: 0.85
8+
Cbb_r: 0.7
9+
Cx: 10.0
10+
DShoreface: 8.9
11+
Dmaxel: 3.4
12+
Dshrub: 2.75
13+
Dstart: 0.5
14+
DuneParamStart: true
15+
DuneRestart: 0.075
16+
DuneWidth: 20.0
17+
Female: 0.5
18+
GermRate: 0.6
19+
GrowthParamStart: false
20+
HdDiffu: 0.75
21+
Ki: 7.5e-06
22+
Kr: 7.5e-05
23+
LShoreface: 524.3969226015213
24+
MHW: 0.46
25+
MaxShrubHeight: 5.3
26+
MaxUpSlope: 0.25
27+
OWss_i: 2
28+
OWss_r: 1
29+
Qs_bb_min: 1
30+
Qs_min: 1.0
31+
Qshrub_max: 0.15
32+
RSLR_Constant: true
33+
RSLR_const: 0.0056
34+
Rat: 0.0
35+
Rin_i: 0.1
36+
Rin_r: 2.0
37+
SalineLimit: 5
38+
Sandbag_elevation: 1.9
39+
SeededRNG: true
40+
Seedmax: 1000.0
41+
Seedmin: 100.0
42+
ShorefaceToe: 1699.3199999999995
43+
ShrubEl_max: 2.3
44+
ShrubEl_min: 1.2
45+
Shrub_ON: 0
46+
SprayDist: 170
47+
StormSeries: []
48+
StormStart: 2
49+
TMAX: 20
50+
TideAmp: 1.2
51+
TimeFruit: 5.0
52+
UprootLimit: -0.2
53+
beta: 0.04
54+
disp_mu: -0.721891
55+
disp_sigma: 1.5
56+
dune_file: C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\buffer\sample_1_dune.npy
57+
elevation_file: C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\buffer\sample_1_topography.npy
58+
enable_sandbags: false
59+
growth_param_file: C:\Users\hanna\PycharmProjects\CASCADE\data\default_cascade_variables\growthparam_1000dam.npy
60+
k_sf: 19324.753176079226
61+
mm: 2.0
62+
nn: 0.5
63+
rmax: 0.95
64+
rmin: 0.55
65+
s_sf_eq: 0.01698590034494604
66+
sandbag_elevation: 1.8
67+
sandbag_need: false
68+
storm_file: C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\storms\hindcast_storms\storms_1978_1997.npy
69+
threshold_in: 0.25
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
import pandas as pd
2+
3+
# Input dune-line CSVs (raw, per-transect)
4+
dune1978 = pd.read_csv(
5+
r"C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\island_offset\1978\1978_duneline_offset_raw.csv"
6+
)
7+
dune1997 = pd.read_csv(
8+
r"C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\island_offset\1997\1997_duneline_offset_raw.csv"
9+
)
10+
11+
# ---- 1. Aggregate each year to one value per domain (mean ORIG_LEN) ----
12+
d78 = (
13+
dune1978
14+
.groupby("domain_id")["ORIG_LEN"]
15+
.mean()
16+
.reset_index()
17+
.rename(columns={"ORIG_LEN": "dune_1978_m"})
18+
)
19+
20+
d97 = (
21+
dune1997
22+
.groupby("domain_id")["ORIG_LEN"]
23+
.mean()
24+
.reset_index()
25+
.rename(columns={"ORIG_LEN": "dune_1997_m"})
26+
)
27+
28+
# ---- 2. Merge per-domain means on domain_id ----
29+
df = d78.merge(d97, on="domain_id", how="inner")
30+
31+
# ---- 3. Compute dune-line change (1997 - 1978) ----
32+
# NEW: positive = seaward / accretion, negative = landward / retreat
33+
df['dune_change_m'] = df['dune_1978_m'] - df['dune_1997_m']
34+
35+
36+
# ---- 4. Sort and save ----
37+
df = df.sort_values("domain_id")
38+
39+
outpath = (
40+
r"C:\Users\hanna\PycharmProjects\CASCADE\data\hatteras_init\duneline_change"
41+
r"\dune_change_1978_1997_by_domain.csv"
42+
)
43+
df.to_csv(outpath, index=False)
44+
45+
print("Saved dune-line change table to:", outpath)
46+
print(df.head())
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.
-528 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)