Skip to content

Commit

Permalink
Refactor dependencies and remove unused code
Browse files Browse the repository at this point in the history
- Updated dependencies in pyproject.toml
- Added hvplot, pyarrow, plotly, and plotly-express to dependencies
- Removed unused PowerAnalysis class in PowerAnalysis.py
- Commented out replace_nan_with_none methods in models.py
- Added find_peaks, find_temporal_relative_peaks, and read_in_json_to_polars functions in main.py
  • Loading branch information
Molier committed Aug 27, 2024
1 parent 5b7ce61 commit 98d5124
Show file tree
Hide file tree
Showing 7 changed files with 1,345 additions and 254 deletions.
230 changes: 115 additions & 115 deletions data/capacity/capacity_output.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"2024-06-13T17:30:00+02:00",
"2024-07-02T11:00:00+02:00"
],
"name": null,
"name": "None",
"data": [
2.32,
3.596,
Expand All @@ -29,7 +29,7 @@
"2024-06-13T18:30:00+02:00",
"2024-06-13T18:45:00+02:00"
],
"name": null,
"name": "None",
"data": [
2.104,
0.9,
Expand All @@ -44,37 +44,6 @@
]
}
},
{
"peak_time": "2024-06-13T17:45:00+02:00",
"peak_value": 3.316,
"surrounding_data": {
"index": [
"2024-06-13T16:45:00+02:00",
"2024-06-13T17:00:00+02:00",
"2024-06-13T17:15:00+02:00",
"2024-06-13T17:30:00+02:00",
"2024-06-13T17:45:00+02:00",
"2024-06-13T18:00:00+02:00",
"2024-06-13T18:15:00+02:00",
"2024-06-13T18:30:00+02:00",
"2024-06-13T18:45:00+02:00",
"2024-06-13T19:00:00+02:00"
],
"name": null,
"data": [
0.9,
2.628,
1.352,
3.596,
3.316,
2.216,
1.412,
0.768,
0.544,
0.564
]
}
},
{
"peak_time": "2024-06-24T18:00:00+02:00",
"peak_value": 3.048,
Expand All @@ -91,7 +60,7 @@
"2024-06-24T19:00:00+02:00",
"2024-06-24T19:15:00+02:00"
],
"name": null,
"name": "None",
"data": [
0.628,
0.724,
Expand Down Expand Up @@ -122,7 +91,7 @@
"2024-06-06T01:15:00+02:00",
"2024-06-06T01:30:00+02:00"
],
"name": null,
"name": "None",
"data": [
1.324,
1.384,
Expand Down Expand Up @@ -153,7 +122,7 @@
"2024-07-02T12:00:00+02:00",
"2024-07-02T12:15:00+02:00"
],
"name": null,
"name": "None",
"data": [
0.508,
0.7,
Expand All @@ -168,37 +137,6 @@
]
}
},
{
"peak_time": "2024-06-13T17:00:00+02:00",
"peak_value": 2.628,
"surrounding_data": {
"index": [
"2024-06-13T16:00:00+02:00",
"2024-06-13T16:15:00+02:00",
"2024-06-13T16:30:00+02:00",
"2024-06-13T16:45:00+02:00",
"2024-06-13T17:00:00+02:00",
"2024-06-13T17:15:00+02:00",
"2024-06-13T17:30:00+02:00",
"2024-06-13T17:45:00+02:00",
"2024-06-13T18:00:00+02:00",
"2024-06-13T18:15:00+02:00"
],
"name": null,
"data": [
0.728,
1.468,
2.104,
0.9,
2.628,
1.352,
3.596,
3.316,
2.216,
1.412
]
}
},
{
"peak_time": "2024-06-27T23:00:00+02:00",
"peak_value": 2.612,
Expand All @@ -215,7 +153,7 @@
"2024-06-28T00:00:00+02:00",
"2024-06-28T00:15:00+02:00"
],
"name": null,
"name": "None",
"data": [
0.74,
0.724,
Expand Down Expand Up @@ -246,7 +184,7 @@
"2024-06-02T20:15:00+02:00",
"2024-06-02T20:30:00+02:00"
],
"name": null,
"name": "None",
"data": [
0.872,
0.888,
Expand All @@ -262,64 +200,126 @@
}
},
{
"peak_time": "2024-07-02T11:15:00+02:00",
"peak_value": 2.56,
"peak_time": "2024-06-05T09:15:00+02:00",
"peak_value": 2.464,
"surrounding_data": {
"index": [
"2024-07-02T10:15:00+02:00",
"2024-07-02T10:30:00+02:00",
"2024-07-02T10:45:00+02:00",
"2024-07-02T11:00:00+02:00",
"2024-07-02T11:15:00+02:00",
"2024-07-02T11:30:00+02:00",
"2024-07-02T11:45:00+02:00",
"2024-07-02T12:00:00+02:00",
"2024-07-02T12:15:00+02:00",
"2024-07-02T12:30:00+02:00"
"2024-06-05T08:15:00+02:00",
"2024-06-05T08:30:00+02:00",
"2024-06-05T08:45:00+02:00",
"2024-06-05T09:00:00+02:00",
"2024-06-05T09:15:00+02:00",
"2024-06-05T09:30:00+02:00",
"2024-06-05T09:45:00+02:00",
"2024-06-05T10:00:00+02:00",
"2024-06-05T10:15:00+02:00",
"2024-06-05T10:30:00+02:00"
],
"name": null,
"name": "None",
"data": [
0.7,
0.564,
0.824,
2.852,
2.56,
2.216,
1.392,
0.604,
0.672,
0.62
0.612,
0.484,
0.444,
1.528,
2.464,
1.884,
0.864,
0.628,
0.552,
0.608
]
}
},
{
"peak_time": "2024-06-06T00:30:00+02:00",
"peak_value": 2.548,
"peak_time": "2024-06-07T10:30:00+02:00",
"peak_value": 2.46,
"surrounding_data": {
"index": [
"2024-06-05T23:30:00+02:00",
"2024-06-05T23:45:00+02:00",
"2024-06-06T00:00:00+02:00",
"2024-06-06T00:15:00+02:00",
"2024-06-06T00:30:00+02:00",
"2024-06-06T00:45:00+02:00",
"2024-06-06T01:00:00+02:00",
"2024-06-06T01:15:00+02:00",
"2024-06-06T01:30:00+02:00",
"2024-06-06T01:45:00+02:00"
"2024-06-07T09:30:00+02:00",
"2024-06-07T09:45:00+02:00",
"2024-06-07T10:00:00+02:00",
"2024-06-07T10:15:00+02:00",
"2024-06-07T10:30:00+02:00",
"2024-06-07T10:45:00+02:00",
"2024-06-07T11:00:00+02:00",
"2024-06-07T11:15:00+02:00",
"2024-06-07T11:30:00+02:00",
"2024-06-07T11:45:00+02:00"
],
"name": null,
"name": "None",
"data": [
1.384,
1.348,
1.696,
2.888,
2.548,
1.536,
0.512,
0.328,
0.32,
0.296
0.448,
0.304,
0.396,
0.864,
2.46,
1.092,
0.648,
0.548,
1.188,
1.836
]
}
},
{
"peak_time": "2024-06-29T18:00:00+02:00",
"peak_value": 2.456,
"surrounding_data": {
"index": [
"2024-06-29T17:00:00+02:00",
"2024-06-29T17:15:00+02:00",
"2024-06-29T17:30:00+02:00",
"2024-06-29T17:45:00+02:00",
"2024-06-29T18:00:00+02:00",
"2024-06-29T18:15:00+02:00",
"2024-06-29T18:30:00+02:00",
"2024-06-29T18:45:00+02:00",
"2024-06-29T19:00:00+02:00",
"2024-06-29T19:15:00+02:00"
],
"name": "None",
"data": [
0.64,
0.608,
0.6,
1.116,
2.456,
1.6,
1.644,
1.504,
0.832,
0.716
]
}
},
{
"peak_time": "2024-06-27T11:15:00+02:00",
"peak_value": 2.428,
"surrounding_data": {
"index": [
"2024-06-27T10:15:00+02:00",
"2024-06-27T10:30:00+02:00",
"2024-06-27T10:45:00+02:00",
"2024-06-27T11:00:00+02:00",
"2024-06-27T11:15:00+02:00",
"2024-06-27T11:30:00+02:00",
"2024-06-27T11:45:00+02:00",
"2024-06-27T12:00:00+02:00",
"2024-06-27T12:15:00+02:00",
"2024-06-27T12:30:00+02:00"
],
"name": "None",
"data": [
2.036,
1.04,
1.232,
0.804,
2.428,
0.796,
0.64,
0.552,
0.584,
0.584
]
}
}
Expand Down
802 changes: 724 additions & 78 deletions demo_capacity_analysis.ipynb

Large diffs are not rendered by default.

34 changes: 0 additions & 34 deletions openenergyid/capacity/PowerAnalysis.py

This file was deleted.

Loading

0 comments on commit 98d5124

Please sign in to comment.