Skip to content

Conversation

@cfrontin
Copy link
Collaborator

@cfrontin cfrontin commented Jan 7, 2026

Adds exclusion zones that mirror boundaries using the windIO setup.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds support for domain exclusion zones in wind farm layouts through the windIO configuration system. The implementation mirrors the existing boundary distance handling and provides a new component for calculating distances between turbines and exclusion zones.

Key Changes:

  • New FarmExclusionDistancePolygon OpenMDAO component for computing turbine-to-exclusion-zone distances
  • Comprehensive test suite for single and multi-polygon exclusion zones including derivative validation
  • Visualization support for rendering exclusion zones in layout plots

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
ard/layout/exclusions.py New OpenMDAO component implementing polygon exclusion zone distance calculations with automatic differentiation via JAX
test/ard/unit/layout/test_exclusion.py Comprehensive test suite validating exclusion distance computation and derivatives for single and multiple polygon scenarios
test/ard/unit/layout/test_boundary.py Cleanup of unused imports and variables that were likely used during development
ard/viz/layout.py Extended plotting functionality to render exclusion zones as semi-transparent red polygons

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

@jaredthomas68 jaredthomas68 left a comment

Choose a reason for hiding this comment

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

Minor comments, not really blocking. I did not math check your tests, but I assume you did.

"exclusions": {
"polygons": [
{
"x": [0.0, 1000.0, 1000.0, 0.0],
Copy link
Contributor

Choose a reason for hiding this comment

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

I would prefer to see this test use a case closer to the expected use case. In this test, all turbines are inside the exclusion zone. Could you make the exclusion zone smaller, with maybe just one turbine inside and at least one turbine right on the boundary and other turbines outside?

Copy link
Contributor

Choose a reason for hiding this comment

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

all these tests, not just this one

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

tests updated in 44c1b37. failing one in a way I can't explain.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants