An official website of the United States government
Here’s how you know
Official websites use .gov A
.gov website belongs to an official government
organization in the United States.
Secure .gov websites use HTTPS A
lock
() or https:// means you’ve safely connected to
the .gov website. Share sensitive information only on official,
secure websites.
This program is designed to make modifications to various objects and groups found in ISIS
cube labels, but a .pvl file can also be used. When a PVL is used, an interim processing file
will be created, which you can later remove. Using either file type, you can add/delete or
modify keywords in a group (e.g.: 2, 3, 5), or add or remove entire groups (e.g.: 1, 6) within
the labels. For simplicity's sake, use a template (e.g.: 4) to modify labels, as this makes it
unnecessary to run the program multiple times when adding new groups. Examples can be found at
the end of this document.
Added the SETKEY parameter to prevent non-explicit duplicate keywords,
greatly cleaned and reduced code, and added support for non-cube Pvls.
Jeannie Backer
2012-12-20
Modified to update history in the labels and show appropriate files
in the dialog box for choosing FROM parameter filenames.
Fixes #655. Fixes #1084
Andrew Stebenne
2015-04-03
Modified the description to indicate that editlab always adds a blank cube to a pvl if one
isn't present.
Andrew Stebenne
2015-04-24
Reworked documentation for clarity.
Parameters
Files
The pvl or cube file containing the label to be modified.
Type
filename
File Mode
input
Filter
*.cub *.pvl
Modification Options
A list of the different types of modifications allowed on the label.
Type
string
Default
SETKEY
Option List:
Option
Brief
Description
ADDG
Add Group
Adds a group to the file label.
Exclusions
KEYWORD
VALUE
UNITS
TEMPFILE
Inclusions
GRPNAME
DELG
Delete Group
Deletes specified group from the file label.
Exclusions
KEYWORD
VALUE
UNITS
TEMPFILE
COMMENT
Inclusions
GRPNAME
ADDKEY
Add Keyword
Adds a keyword to the specified group in the file label.
Exclusions
TEMPFILE
Inclusions
GRPNAME
KEYWORD
VALUE
DELKEY
Delete Keyword
Deletes specified keyword from the specified group on the file label.
Exclusions
VALUE
UNITS
TEMPFILE
COMMENT
Inclusions
GRPNAME
KEYWORD
MODKEY
Modify Keyword
Modifies existing keyword in specified group on the file label.
Exclusions
TEMPFILE
Inclusions
GRPNAME
KEYWORD
VALUE
SETKEY
Set Keyword: deletes duplicates
Adds or modifies an existing keyword to the specified
group in the file label. If there are duplicates of the
provided keyword, all duplicates are removed from the
group, leaving only the new, provided value.
Exclusions
TEMPFILE
Inclusions
GRPNAME
KEYWORD
VALUE
ADDTEMP
Add Template File
Adds a template file to the file label.
Exclusions
GRPNAME
KEYWORD
VALUE
UNITS
COMMENT
Inclusions
TEMPFILE
Input Values
Group that is being added, deleted, or modified.
Type
string
Keyword that is being added, deleted, or modified.
Type
string
The value of the Keyword being added or modified.
Type
string
The units associated with the Keyword being added or modified.
Type
string
Internal Default
none
Adds the PvlGroups defined within the template file to the
cube's labels.
Type
filename
File Mode
input
When adding or modifying a PvlGroup or PvlKeyword, then this comment
is added to that altered PvlGroup or PvlKeyword.
Type
string
Internal Default
none
Example 1
Adding a group
This example uses the editlab application to add a new group to a previously blank label. The new
group created will be empty.
Command Line
Run the editlab application to add a group to a label
editlab from=new.cub option=addg grpname=NewGroup
Data Files
Links open in a new window.
Starting Label
Object = Label
Bytes = 65536
End_Object
Object = IsisCube
Object = Core
/* Location of the core
StartByte = 65537
Format = Tile
TileSamples = 128
TileLines = 128
Group = Dimensions
Samples = 1024
Lines = 1024
Bands = 7
End_Group
Group = Pixels
Type = Real
ByteOrder = LSB
Base = 0.0
Multiplier = 1.0
End_Group
End_Object
End_Object
End
Label after the command line is ran
Object = Label
Bytes = 65536
End_Object
Object = IsisCube
Object = Core
/* Location of the core
StartByte = 65537
Format = Tile
TileSamples = 128
TileLines = 128
Group = Dimensions
Samples = 1024
Lines = 1024
Bands = 7
End_Group
Group = Pixels
Type = Real
ByteOrder = LSB
Base = 0.0
Multiplier = 1.0
End_Group
End_Object
Group = NewGroup
End_Group
End_Object
End
Example 2
Adding a keyword
This example uses the editlab application to add a keyword to the empty group created in the last example.
Command Line
Run the editlab application to add a keyword to an existing group
Object = Label
Bytes = 65536
End_Object
Object = IsisCube
Object = Core
/* Location of the core
StartByte = 65537
Format = Tile
TileSamples = 128
TileLines = 128
Group = Dimensions
Samples = 1024
Lines = 1024
Bands = 7
End_Group
Group = Pixels
Type = Real
ByteOrder = LSB
Base = 0.0
Multiplier = 1.0
End_Group
End_Object
Group = NewGroup
Keyword = old
End_Group
End_Object
End
Example 4
Adding a template file
This example uses the editlab application to add more than one group (containing keywords) at a time
by using a template file containing only groups and keywords to the label.
Command Line
Run the editlab application to add a template file to the label