Skip to content

Commit

Permalink
Migrates subset of base data to appdata area in source. Fixes CI erro…
Browse files Browse the repository at this point in the history
…r. (#3731)

* Update meta.yaml to rename conda package to isis from isis3

* Used CK quality for PCK selection in spiceinit (#3716)

* Changed PCK to use CK quality in spiceinit

* Added spiceinit history for change

* Adds the ability to save and restore a greyscale stretch to/from a Cube (#3717)

* Update meta.yaml to rename conda package to isis from isis3

* Initial stretch attempt

* Now will write a single stretch with a name and type to the cube

* Stretch updated to inherit from Blob, re-loading a saved stretch works but only if Linear right now

* Clean up Stretch class

* Completely move stretchTypes into stretch class, and some minor cleanup

* Fixed combo-box not updating bug and more cleanup

* Further cleanup of propagated earlier changes with types and names being removed from unnecessary classes

* Removed added unneeded member variables from StretchType

* Cleanup StretchTool class

* Update enter-text dialogs to drop down selection options

* Wrapped some long strings

* Initial commit to address most of review comments

* Removed buttons in case of RGB stretch and add a 'Color' PvlKeyword to Stretch output

Co-authored-by: Stuart Sides <[email protected]>

* Updated kaguyatc2isis to allow ingestion of data provided by JAXA online archive (#3713)

* Updated to allow ingestion of data provided by JAXA online archive

* Listed SLN-L-TC-5-MORNING-MAP-V4.0 as a supported format.

* Added tests + testing data

* Replaced several label parsing tests with cube attribute tests.

* Fixes ddd2isis to support updated uvflat files (#3719)

* Fixes ddd2isis to support updated uvflat files

* Added history comment

* Changed version numbers for 4.1 RC (#3722)

* Add directory structure for appdata in source

* Update cmakelists to copy translation files over into the appdata/translations area in the build directory.

* Update to install appdata

* Add appdata/templates directory needed for apollo work.

* Migrates everything in maps, labels, and and autoreg into source, adds placeholders for cmake for images and templates, and adds two actual base translation files and associated changes

* Actually address all merge conflicts

* Add placeholder for serialnumbers

Co-authored-by: Jesse Mapel <[email protected]>
Co-authored-by: Stuart Sides <[email protected]>
Co-authored-by: AustinSanders <[email protected]>
Co-authored-by: acpaquette <[email protected]>
  • Loading branch information
5 people authored Mar 5, 2020
1 parent de8cd58 commit 7b6ac6b
Show file tree
Hide file tree
Showing 39 changed files with 2,039 additions and 5 deletions.
33 changes: 32 additions & 1 deletion isis/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -452,6 +452,11 @@ execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/inc)
# Create the appdata directory and translations directory
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/translations)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/templates)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/maps)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/images/icons)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/images/targets)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/labels)
execute_process(COMMAND mkdir -p ${CMAKE_BINARY_DIR}/appdata/autoreg)

# Create an xml folder in the source directory that we will need later
set(sourceXmlFolder ${CMAKE_BINARY_DIR}/bin/xml)
Expand Down Expand Up @@ -500,7 +505,8 @@ add_dependencies(isis3 incs)
# Add custom build target to copy modified translation files to the build/appdata/translations
# directory. (As above - may need to be updated)
add_custom_target(appdata ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/serialnumbers/*.trn ${CMAKE_SOURCE_DIR}/src/*/apps/*/*.trn
${CMAKE_SOURCE_DIR}/appdata/serialnumbers/*.trn ${CMAKE_SOURCE_DIR}/appdata/translations/*.trn
${CMAKE_SOURCE_DIR}/src/*/apps/*/*.trn
${CMAKE_BINARY_DIR}/appdata/translations)
add_dependencies(isis3 appdata)

Expand All @@ -510,6 +516,31 @@ add_custom_target(templates ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/templates/*.pvl ${CMAKE_BINARY_DIR}/appdata/templates)
add_dependencies(isis3 templates)

# Either add these for maps, labels, autoreg, images or approach in a different way.

# Add custom build target to copy modified template files to the build/appdata/templates
# directory. (As above - may need to be updated)

add_custom_target(icons ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/images/icons/* ${CMAKE_BINARY_DIR}/appdata/images/icons)
add_dependencies(isis3 icons)

add_custom_target(targets ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/images/targets/* ${CMAKE_BINARY_DIR}/appdata/images/targets)
add_dependencies(isis3 targets)

add_custom_target(maps ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/maps/*.map ${CMAKE_BINARY_DIR}/appdata/maps)
add_dependencies(isis3 maps)

add_custom_target(labels ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/labels/*.pft ${CMAKE_BINARY_DIR}/appdata/labels)
add_dependencies(isis3 labels)

add_custom_target(autoreg ALL COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_SOURCE_DIR}/appdata/autoreg/*.def ${CMAKE_BINARY_DIR}/appdata/autoreg)
add_dependencies(isis3 autoreg)

# Add a custom build target to clean out everything that gets added to the source
# directory during the build process.
# - Only a few things are added in order to make the tests work properly so
Expand Down
256 changes: 256 additions & 0 deletions isis/appdata/autoreg/coreg.adaptgruen.p1515s3030.def
Original file line number Diff line number Diff line change
@@ -0,0 +1,256 @@
Object = AutoRegistration
Group = Algorithm
# This is the adaptive gruen algorithm, which provides adaptive image
# (chip) registration using an Affine transform to iteratively adjust
# the search chip at each iteration. Each iteration solves for new
# adjustments to the Affine transform until the 6 affine parameters
# fall below the tolerances as specified by the following parameters.
#REQUIRED
Name = AdaptiveGruen

# The tolerance for the goodness-of-fit. For the
# AdaptiveGruen algorithm, the goodness-of-fit value must
# be less than Tolerance before the algorithm is considered
# to have converged to a user-acceptable solution.
#Possible Values: [0,infinity)
#REQUIRED
Tolerance = 0.1

# The Maximum number of iterations the algorithm is allowed to perform
# in an attempt to converge before failing and returning no registration.
#Possible Values: [1,infinity), integer
#REQUIRED
MaximumIterations = 30

# The AffineTolerance specifies the amount of offset in pixels an affine
# derived point is allowed to deviate from the orginal match point.
#Possible Values: [0,infinity)
#OPTIONAL
AffineTolerance = 5.0

# The AffineTranslationTolerance specifies the threshold convergence value
# of the affine translation shift in line/sample between each Gruen match
# iteration. If the amount of affine translation computed in the Gruen
# algorithm is less than the AffineTranslationTolerance, that point is
# deemed a match point for the purposes of the translation portion of the
# registered point.
#Possible Values: [0,infinity)
#OPTIONAL
AffineTranslationTolerance = 0.2

# The AffineScaleTolerance specifies the threshold convergence value of the
# affine scale in line/sample between each Gruen match iteration. If the
# amount of the affine translation computed in the Gruen algorithm is
# less than the AffineScaleTolerance, that point is deemed a match point
# for the purposes of the scaling portion of the registered point.
#Possible Values: [0,infinity)
#OPTIONAL
AffineScaleTolerance = 0.7

# The AffineShearTolerance specifies the threshold convergence value of the
# affine scale in line/sample between each Gruen match iteration. If the
# amount of the affine translation computed in the Gruen algorithm is
# less than the AffineShearTolerance, that point is deemed a match point
# for the purposes of the shear portion of the registered point.
#Possible Values: [0,infinity)
#OPTIONAL
#AffineShearTolerance = 0.7

#The SpiceTolerance defines the amount of offset in pixels a registration
# is allowed to deviate from a registered point.
#Possible Values: [0,infinity)
#OPTIONAL
#SpiceTolerance = 7.0

#The RadioShiftTolerance specifies the threshold convergence value for the
# radiometric shift of the pixel value between each Gruen match iteration.
# If the amount of the radiometric shift computed in the Gruen algorithm is
# less than the RadioShiftTolerance, that point is deemed a match point
# for the purposes of the radiometric shift portion of the registered point.
# This tolerance value depends heavily on the radiometric properties of
# your images.
#Possible Values: (-infinity,infinity)
#OPTIONAL
#RadioShiftTolerance = 256

#The RadioGainMinTolerance specifies the minimum value for the
# radiometric gain of the pixel value between each Gruen match iteration.
# If the amount of the radiometric gain computed in the Gruen algorithm is
# greater than the RadioGainMinTolerance and is less than
# RadioGainMaxTolerance, that point is deemed a match point for the
# purposes of the radiometric gain portion of the registered point.
# This tolerance value depends heavily on the radiometric properties of
# your images.
#Possible Values: (-infinity,infinity)
#OPTIONAL
#RadioGainMinTolerance = -0.75

#The RadioGainMaxTolerance specifies the maximum value for the
# radiometric gain of the pixel value between each Gruen match iteration.
# If the amount of the radiometric gain computed in the Gruen algorithm is
# greater than the RadioGainMinTolerance and is less than
# RadioGainMaxTolerance, that point is deemed a match point for the
# purposes of the radiometric gain portion of the registered point.
# This tolerance value depends heavily on the radiometric properties of
# your images.
#Possible Values: (-infinity,infinity)
#OPTIONAL
#RadioGainMaxTolerance = 3.0

#FitChipScale = 0.1

#The DefaultRadioShift sets the default value for the radiometric shift
# value used as a starting point in the Gruen algorithm.
#Possible Values: (-infinity,infinity)
#OPTIONAL
#DefaultRadioShift = 0.0

#The DefaultRadioGain sets the default value for the radiometric gain
# value used as a starting point in the Gruen algorithm.
#Possible Values: (-infinity,infinity)
#OPTIONAL
#DefaultRadioGain = 0.0

# Calculate the registration to subpixel accuracy. This is a
# boolean (True or False).
#Possible Values: {True, False}
#OPTIONAL
#SubPixelAccuracy = True

# Reduce the size of of the Pattern and Search chips by a
# the ReductionFactor for a first-run through the data
# to find a low-accuracy match. Then focus the
# full-accuracy match to the surrounding area.
#Possible Values: Natural Numbers
#OPTIONAL
#ReductionFactor = 1

# Apply a Sobel gradient filter to the chips before running the
# pattern matching Algorithm. This essentially highlights
# edges within the chips, possibly increasing the chance of
# finding a good match between the search and pattern chips.
#Possible Values: {None, Sobel}
#OPTIONAL
#Gradient = None

# If the two images to be registered do not have the same
# geometry, pattern matching becomes more difficult. This
# option informs the algorithm to warp the pattern cube to
# match the geometry of the search cube by using map
# projections and/or camera models. The warping requires
# interpolation, and the type of interpolation is chosen here.
#Possible Values: {NearestNeighborType, BiLinearType, CubicConvolutionType}
#OPTIONAL
#ChipInterpolator = NearestNeighborType
EndGroup

#Pattern Chip Definitions
Group = PatternChip
#Size of the PatternChip in Samples and Lines
#Possible Values: Natural Numbers
#REQUIRED
Samples = 15
Lines = 15

#The minimum/maximum pixel value the algorithm should use for registration.
# If a pixel is outside of this range, then it will not be used in the
# registration calculations.
#Possible Values: (-infinity, infinity), ValidMinimum < ValidMaximum
#OPTIONAL
#ValidMinimum = -100
#ValidMaximum = 100

#The MinimumZScore is used to guarantee that the pattern chip has
# enough variability--if the chip is too smooth, spurious matches
# are likely to occur.
#Possible Values: (0.0,infinity)
#OPTIONAL
#MinimumZScore = 1.0

#The ValidPercent parameter specifies how many invalid pixels
# (NULL, HIS, etc.) are allowed in the chip before the chip is
# considered invalid and the match fails.
#Possible Values: (0.0,100.0]
#OPTIONAL
#ValidPercent = 50.0
EndGroup

#Search Chip Definitions
Group = SearchChip
#Size of the SearchChip in Samples and Lines
#Possible Values: Natural Numbers
#REQUIRED
Samples = 30
Lines = 30

#The minimum/maximum pixel value the algorithm should use for registration.
# If a pixel is outside of this range, then it will not be used in the
# registration calculations.
#Possible Values: (-infinity, infinity), ValidMinimum < ValidMaximum
#OPTIONAL
#ValidMinimum = -100
#ValidMaximum = 100

#The SubchipValidPercent parameter specifies how many invalid pixels
# (NULL, HIS, etc.) are allowed in the subchip before it is
# considered invalid and the match fails.
#Possible Values: (0.0, 100.0]
#OPTIONAL
#SubchipValidPercent = 50.0
EndGroup

#If the SubPixelAccuracy parameter is TRUE, then a continuous surface
# based on the fit chip is generated. A least squares fit is then used
# to estimate the true registration position (likely to be between pixels).
Group = SurfaceModel
#The result of a sub-pixel accuracy computation is likely to move
# the result away from its original whole-pixel fit. However,
# sometimes the move could be so drastic that it calls into
# question the validity of the match. This tolerance value
# thus specifies the max number of pixels the sub-pixel accuracy
# computation can move the best fit before the registration is rejected
# entirely.
#Possible Values (0.0, infinity)
#OPTIONAL
#DistanceTolerance = 1.5

#When refining a whole-pixel match to sub-pixel accuracy, it is important
# to consider how much area around that best whole-pixel fit to sample
# for constructing a surface model. The WindowSize keyword defines the
# size of the window, centered on the best whole-pixel match, that will
# be used for modelling the surface. Values for WindowSize specify the
# N of an NxN chip, and must be odd numbers greater than or equal to 3.
#Possible Values: [3, infinity), odd integer
#OPTIONAL
#WindowSize = 5

#After the least squares fit is performed to model a surface, the
# ideal result is a circular formation of goodness-of-fit values
# improving towards the center of the surface. The less circular,
# or more "eccentric", the formation of goodness-of-fit values,
# the less likely the modelling result is accurate. The
# conditions under which a high ratio occurs is when there are
# primiarily linear features in the search and pattern chips.
# In an attempt to let the user define what constitutes a tolerable
# amount of eccentricity in their surface models, we introduce the
# notion of an "Eccentricity Ratio". Here we think of eccentricity
# as a ratio between the semi-major and semi-minor axes of an ellipse.
#Possible Values [1.0, infinity]
#OPTIONAL
#EccentricityRatio = 1.0

#The least squares fit performed to construct the surface model
# takes discrete data from the whole-pixels around the best-fit.
# When these discrete data are fit with a continuous function,
# there is likely going to be some amount of error between the
# original value for some pixel and its interpolated value in the
# least squares solution. The ResidualTolerance keyword thus
# allows the user to specify the maximum average residual, or
# mean absolute error, for all pixels in the surface model area,
# that will be tolerated before the sub-pixel accuracy computation
# is rejected and the registration fails for that point.
#Possible Values: [0.0, infinity]
#OPTIONAL
#ResidualTolerance = 0.0
EndGroup
EndObject
Loading

0 comments on commit 7b6ac6b

Please sign in to comment.