Ask A Cartographer

How to batch crop and mosaic a lot of rasters

October 08 2011 | 2 comments
Categories: Map Data


I have a georeferenced map collection. All map sections are rectangle-shaped, and all sections are the same size as all others. All sections have frames, with a subtitle about the author, graticule etc. If I display in ArcMap, all the sections overlap the others for a bit (the frame part overlaps the neighbour sections). First, I need to crop all sections. Second, I need to mosaic them to one big map, for the better use (less memory usage, faster working etc.)

I tested the Clip (data management) tool on 3 sample sections. I created a polygon feature, and I drew 3 polygons on that layer. I thought, maybe I can setup in the Clip function window, that this polygon layer is the mask, and that the function needs to clip by this layer. The result isn't good -some sides of the sections are clipped, some aren't.

I tested the Extract by Mask tool as well and the results are the same as above.

Any ideas? Btw I have around 600 map sections.....

Mapping Center Answer:

You can achieve the desired result using a Mosaic dataset (introduced at 10.0), which allows you to store, manage, view, and query small to vast collections of raster data. Here is the workflow you need to follow. You can modify the footprints of the mosaic dataset to clip the frame part of your sections.

You can edit your footprints by starting an edit session in ArcMap and manually editing each footprint, or you can replace the footprints with polygons you already have. Optionally, you can shrink the existing footprints using Build Footprints tool.

Tip: In case you need to create the footprint polygon, you can use Grid Index Features tool to create one and replace the footprints with polygons.

Update answer and links posted by Brent Edwards on Oct 28 2015 7:09AM
Are the proposed methods still relevant? If so, could you please update the links as they seem to be broken.

Workflow posted by Aileen Buckley on Oct 29 2015 12:53PM
The workflow is pretty much the same. One thing I would note is that you can use a separate feature class and the Update Mosaic Dataset Geometry tool to update the footprints. Also, I have also used a separate feature class to create the mosaic dataset which includes the desired footprint of the image as well as a path to the location of the image on the computer and any metadata you want to include about the images when you make the mosaic dataset. The mosaic dataset then has the images, clipped to the desired footprints, along with the metadata. One cool thing about this approach is that to do this, simply open the Catalog window and drag the feature class with the desired footprints (and optional metadata)_ over the mosaic dataset and the tool will open fully populated with all the right parameters. Simply click OK and you are good to go!

If you would like to post a comment, please login.

Contact Us | Legal | Privacy |