-
Notifications
You must be signed in to change notification settings - Fork 7
add ground temperature 1m as option to weather data #1351
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
Open
pierrepetersmeier
wants to merge
47
commits into
dev
Choose a base branch
from
pp/#1343-add-ground-temperature-1m-as-option-to-weather-data
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
47 commits
Select commit
Hold shift + click to select a range
6bb6984
Add ground temperature (1m) as option to weather data.
pierrepetersmeier 0342ae2
Merge branch 'dev' into 1343-add-ground-temperature-1m-as-option-to-w…
pierrepetersmeier 920be80
Address review feedback and align test suite
pierrepetersmeier e259bee
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 1b8dd09
fixing the comments and tests.
pierrepetersmeier 6a77ffc
fmt
pierrepetersmeier d46b0d1
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 9f767ed
Meeting
pierrepetersmeier b015b66
Add GroundTemperatureValue and refactor WeatherValue, CosmoTimeBasedW…
pierrepetersmeier 8e33409
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier b0d87d9
Remove logger.warn
pierrepetersmeier 0399aa3
fmt
pierrepetersmeier 813cdbe
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 88191d1
fmt
pierrepetersmeier 47ac942
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 41302fe
fmt
pierrepetersmeier 3c153a3
Merge remote-tracking branch 'origin/pp/#1343-add-ground-temperature-…
pierrepetersmeier 83b3736
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 13f27ee
Merge remote-tracking branch 'origin/pp/#1343-add-ground-temperature-…
pierrepetersmeier 55a7c15
Add GroundTemperatureValue 0cm and 80cm.
pierrepetersmeier cde88f0
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier f0698b4
Fix SqlSinkTest
pierrepetersmeier 1d9ff09
fmt
pierrepetersmeier 4ec2c68
fmt
pierrepetersmeier f939e57
fmt
danielfeismann 55bb4e1
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
danielfeismann 71ab33a
Apply suggestion from @danielfeismann
pierrepetersmeier 224aa30
Update src/test/resources/edu/ie3/datamodel/io/source/csv/_weather/co…
pierrepetersmeier 6039cc2
Update src/test/resources/edu/ie3/datamodel/io/sink/_sql/time_series.sql
pierrepetersmeier 46fb11f
remove unused function
pierrepetersmeier 082451a
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 3a0e1e9
remove unused function and refactoring tests
pierrepetersmeier 57640e2
fmt
pierrepetersmeier 7f11669
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 1c5c4ba
InfluxDB
pierrepetersmeier 3be844f
TestData
pierrepetersmeier 3f04286
fmt
pierrepetersmeier c8f0d18
fmt
pierrepetersmeier c067c0b
fmt
pierrepetersmeier 64c0172
fmt
pierrepetersmeier d691a2c
Update src/main/java/edu/ie3/datamodel/models/value/WeatherValue.java
pierrepetersmeier e80cb33
Merge branch 'dev' into pp/#1343-add-ground-temperature-1m-as-option-…
pierrepetersmeier 42e8599
Optional
pierrepetersmeier ae9da09
FlatMap instead of Map. Optional in Tests.
pierrepetersmeier 481ab12
enhancing TimeSeriesProcessor
danielfeismann 5efc4d2
sonar
danielfeismann 41d031e
optinal empty
danielfeismann File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -33,6 +33,8 @@ public class IconTimeBasedWeatherValueFactory extends TimeBasedWeatherValueFacto | |
| private static final String TEMPERATURE = "t2m"; | ||
| private static final String WIND_VELOCITY_U = "u131m"; | ||
| private static final String WIND_VELOCITY_V = "v131m"; | ||
| private static final String GROUND_TEMPERATURE_VALUE_ONE = "t_v1"; | ||
| private static final String GROUND_TEMPERATURE_VALUE_TWO = "t_v2"; | ||
|
Comment on lines
+36
to
+37
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. how about tg_1, tg_2? |
||
|
|
||
| public IconTimeBasedWeatherValueFactory() { | ||
| super(); | ||
|
|
@@ -53,7 +55,8 @@ protected List<Set<String>> getFields(Class<?> entityClass) { | |
| "albrad", | ||
| "asobs", | ||
| "aswdifuS", | ||
| "tG", | ||
| "t_v1", | ||
| "t_v2", | ||
| "u10m", | ||
| "u20m", | ||
| "u216m", | ||
|
|
@@ -88,14 +91,21 @@ protected TimeBasedValue<WeatherValue> buildModel(TimeBasedWeatherValueData data | |
| data.getQuantity(TEMPERATURE, Units.KELVIN).to(StandardUnits.TEMPERATURE); | ||
| ComparableQuantity<Angle> windDirection = getWindDirection(data); | ||
| ComparableQuantity<Speed> windVelocity = getWindVelocity(data); | ||
| Optional<ComparableQuantity<Temperature>> groundTemperatureValueOne = | ||
| data.getQuantityOptional(GROUND_TEMPERATURE_VALUE_ONE, Units.KELVIN); | ||
| Optional<ComparableQuantity<Temperature>> groundTemperatureValueTwo = | ||
| data.getQuantityOptional(GROUND_TEMPERATURE_VALUE_TWO, Units.KELVIN); | ||
|
|
||
| WeatherValue weatherValue = | ||
| new WeatherValue( | ||
| coordinate, | ||
| directIrradiance, | ||
| diffuseIrradiance, | ||
| temperature, | ||
| windDirection, | ||
| windVelocity); | ||
| windVelocity, | ||
| groundTemperatureValueOne, | ||
| groundTemperatureValueTwo); | ||
| return new TimeBasedValue<>(time, weatherValue); | ||
| } | ||
|
|
||
|
|
||
This file contains hidden or 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 hidden or 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
30 changes: 30 additions & 0 deletions
30
src/main/java/edu/ie3/datamodel/models/value/GroundTemperatureValue.java
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| /* | ||
| * © 2025. TU Dortmund University, | ||
| * Institute of Energy Systems, Energy Efficiency and Energy Economics, | ||
| * Research group Distribution grid planning and operation | ||
| */ | ||
| package edu.ie3.datamodel.models.value; | ||
|
|
||
| import javax.measure.quantity.Temperature; | ||
| import tech.units.indriya.ComparableQuantity; | ||
|
|
||
| /** | ||
| * Describes a ground temperature value. This class extends {@link TemperatureValue} to represent | ||
| * temperature at a specific depth in the ground. | ||
| */ | ||
| public class GroundTemperatureValue extends TemperatureValue { | ||
|
|
||
| /** | ||
| * Constructs a new GroundTemperatureValue. | ||
| * | ||
| * @param temperature The temperature quantity (typically in K) | ||
| */ | ||
| public GroundTemperatureValue(ComparableQuantity<Temperature> temperature) { | ||
| super(temperature); | ||
| } | ||
|
|
||
| @Override | ||
| public String toString() { | ||
| return "GroundTemperatureValue{" + "temperature=" + getTemperature().orElse(null) + '}'; | ||
| } | ||
| } |
This file contains hidden or 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 hidden or 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 hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this need some update since know its possible to use different depths, right?