-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #332 from WISDEM/hackathon
Cleanup of ref turbine files
- Loading branch information
Showing
62 changed files
with
7,295 additions
and
7,680 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,41 @@ | ||
import os | ||
import requests | ||
''' | ||
""" | ||
Run this script to update geometry yamls based on WISDEM yamls | ||
''' | ||
""" | ||
|
||
def main(): | ||
|
||
wisdem_weis_map = { | ||
# relative to examples/ | ||
# WISDEM example input WEIS example | ||
"09_floating/nrel5mw-spar_oc3.yaml": "03_NREL5MW_OC3_spar/nrel5mw-spar_oc3.yaml", | ||
"09_floating/nrel5mw-semi_oc4.yaml": "04_NREL5MW_OC4_semi/nrel5mw-semi_oc4.yaml", | ||
"09_floating/IEA-15-240-RWT_VolturnUS-S.yaml": "06_IEA-15-240-RWT/IEA-15-240-RWT_VolturnUS-S.yaml", | ||
"02_reference_turbines/IEA-15-240-RWT.yaml": "06_IEA-15-240-RWT/IEA-15-240-RWT_Monopile.yaml", | ||
"02_reference_turbines/IEA-3p4-130-RWT.yaml": "05_IEA-3.4-130-RWT/IEA-3p4-130-RWT.yaml", | ||
"03_blade/BAR_USC.yaml": "08_OLAF/BAR_USC.yaml", | ||
} | ||
wisdem_ref_turbs = [ | ||
"09_floating/nrel5mw-spar_oc3.yaml", | ||
"09_floating/nrel5mw-semi_oc4.yaml", | ||
"09_floating/IEA-15-240-RWT_VolturnUS-S.yaml", | ||
"09_floating/IEA-22-280-RWT_Floater.yaml", | ||
"02_reference_turbines/IEA-10-198-RWT.yaml", | ||
"02_reference_turbines/IEA-15-240-RWT.yaml", | ||
"02_reference_turbines/IEA-22-280-RWT.yaml", | ||
"02_reference_turbines/IEA-3p4-130-RWT.yaml", | ||
"03_blade/BAR_USC.yaml", | ||
] | ||
|
||
example_dir = os.path.join(os.path.dirname(__file__),"..") | ||
setup_dir = os.path.dirname(__file__) | ||
|
||
for wisdem_ex, weis_ex in wisdem_weis_map.items(): | ||
for wisdem_ex in wisdem_ref_turbs: | ||
|
||
raw_url = f"https://raw.githubusercontent.com/WISDEM/WISDEM/master/examples/{wisdem_ex}" | ||
|
||
local_path = os.path.join(example_dir,weis_ex) | ||
fname = wisdem_ex.split('/')[-1] | ||
local_path = os.path.join(setup_dir, "ref_turbines", fname) | ||
|
||
# Download the file | ||
response = requests.get(raw_url) | ||
if response.status_code == 200: | ||
with open(local_path, 'wb') as f: | ||
with open(local_path, "wb") as f: | ||
f.write(response.content) | ||
print(f"Downloaded {raw_url} to {local_path}") | ||
else: | ||
print(f"Failed to download {raw_url}. Status code: {response.status_code}") | ||
|
||
|
||
if __name__=="__main__": | ||
main() | ||
main() |
File renamed without changes.
File renamed without changes.
Large diffs are not rendered by default.
Oops, something went wrong.
253 changes: 103 additions & 150 deletions
253
...A-15-240-RWT/IEA-15-240-RWT_Monopile.yaml → ...00_setup/ref_turbines/IEA-15-240-RWT.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
228 changes: 91 additions & 137 deletions
228
...5-240-RWT/IEA-15-240-RWT_VolturnUS-S.yaml → ..._turbines/IEA-15-240-RWT_VolturnUS-S.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
1,278 changes: 1,278 additions & 0 deletions
1,278
examples/00_setup/ref_turbines/IEA-15-240-RWT_VolturnUS-S_sparsetower.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
2,685 changes: 1,319 additions & 1,366 deletions
2,685
...IEA-15-240-RWT/IEA-15-floating_wTMDs.yaml → ...nes/IEA-15-240-RWT_VolturnUS-S_wTMDs.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
1,481 changes: 1,481 additions & 0 deletions
1,481
examples/00_setup/ref_turbines/IEA-22-280-RWT.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
1,711 changes: 1,711 additions & 0 deletions
1,711
examples/00_setup/ref_turbines/IEA-22-280-RWT_Floater.yaml
Large diffs are not rendered by default.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.