Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement HOGER homogenization #240

Merged
merged 31 commits into from
Dec 2, 2024
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/deploy-pages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ jobs:
- name: Copy examples to docs
working-directory: ${{runner.workspace}}/flasc/
run: |
rsync -av --mkpath examples_artificial_data/01_raw_data_processing/ docs/examples/01_raw_data_processing
rsync -av --mkpath examples_artificial_data/03_energy_ratio/ docs/examples/03_energy_ratio
rsync -av --mkpath examples_artificial_data/floris_input_artificial/ docs/examples/floris_input_artificial
ls docs/examples
Expand Down
6 changes: 4 additions & 2 deletions docs/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,12 @@ parts:
# - file: contributing
# - file: development
# - file: testing
- caption: Examples Data Processing
chapters:
- file: examples/01_raw_data_processing/03_northing_calibration_hoger

- caption: Examples
- caption: Examples Energy Ratio
chapters:
# - file: flascdataframe
- file: examples/03_energy_ratio/00_demo_energy_ratio_syntax
- file: examples/03_energy_ratio/01_demo_energy_ratio_options

Expand Down
misi9170 marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,9 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 46,
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"/opt/anaconda3/envs/flasc-reqs/lib/python3.10/site-packages/pandas/core/computation/expressions.py:21: UserWarning: Pandas requires version '2.8.4' or newer of 'numexpr' (version '2.8.3' currently installed).\n",
" from pandas.core.computation.check import NUMEXPR_INSTALLED\n"
]
}
],
"outputs": [],
"source": [
"# from datetime import timedelta as td\n",
"import os\n",
Expand Down Expand Up @@ -49,7 +40,7 @@
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 47,
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -69,7 +60,7 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 48,
"metadata": {},
"outputs": [],
"source": [
Expand Down Expand Up @@ -104,9 +95,21 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 49,
"metadata": {},
"outputs": [],
"outputs": [
{
"ename": "UserWarning",
"evalue": "Please run '00_setup_floris_model/02_precalculate_floris_solutions.py' for the appropriate wake models first.",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mUserWarning\u001b[0m Traceback (most recent call last)",
"Cell \u001b[0;32mIn[49], line 13\u001b[0m\n\u001b[1;32m 11\u001b[0m df_fm_approx \u001b[38;5;241m=\u001b[39m pd\u001b[38;5;241m.\u001b[39mread_feather(fn_approx)\n\u001b[1;32m 12\u001b[0m \u001b[38;5;28;01melse\u001b[39;00m:\n\u001b[0;32m---> 13\u001b[0m \u001b[38;5;28;01mraise\u001b[39;00m \u001b[38;5;167;01mUserWarning\u001b[39;00m(\n\u001b[1;32m 14\u001b[0m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;124mPlease run \u001b[39m\u001b[38;5;124m'\u001b[39m\u001b[38;5;124m00_setup_floris_model/02_precalculate_floris_solutions.py\u001b[39m\u001b[38;5;124m'\u001b[39m\u001b[38;5;124m \u001b[39m\u001b[38;5;124m\"\u001b[39m\n\u001b[1;32m 15\u001b[0m \u001b[38;5;124m\"\u001b[39m\u001b[38;5;124mfor the appropriate wake models first.\u001b[39m\u001b[38;5;124m\"\u001b[39m\n\u001b[1;32m 16\u001b[0m )\n",
"\u001b[0;31mUserWarning\u001b[0m: Please run '00_setup_floris_model/02_precalculate_floris_solutions.py' for the appropriate wake models first."
]
}
],
"source": [
"# Now we calculate a grid of FLORIS solutions. Since our estimated SCADA\n",
"# data changes as we shift its wind direction, the predicted solutions\n",
Expand Down Expand Up @@ -137,7 +140,7 @@
},
{
"cell_type": "code",
"execution_count": 5,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -239,7 +242,7 @@
},
{
"cell_type": "code",
"execution_count": 6,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -1316,7 +1319,7 @@
},
{
"cell_type": "code",
"execution_count": 7,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -2926,7 +2929,7 @@
},
{
"cell_type": "code",
"execution_count": 8,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -2979,7 +2982,7 @@
},
{
"cell_type": "code",
"execution_count": 9,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -3087,7 +3090,7 @@
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": null,
"metadata": {},
"outputs": [
{
Expand All @@ -3111,7 +3114,7 @@
},
{
"cell_type": "code",
"execution_count": 11,
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
Expand Down
Copy link
Collaborator

@misi9170 misi9170 Nov 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All of the examples here use a wind direction that is steadily ramping (with a very small amount of noise added). How difficult/feasible would it to be to move to a more "reasonable" wind direction signal (e.g., a Gaussian wind direction with a standard deviation of, say, 10 degrees and a non-zero mean to provide bias)? I think that could also help make the jump clearer.

It could also be interesting to compare the northing calibration procedure before and after the jump is detected by HOGER; i.e., demonstrate that the northing calibration doesn't work well if there is a jump in the bias

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can for sure change over the yaw from ramping to fixed. That's no problem. Running the calibration procedure twice could be instructive, but at the cost of a much longer notebook, since it generates a lot of text and plots, so I'd vote against that step

Large diffs are not rendered by default.

Loading
Loading