forked from DOI-USGS/ISIS3
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Corrected invalid geometry problems in isisminer. Addresses DOI-USGS#…
…5612. * GisGeometry was throwing an exception when isValid() was called and the geometry was indeed invalid * GisGeometry - added buffer() method * Strategy was updated to better manage geometries * Strategy - Added RepairInvalidGeometry and InvalidGeometryAction to allow better user control over invalid geometries * Strategy - Apply buffer(0) algorithm when an invalid geometry is detected * Strategy - Added more debug output * isisminer - improved handling of invalid/bad geometries * isisminer - Documented new parameters RepairInvalidGeometry and InvalidGeometryAction and updated Calculator strategy documentation
- Loading branch information
1 parent
cc8261f
commit 1dffcbc
Showing
5 changed files
with
792 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- $Id: isisminer.xml 6513 2016-01-14 23:04:44Z [email protected] $ --> | ||
<application name="isisminer" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://isis.astrogeology.usgs.gov/Schemas/Application/application.xsd"> | ||
<!-- <application name="isisminer" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://isis.astrogeology.usgs.gov/Schemas/Application/application.xsd"> --> | ||
<application name="isisminer" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="/usgs/pkgs/isis3/isis/doc/Schemas/Application/application.xsd"> | ||
|
||
<brief> | ||
Run a series of algorithms (Strategies) that perform various operations on input | ||
|
@@ -340,6 +341,40 @@ | |
as these strings can be quite large. | ||
</TD> | ||
</TR> | ||
<TR> | ||
<TD>RepairInvalidGeometry</TD> | ||
<TD>Optional</TD> | ||
<TD> | ||
There are times when invalid geometries will be passed into <b>isisminer</b>. | ||
One of the most common invalid geometries encountered is self-intersecting | ||
geometries. <b>footprintinit</b> will at times create self-intersecting geometries, | ||
usually when it uses the shape model in projecting/intersecting to ground, | ||
that are often read by <b>isisminer</b> as output from <b>caminfo</b>. | ||
These types of invalid geometries can | ||
be repaired by applying the GIS buffer algorithm with a width of 0. If an | ||
invalid geometry occurs in isisminer, and RepairInvalidGeometry = True, the | ||
buffer algorithm will be run to attempt to repair the geometry. The default | ||
value of this keyword is true so that invalid geometries will be repaired. | ||
See also InvalidGeometryAction. | ||
</TD> | ||
</TR> | ||
<TR> | ||
<TD>InvalidGeometryAction</TD> | ||
<TD>Optional</TD> | ||
<TD> | ||
This parameter determines the action taken when an invalid geometry occurs | ||
and is either not repaired (RepairInvalidGeometry = False) or could not be | ||
sucessfully repaired (RepairInvalidGeometry = True). The options are: | ||
continue, disable or error. For InvalidGeometryAction = continue, the state | ||
of the invalid geoemtry is retained in the Resource (some GIS operations | ||
still function) and it is not disabled and no error occurs - the issue is | ||
ignored. If InvalidGeometryAction = disable, then the geometry is retained | ||
in the Resource but the status is set to "discard". It can be re-enabled by | ||
using the ResourceManager strategy. If InvalidGeometryAction = error, then | ||
an error is thrown and <b>isisminer</b> terminates. The default is to | ||
disable the Resource. | ||
</TD> | ||
</TR> | ||
<TR> | ||
<TD>GisSimplifyTolerance</TD> | ||
<TD>Optional</TD> | ||
|
@@ -990,6 +1025,23 @@ EndObject | |
not already exist in the Resources. | ||
</TD> | ||
</TR> | ||
<TR> | ||
<TD>InitializersArgs</TD> | ||
<TD>Optional</TD> | ||
<TD> | ||
Using this parameter, users can list existing keywords in a Resource or | ||
from the global parameter pool in this keyword to create new variables | ||
in the Initializers group. This works by substituting ordered numerical index | ||
values specified as %1, %2, etc..., with a keyword value referenced by | ||
the index in the InitializersArgs array keyword. The InitializersArgs keyword | ||
should have the same number of keywords as %[index], where index is | ||
numbered from 1 to n, specified in the keywords found in the | ||
Initializers group. These initialzers should not involve equations as | ||
they are not resovled in this step. | ||
Note: This is the only way to create new keywords specificially in | ||
<b>isisminer</b>. | ||
</TD> | ||
</TR> | ||
<TR> | ||
<TD>Equation</TD> | ||
<TD>Optional</TD> | ||
|
@@ -4698,6 +4750,12 @@ End | |
Converted isisminer to callable function. Also converted all Makefile | ||
tests to gtest format. Moved some data from isis data area to | ||
"isis/tests/data/isisminer". | ||
<change name="Ken Edmundson" date="2024-09-12"> | ||
Originally implemented in UofA OSIRIS-REx code by Kris Becker, 2018-07-31. | ||
Corrected problems with invalid geometries aborting isisminer. Added two | ||
new parameters, RepairInvalidGeometry and InvalidGeometryAction, to allow user | ||
more control over how invalid geometries are managed. Update some of the | ||
documentation. | ||
</change> | ||
</history> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
APPNAME = isisminer | ||
|
||
include $(ISISROOT)/make/isismake.tsts | ||
|
||
commands: | ||
$(LS) $(INPUT)/*.pvl >& $(OUTPUT)/badgeomfix_data.lis; | ||
$(APPNAME) config=$(INPUT)/badgeomfix.conf \ | ||
parameters="fromlist:$(OUTPUT)/badgeomfix_data.lis@tocsv:$(OUTPUT)/badgeomfix.csv" > /dev/null | ||
$(RM) $(OUTPUT)/badgeomfix_data.lis; | ||
|
Oops, something went wrong.