Skip to content

Commit

Permalink
Merge branch 'dev' into pp/#1012-chpmodelspec-and-cylindricalthermals…
Browse files Browse the repository at this point in the history
…toragespec-also-need-adaptions-for-storage-without-storagevolumelvlmin
  • Loading branch information
pierrepetersmeier authored Nov 27, 2024
2 parents fbf8c4b + e420a54 commit 75b1ac7
Show file tree
Hide file tree
Showing 24 changed files with 531 additions and 324 deletions.
20 changes: 17 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,29 @@ jobs:
with:
fetch-depth: 0

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4

- name: Check Branch
run: |
if [ "${{ github.event_name }}" == "pull_request" ]; then
branchName="${{ github.head_ref }}"
else
branchName="${{ github.ref_name }}"
fi
if [[ "$branchName" == refs/heads/* ]]; then
branchName="${branchName#refs/heads/}"
fi
./gradlew checkBranchName -PbranchName="$branchName"
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: 17

- name: Setup Gradle
uses: gradle/actions/setup-gradle@v4

- name: Build Project
run: ./gradlew --refresh-dependencies clean assemble spotlessCheck

Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Add some quote to 'printGoodbye' [#997](https://github.com/ie3-institute/simona/issues/997)
- Add unapply method for ThermalHouseResults [#934](https://github.com/ie3-institute/simona/issues/934)
- Added `ApparentPower` to differentiate between different power types [#794](https://github.com/ie3-institute/simona/issues/794)
- Update/enhance config documentation [#1013](https://github.com/ie3-institute/simona/issues/1013)
- Create `CITATION.cff` [#1035](https://github.com/ie3-institute/simona/issues/1035)
- Introduce ThermalDemandWrapper [#1049](https://github.com/ie3-institute/simona/issues/1049)

### Changed
- Adapted to changed data source in PSDM [#435](https://github.com/ie3-institute/simona/issues/435)
Expand Down Expand Up @@ -103,6 +106,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Refactor `ResultFileHierarchy` [#1031](https://github.com/ie3-institute/simona/issues/1031)
- Removing logs in `logs/simona` [#1017](https://github.com/ie3-institute/simona/issues/1017)
- Fix implausible test cases of HpModelSpec [#1042](https://github.com/ie3-institute/simona/issues/1042)
- Refactoring to only use 'lastHpState' and 'relevantData' for 'ThermalGrid' calculations [#916](https://github.com/ie3-institute/simona/issues/916)
- Refactor thermal calcRelevantData [#1051](https://github.com/ie3-institute/simona/issues/1051)

### Fixed
- Fix rendering of references in documentation [#505](https://github.com/ie3-institute/simona/issues/505)
Expand Down Expand Up @@ -142,6 +147,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fix some minor issues and findings from inspections [#1019](https://github.com/ie3-institute/simona/issues/1019)
- Fix initialisation freezing on empty primary data [#981](https://github.com/ie3-institute/simona/issues/981)
- Shallow fetch in CI [#1041](https://github.com/ie3-institute/simona/issues/1041)
- Correct wrong use of term "wall clock time" [#727](https://github.com/ie3-institute/simona/issues/727)

## [3.0.0] - 2023-08-07

Expand Down
41 changes: 41 additions & 0 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
cff-version: 1.2.0
title: SIMONA
message: "If you use this software, please cite it as below."
type: software
authors:
- family-names: Hiry
given-names: Johannes
orcid: https://orcid.org/0000-0002-1447-0607
- family-names: Kittl
given-names: Chris
orcid: https://orcid.org/0000-0002-1187-0568
- family-names: Sen Sarma
given-names: Debopama
orcid: https://orcid.org/0000-0003-3311-3020
- family-names: Oberließen
given-names: Thomas
orcid: https://orcid.org/0000-0001-5805-5408
- family-names: Peter
given-names: Sebastian
orcid: https://orcid.org/0000-0001-6311-6113
- family-names: Feismann
given-names: Daniel
orcid: https://orcid.org/0000-0002-3531-9025
- family-names: Bao
given-names: Johannes
orcid: https://orcid.org/0009-0008-3641-6469
- family-names: Hohmann
given-names: Julian
- family-names: Staudt
given-names: Marius
repository-code: https://github.com/ie3-institute/simona
url: https://simona.ie3.e-technik.tu-dortmund.de
repository-artifact: https://central.sonatype.com/artifact/com.github.ie3-institute/simona
keywords:
- agent-based
- discrete-event simulation
- powerflow
- electricity distribution grid
license: BSD-3-Clause
version: 3.0.0
date-released: 2023-08-07
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ apply from: scriptsLocation + 'scoverage.gradle' // scoverage scala code coverag
apply from: scriptsLocation + 'deploy.gradle'
apply from: scriptsLocation + 'semVer.gradle'
apply from: scriptsLocation + 'mavenCentralPublish.gradle'
apply from: scriptsLocation + 'branchName.gradle'

configurations {
scalaCompilerPlugin
Expand Down
14 changes: 7 additions & 7 deletions docs/readthedocs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,13 @@ To create the output directory name, the name of the simulation is used as a str
`simona.simulationName = "vn_simona"`

### Time parameters
Starting date and time of the simulation
- Format: "YYYY-MM-DD HH:MM:SS"
Starting date and time of the simulation in ISO-8601 date and time format with offset

`simona.time.startDateTime = "2011-01-01 00:00:00"`
`simona.time.startDateTime = "2011-01-01T00:00:00Z"`

Ending date and time of the simulation
- Format: "YYYY-MM-DD HH:MM:SS"
Ending date and time of the simulation in ISO-8601 date and time format with offset

`simona.time.endDateTime = "2011-01-01 02:00:00"`
`simona.time.endDateTime = "2011-01-01T02:00:00Z"`

The preset ReadyCheckWindow should be maintained

Expand All @@ -39,7 +37,9 @@ Setting of the data source

`simona.input.grid.datasource.id = "csv"`

Specify the folder path containing the csv data of the grid components and the csv separator (e.g. "," or ";")
Specify the folder path containing the csv data of the grid components and the csv separator (e.g. "," or ";").
The directory structure is determined by the boolean `isHierarchic`.
If files are placed within [a specific set of subdirectories](https://powersystemdatamodel.readthedocs.io/en/latest/io/csvfiles.html#default-directory-hierarchy), `isHierarchic: true` needs to be set.

```
simona.input.primary.csvParams = {
Expand Down
26 changes: 26 additions & 0 deletions gradle/scripts/branchName.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
tasks.register('checkBranchName') {
doLast {
if (!project.hasProperty('branchName')) {
throw new GradleException("Error: Missing required property 'branchName'.")
}

def branchName = project.property('branchName')

def patterns = [
~/^(developer|develop|dev)$/,
~/.*rel\/.*/,
~/^dependabot\/.*$/,
~/.*hotfix\/\pL{2}\/#\d+.*/,
~/.*main/,
~/^[a-z]{2}\/#[0-9]+(?:-.+)?$/
]

def isValid = patterns.any { pattern -> branchName ==~ pattern }

if (!isValid) {
throw new GradleException("Error: Check Branch name format (e.g., ps/#1337-FeatureName).")
}

println "Branch name is $branchName"
}
}
24 changes: 12 additions & 12 deletions src/main/scala/edu/ie3/simona/agent/grid/GridAgentController.scala
Original file line number Diff line number Diff line change
Expand Up @@ -455,9 +455,9 @@ class GridAgentController(
* @param primaryServiceProxy
* Reference to the primary data service proxy
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down Expand Up @@ -512,9 +512,9 @@ class GridAgentController(
* @param primaryServiceProxy
* Reference to the primary data service proxy
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down Expand Up @@ -571,9 +571,9 @@ class GridAgentController(
* @param weatherService
* Reference to the weather service actor
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down Expand Up @@ -631,9 +631,9 @@ class GridAgentController(
* @param evMovementsService
* Reference to the ev movements service actor
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down Expand Up @@ -749,9 +749,9 @@ class GridAgentController(
* @param weatherService
* Reference to the weather service actor
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down Expand Up @@ -807,9 +807,9 @@ class GridAgentController(
* @param primaryServiceProxy
* Reference to the primary data service proxy
* @param simulationStartDate
* First wall clock time in simulation
* The simulation time at which the simulation starts
* @param simulationEndDate
* Last wall clock time in simulation
* The simulation time at which the simulation ends
* @param resolution
* Frequency of power flow calculations
* @param requestVoltageDeviationThreshold
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ object GridResultsSupport {
/** Partial result for the port at the high voltage side
*
* @param time
* Wall clock time, the result does belong to
* Simulation time of the result
* @param input
* Unique identifier of the input model
* @param currentMagnitude
Expand All @@ -638,7 +638,7 @@ object GridResultsSupport {
/** Partial result for the port at the medium voltage side
*
* @param time
* Wall clock time, the result does belong to
* Simulation time of the result
* @param input
* Unique identifier of the input model
* @param currentMagnitude
Expand All @@ -656,7 +656,7 @@ object GridResultsSupport {
/** Partial result for the port at the low voltage side
*
* @param time
* Wall clock time, the result does belong to
* Simulation time of the result
* @param input
* Unique identifier of the input model
* @param currentMagnitude
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,9 @@ protected trait ParticipantAgentFundamentals[
* @param modelConfig
* Configuration for the model
* @param simulationStartDate
* Wall clock time of first instant in simulation
* Simulation time of first instant in simulation
* @param simulationEndDate
* Wall clock time of last instant in simulation
* Simulation time of last instant in simulation
* @return
*/
def buildModel(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -440,9 +440,9 @@ trait HpAgentFundamentals
* @param modelConfig
* Configuration for the model
* @param simulationStartDate
* Wall clock time of first instant in simulation
* Simulation time of first instant in simulation
* @param simulationEndDate
* Wall clock time of last instant in simulation
* Simulation time of last instant in simulation
* @return
*/
override def buildModel(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ trait BaseStateData[+PD <: PrimaryDataWithApparentPower[PD]]
*/
val startDate: ZonedDateTime

/** The wall clock date, at which the simulation ends
/** The simulation time at which the simulation ends
*/
val endDate: ZonedDateTime

Expand Down Expand Up @@ -132,7 +132,7 @@ object BaseStateData {
* @param startDate
* The date, that fits the tick 0
* @param endDate
* The wall clock date, at which the simulation ends
* The simulation time at which the simulation ends
* @param outputConfig
* Determines the output behaviour of this model
* @param additionalActivationTicks
Expand Down Expand Up @@ -179,7 +179,7 @@ object BaseStateData {
* @param startDate
* The date, that fits the tick 0
* @param endDate
* The wall clock date, at which the simulation ends
* The simulation time at which the simulation ends
* @param model
* Physical model of the load
* @param services
Expand Down
Loading

0 comments on commit 75b1ac7

Please sign in to comment.