Showing results for 
Search instead for 
Do you mean 

Drop Edges from Image

by on ‎04-29-2016 12:20 PM - edited on ‎02-24-2020 02:01 AM by Community Manager (1,031 Views)

Download model

Description:

Trims edges from an image. Enter number of pixel rows/columns to trim from image. You can use the Preview function to tweak the trim level setting to your needs. This is useful for cutting off rough or skewed edges or otherwise if you need a rectangular image. 

One limitation of this Model is that the rows and columns aren't physically trimmed from the file - the output image still has the same number of rows and columns as the input file, but the specified number of edge rows and columns have been set to  have a pixel value of 0 in the output. In ERDAS IMAGINE 2016 we will be able to use the Define Processing Area operator to physically trim edge rows/columns (and a new Article will be posted with that Model).

 

DropEdges-v15-1-5.gmdx

image2015-12-17 16 6 46.png   

Input parameters:

Raster Input File: enter the filename of raster to trim

Set Trim Level: enter the number of pixel rows/columns you wish to trim from the image

Trimmed Raster Output File: enter the filename of the new raster

image2015-12-23 14 40 47.png

 

Comments
by Technical Evangelist
a week ago - last edited a week ago

Addendum 13th January, 2021:

 

Since probably about the ERDAS IMAGINE 2016 release, the Pixel X and Pixel Y operators have required an IMAGINE.Features stream to their input port to derive an extent from. So for the above Spatial Model to work in newer versions you will need to connect the RasterOut port of the Raster Input operator to the RasterIn ports of the Pixel X and Pixel Y operators. 

 

Cheers

 

Courses