Home

User Documentation

Getting Started
Learn More
Explore in Detail
Get Inspired

Contributor Documentation

Getting Started
Learn More
Explore in Detail
Get Inspired

Quick Links

Software Manual
AstroDiscuss
GitHub
API Reference

Documentation Versions

Public Release
8.1.0
8.0.0
7.2.0
7.1.0
7.0.0
6.0.0
3.9.0
3.5.0

ISIS 2

Documentation
Tutorials
Technical Documents
USGS

ISIS Application Documentation


camtrim

Printer Friendly View | TOC | Home

Trims pixels outside of lat/lon range

Overview Parameters Example 1 Example 2

Description

This application trims pixels outside of a user-specified latitude/longitude range. Pixels that are outside of the lat/lon range are set to NULL in the resulting cube. By default, the lat/lon range is in the universal coordinate system. This can be overridden using a map projection template file.

Note: This application will not handle projected images (i.e. Level2). This program is meant to work specifically on Level1 images. To trim Level2 images, please refer to maptrim.

Categories


History

Jeff Anderson2003-04-28 Original version
Jeff Anderson2003-04-28 Added program to the Cameras category
Jeff Anderson2003-04-29 Fixed bug in the Xml file
Jeff Anderson2003-04-30 Fixed problem with projection manager prematurely destroying projection object
Stuart Sides2003-05-16 Modified schema location from astogeology... to isis.astrogeology..."
Jeff Anderson2003-06-04 Added dependent multi-band capabilities
Stuart Sides2003-07-29 Modified filename parameters to be cube parameters where necessary
Jacob Danton2005-12-02 Added appTest
Elizabeth Miller2006-05-18 Depricated CubeProjection and ProjectionManager to ProjectionFactory
Steven Lambright2008-05-12 Removed references to CubeInfo
Travis Addair2009-08-10 Mapping group parameters are now placed into the print file.
Jai Rideout2012-01-11 Updated documentation and testing with Ella Lee in preparation for the 3.4.0 release. Fixed various inconsistencies in the documentation and rewrote some parts to make it clearer. Added two examples. Added a check to ensure that projected cubes cannot be used with this application. Added two new tests to test the processing of level 2 cubes and the use of a map template file.
Tracie Sucharski2012-12-06 Changed to use TProjection instead of Projection. References #775

Parameter Groups

Files

Name Description
FROM Input cube to trim
TO Output cube
MAP Map projection template file

Ground Range

Name Description
MINLATMinimum Latitude
MAXLATMaximum Latitude
MINLONMinimum Longitude
MAXLONMaximum Longitude
X

Files: FROM


Description

Use this parameter to select the input cube filename. All bands within the cube will be trimmed.

Type cube
File Mode input
Filter *.cub
Close Window
X

Files: TO


Description

This file will contain the trimmed cube.

Type cube
File Mode output
Close Window
X

Files: MAP


Description

If a file is not provided, this program will use the planetocentric latitude type, positive east longitude direction, and 360 longitude domain. Otherwise, the labels (LatitudeType, LongitudeDomain, and LongitudeDirection) in the map projection template file will determine the lat/lon type, direction, and domain.

Type filename
File Mode input
Default None
Close Window
X

Ground Range: MINLAT


Description

Pixels that have a latitude less than this value will be trimmed.

Type double
Minimum -90 (inclusive)
Maximum 90 (inclusive)
Less Than MAXLAT
Close Window
X

Ground Range: MAXLAT


Description

Pixels that have a latitude greater than this value will be trimmed.

Type double
Minimum -90 (inclusive)
Maximum 90 (inclusive)
Greater Than MINLAT
Close Window
X

Ground Range: MINLON


Description

Pixels that have a longitude less than this value will be trimmed.

Type double
Minimum -360 (inclusive)
Maximum 360 (inclusive)
Less Than MAXLON
Close Window
X

Ground Range: MAXLON


Description

Pixels that have a longitude greater than this value will be trimmed.

Type double
Minimum -360 (inclusive)
Maximum 360 (inclusive)
Greater Than MINLON
Close Window

Example 1

Trimming Pixels

Description

This example illustrates how to trim a cube such that all pixels with latitudes greater than 25 are set to NULL.

Command Line

camtrim FROM=input.cub TO=trimmed.cub MINLAT=-90 MAXLAT=25 MINLON=0 MAXLON=360
The command to use for this example.

Input Image

input.cub

Input cube

Parameter Name: FROM

This is the input cube to trim.

Output Image

trimmed.cub

Trimmed cube

Parameter Name: TO

This is the trimmed cube. Notice the NULL pixels with latitudes greater than 25 degrees.


Example 2

Trimming Pixels Using a Map Projection Template File

Description

This example illustrates how to trim a cube such that only pixels between longitudes 134 and 136 are kept. All other pixels are set to NULL. The map projection template file specifies planetographic latitudes and -180 to 180 positive west longitudes, instead of using planetocentric latitudes and 0 to 360 positive east longitudes (the default).

Command Line

camtrim FROM=input.cub TO=trimmed_lon.cub MAP=sinusoidal.map MINLAT=-90 MAXLAT=90 MINLON=134 MAXLON=136
The command to use for this example.

Input Image

input.cub

Input cube

Parameter Name: FROM

This is the input cube to trim.

Data File

Links open in a new window.
Map projection template file This is the map projection template file that is used to specify the latitude type, longitude direction, and longitude domain. The three keywords of interest in this file are LatitudeType, LongitudeDirection, and LongitudeDomain.

Output Image

trimmed_lon.cub

Trimmed cube

Parameter Name: TO

This is the trimmed cube.