Skip to content

Conversation

@awirb
Copy link
Contributor

@awirb awirb commented Dec 22, 2025

In the aimec analysis a new coordinate system is defined along the thalweg (avaDir/Inputs/LINES/path_aimec.shp). If the provided line has to much curvature, this can introduce overlapping parts (with respect to the original data in cartesian coordinates) in the new coordinate system.

In this PR, introduce two checks:

  1. if domain boundaries (left and right of the thalweg) are selfintersecting lines -> Error
  2. if any of the new coordinate lines (parallel to the thalweg that form new coordinate system) in x, y coordinates intersect -> Error

The second check would also cover errors of the first check, however it saves computational time if the first check already fails.

@awirb awirb requested a review from fso42 December 22, 2025 13:26
@awirb awirb self-assigned this Dec 22, 2025
@awirb awirb added the enhancement New feature or request label Dec 22, 2025
@qltysh
Copy link
Contributor

qltysh bot commented Dec 22, 2025

All good ✅

@qltysh
Copy link
Contributor

qltysh bot commented Dec 22, 2025

Qlty

Coverage Impact

⬆️ Merging this pull request will increase total coverage on master by 0.06%.

Modified Files with Diff Coverage (2)

RatingFile% DiffUncovered Line #s
Coverage rating: B Coverage rating: B
avaframe/ana3AIMEC/aimecTools.py100.0%
Coverage rating: A Coverage rating: A
avaframe/in3Utils/geoTrans.py78.6%2125-2127
Total91.2%
🤖 Increase coverage with AI coding...

In the `checkAimecDomain` branch, add test coverage for this new code:

- `avaframe/in3Utils/geoTrans.py` -- Line 2125-2127

🚦 See full report on Qlty Cloud »

🛟 Help
  • Diff Coverage: Coverage for added or modified lines of code (excludes deleted files). Learn more.

  • Total Coverage: Coverage for the whole repository, calculated as the sum of all File Coverage. Learn more.

  • File Coverage: Covered Lines divided by Covered Lines plus Missed Lines. (Excludes non-executable lines including blank lines and comments.)

    • Indirect Changes: Changes to File Coverage for files that were not modified in this PR. Learn more.

@awirb awirb requested a review from fso42 December 23, 2025 07:56
@awirb awirb assigned fso42 and unassigned fso42 and awirb Dec 23, 2025
@fso42 fso42 changed the title add check for aimec new coordinate system [ana3;in3] add check for aimec new coordinate system Dec 23, 2025
remove unused imports

add pytest

remove unused return variable
@fso42 fso42 assigned awirb and unassigned fso42 Dec 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants