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

Fixes in CGMES export #2574

Merged
merged 41 commits into from
May 31, 2023
Merged

Fixes in CGMES export #2574

merged 41 commits into from
May 31, 2023

Conversation

colinepiloquet
Copy link
Member

@colinepiloquet colinepiloquet commented May 17, 2023

Please check if the PR fulfills these requirements

  • The commit message follows our guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)

Does this PR already have an issue describing the problem?
No

What kind of change does this PR introduce?
Fixes related to SUV

What is the new behavior (if this is a feature change)?

  • Remove regulation status from EQ
  • Double dependency to SSH is removed in SV
  • Dependency to TPBD is added to SV
  • ReactiveCapabilityCurve CurveStyle changed from ConstantYValue to StraightLineYValues
  • default value for exportPowerFlowsForSwitches is true
  • Add LoadArea and subload area in load groups
  • Add custom modeling authority set
  • Add energyArea in controlArea
  • Format maximum double values using scientific notation.
  • TopologicalIslandId needs to be maximum 32 characters
  • Terminals must have a name
  • RatedS for PowerTransformers and RotatingMachine must be written and cannot be equal to 0, so it is set to 100 for PowerTransformerEnd but as optional for SynchronousMachine we do nothing (it should be done at iidm level).
  • Fix terminals and busbar sections have the same ID
  • switch retained and connected to same bus on both side are ignored (I am not sure anymore why we have to do that)
  • GeneratingUnit.maxP cannot be equal to 0.
  • add interpolation if ReactiveCapabilityCurve has only 2 points -> TODO at IIDM level
  • export all SvPowerFlow for switches
  • write TieFlow for Boundary
  • Return non conform load by default if the extension LoadDetail is not null
  • minOperatingP and maxOperatingP takes 0 in the interval (for the interpolation)
  • fix kind synchronous machine so that it fits the mode in SSH

Does this PR introduce a breaking change or deprecate an API?

  • The Breaking Change or Deprecated label has been added
  • The migration guide has been updated in the github wiki (What changes might users need to make in their application due to this PR?)

Other information:

@@ -150,13 +156,17 @@ public static void writeStartId(String className, String id, boolean writeMaster
}
}

public static void writeStartIdName(String className, String id, String name, String cimNamespace, XMLStreamWriter writer, CgmesExportContext context) throws XMLStreamException {
writeStartId(className, id, true, cimNamespace, writer, context);
public static void writeStartIdName(String className, String id, String name, boolean writeMasterResourceId, String cimNamespace, XMLStreamWriter writer, CgmesExportContext context) throws XMLStreamException {
Copy link
Member Author

Choose a reason for hiding this comment

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

I am not sure this is useful anymore.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…d dependency to TPDB in SV

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>

Default value for exportFlowsForSwitches is true.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…and positive - test to be done.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…pabilityCurve if minQ = maxQ + write kind corresponding to curve in SynchronousMachine EQ and SSH - to refactor.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…o do.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…defined and positive - test to be done."

This reverts commit d70f8f3.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
This reverts commit a341214.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…activeCapabilityCurve if minQ = maxQ + write kind corresponding to curve in SynchronousMachine EQ and SSH - to refactor."

This reverts commit fce6799.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
This reverts commit 9fccf09.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…- test to do."

This reverts commit 1f24b03.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
This reverts commit 0eaffe3.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
@colinepiloquet colinepiloquet force-pushed the fixes_cgmes_export branch 2 times, most recently from b7bb52a to 3c99bce Compare May 24, 2023 15:12
@annetill annetill changed the title [WIP] Fix CGMES export. Fixes in CGMES export May 25, 2023
@annetill annetill marked this pull request as ready for review May 25, 2023 11:59
@miovd miovd requested a review from zamarrenolm May 25, 2023 12:44
@miovd
Copy link
Contributor

miovd commented May 25, 2023

RatedS for PowerTransformers and RotatingMachine must be written and cannot be equal to 0,so it is set to Double.MAX_VALUE
GeneratingUnit.maxP cannot be equal to 0, so it is set to Double.MAX_VALUE

For these, default values must be debated @annetill @zamarrenolm

write positive minP and maxP for SynchronousMachine

Not sure this should be kept... @colinepiloquet can you make test just without this fix?

annetill and others added 2 commits May 25, 2023 15:13
Signed-off-by: Anne Tilloy <anne.tilloy@rte-france.com>
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
@zamarrenolm
Copy link
Member

RatedS for PowerTransformers and RotatingMachine must be written and cannot be equal to 0,so it is set to Double.MAX_VALUE

For power transformers, ratedS is not read during CGMES import. It could be read.
For rotating machines, it is an optional attribute both in CGMES 2 and 3. Maybe the validation rules have additional constraints over the standard?.
Maybe we can think of a default value that is not so extreme.

GeneratingUnit.maxP cannot be equal to 0, so it is set to Double.MAX_VALUE

For these, default values must be debated @annetill @zamarrenolm

write positive minP and maxP for SynchronousMachine

Not sure this should be kept... @colinepiloquet can you make test just without this fix?

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
@zamarrenolm
Copy link
Member

RatedS for PowerTransformers and RotatingMachine must be written and cannot be equal to 0,so it is set to Double.MAX_VALUE

For power transformers, ratedS is not read during CGMES import. It could be read. For rotating machines, it is an optional attribute both in CGMES 2 and 3. Maybe the validation rules have additional constraints over the standard?. Maybe we can think of a default value that is not so extreme.

GeneratingUnit.maxP cannot be equal to 0, so it is set to Double.MAX_VALUE

For these, default values must be debated @annetill @zamarrenolm

write positive minP and maxP for SynchronousMachine

Not sure this should be kept... @colinepiloquet can you make test just without this fix?

To obtain a reasonable default value for the ratedS of rotating machines, we could obtain the maximum absolute value of P and Q for the generator (eventually using points from reactive capability curve) and multiply it by a reasonability factor (10), like it is described in the rule SMRatedSunrealistic of the ENTSO-E document about quality of CGMES dataset calculations (v3.3).

colinepiloquet and others added 7 commits May 30, 2023 10:23
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
…d, by default to 100 - test to be enhanced.

Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Anne Tilloy <anne.tilloy@rte-france.com>
Signed-off-by: Luma <zamarrenolm@aia.es>
Signed-off-by: Anne Tilloy <anne.tilloy@rte-france.com>
zamarrenolm and others added 5 commits May 31, 2023 11:58
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 4 Code Smells

85.1% 85.1% Coverage
0.0% 0.0% Duplication

@annetill annetill merged commit 3ac1b87 into main May 31, 2023
@annetill annetill deleted the fixes_cgmes_export branch May 31, 2023 12:32
flo-dup pushed a commit that referenced this pull request May 31, 2023
Signed-off-by: Coline PILOQUET <coline.piloquet@rte-france.com>
Signed-off-by: Luma <zamarrenolm@aia.es>
Signed-off-by: Anne Tilloy <anne.tilloy@rte-france.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants