extremitypathfinder icon indicating copy to clipboard operation
extremitypathfinder copied to clipboard

Allow empty boundary polygon

Open jannikmi opened this issue 10 months ago • 6 comments

In some scenarios there might not be explicit boundaries. Allow the boundary polygon parameter to be None.

Note: If the boundary polygon is None, there must be holes given

Quick workaround: take a simple recangle containing all given holes.

jannikmi avatar Apr 18 '24 08:04 jannikmi

Hey do you have some specific opinions regarding this?

Sherwin-14 avatar Apr 18 '24 14:04 Sherwin-14

Not really. You are welcome to contribute!

jannikmi avatar Apr 18 '24 15:04 jannikmi

I'll start working on this.;).

Sherwin-14 avatar Apr 18 '24 15:04 Sherwin-14

Great! You can open a (draft) pull request to keep track of the progress. I will support with code review and guidance.

jannikmi avatar Apr 19 '24 11:04 jannikmi

@jannikmi, Hey I had been working on this and I have been trying to solve this issue using the following process:

  1. We check if the boundary coordinates are None for a particular case, if they are None then we populate the boundary coordinates array with values present in list_of_holes.

  2. Once we do the above, we then send all of this information to the plotting function which takes care of plotting the rectangle that would be made using these boundary coordinates.

Is this approach feasible to you? I am asking this since I have been running into some errors and I think it maybe down to the approach that I am using? Would appreciate your take on this .

Sherwin-14 avatar Apr 22 '24 14:04 Sherwin-14

Could you please open a PR with you changes. Then I can advise

jannikmi avatar Apr 22 '24 15:04 jannikmi