ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Help
  • Sign Out
ArcGIS Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS Desktop

A complete professional GIS

ArcGIS Enterprise

GIS in your enterprise

ArcGIS Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

ArcMap

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • Extensions

Define Mosaic Dataset NoData

  • Summary
  • Usage
  • Syntax
  • Code sample
  • Environments
  • Licensing information

Summary

Specifies one or more values to be represented as NoData.

Usage

  • NoData can be used to define pixel values that surround an image; however, the mosaic dataset can be made more efficient if the footprints are recomputed to remove these boundary areas. To recompute the footprints you can edit them manually or use the Build Footprints tool.

  • You can specify multiple NoData values with the Bands For NoData Value parameter. Use a space delimiter between each value you want to define as NoData.

  • This tool inserts the Mask function within the function chain for each raster item within a mosaic dataset.

Syntax

arcpy.management.DefineMosaicDatasetNoData(in_mosaic_dataset, num_bands, {bands_for_nodata_value}, {bands_for_valid_data_range}, {where_clause}, {Composite_nodata_value})
ParameterExplanationData Type
in_mosaic_dataset

The mosaic dataset where you want to update the NoData values.

Mosaic Layer
num_bands

The number of bands in the mosaic dataset.

Long
bands_for_nodata_value
[band {NoData value},...]
(Optional)

Define values for each or all bands. Each band can have a unique NoData value defined, or the same value can be specified for all bands. If you want to define multiple NoData values for each band selection, use a space delimiter between each NoData value within the bands_for_nodata_value parameter.

The Mask function inserted by this tool is inserted before the Composite Bands function in the function chain. Therefore, if the function chain for each raster within the mosaic dataset contains the Composite Bands function, or if your raster data was added with a raster type that adds the Composite Bands function to each raster’s function chain, then any value you specify will apply to all bands.

Value Table
bands_for_valid_data_range
[band {minimum value} {maximum value},...]
(Optional)

Specify a range of values to display for each band. Values outside of this range will be classified as NoData. When working with composite bands, the range will apply to all bands.

Value Table
where_clause
(Optional)

An SQL statement to select specific raster in the mosaic dataset. Only the selected rasters will have their NoData values changed.

SQL Expression
Composite_nodata_value
(Optional)

Choose whether all bands must be NoData in order for the pixel to be classified as NoData.

  • NO_COMPOSITE_NODATA —If any of the bands have pixels of NoData, then the pixel is classified as NoData. This is the default.
  • COMPOSITE_NODATA —All of the bands must have pixels of NoData in order for the pixel to be classified as NoData.
Boolean

Derived Output

NameExplanationData Type
out_mosaic_dataset

The updated mosaic dataset.

Mosaic Layer

Code sample

DefineMosaicDatasetNoData example 1 (Python window)

This is a Python sample for DefineMosaicDatasetNoData.

import arcpy
arcpy.DefineMosaicDatasetNodata_management(
     "c:/workspace/Nodata.gdb/md", "3",  "ALL_BANDS '0 9'", "#", 
     "OBJECTID=2",  "COMPOSITE_NODATA")
DefineMosaicDatasetNoData example 2 (stand-alone script)

This is a Python script sample for DefineMosaicDatasetNoData.

#Specify multiple Nodata values for all bands in one Catalog item

import arcpy
arcpy.env.workspace = "C:/Workspace"

mdname = "Nodata.gdb/md"
noofbands = "3"
nodataval = "ALL_BANDS '0 9'"
nodatarange = "#"
query = "OBJECTID=2"
mode = "#"

arcpy.DefineMosaicDatasetNoData_management(mdname, noofbands, nodataval, 
                                           nodatarange, query, mode)

Environments

  • Extent

Licensing information

  • Basic: No
  • Standard: Yes
  • Advanced: Yes

Related topics

  • An overview of the Raster toolset
  • Environment settings for raster data

ArcGIS Desktop

  • Home
  • Documentation
  • Support

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Esri Blog
  • User Conference
  • Developer Summit
Esri
Tell us what you think.
Copyright © 2021 Esri. | Privacy | Legal