Summary
Combines a high-resolution panchromatic raster dataset with a lower-resolution multiband raster dataset to create a high-resolution multiband raster dataset for visual analysis.
To learn more about pan sharpening, see Fundamentals of pan sharpening.
Usage
Only the areas that fully overlap will be affected by this tool.
You can save your output to BIL, BIP, BMP, BSQ, DAT, Esri Grid , GIF, IMG, JPEG, JPEG 2000, PNG, TIFF, MRF, CRF or any geodatabase raster dataset.
The four weight values assigned to the blue, green, red, and infrared bands allow you to adjust the pan-sharpening algorithms.
Pan sharpening performed on a three-band raster dataset will produce a raster dataset that has three bands.
Pan sharpening performed on a four-band raster dataset will produce a raster dataset that has four bands.
Syntax
arcpy.management.CreatePansharpenedRasterDataset(in_raster, red_channel, green_channel, blue_channel, {infrared_channel}, out_raster_dataset, in_panchromatic_image, pansharpening_type, {red_weight}, {green_weight}, {blue_weight}, {infrared_weight}, {sensor})
Parameter | Explanation | Data Type |
in_raster | The raster dataset that you want to pan sharpen. | Mosaic Dataset; Mosaic Layer; Raster Dataset; Raster Layer |
red_channel | The input raster band that you want to display with the red color channel. | Long |
green_channel | The input raster band that you want to display with the green color channel. | Long |
blue_channel | The input raster band that you want to display with the blue color channel. | Long |
infrared_channel (Optional) | The input raster band that you want to display with the infrared color channel. | Long |
out_raster_dataset | The name, location, and format for the dataset you are creating. When storing the raster dataset in a file format, you need to specify the file extension: When storing a raster dataset in a geodatabase, no file extension should be added to the name of the raster dataset. When storing the raster dataset in a file format, you need to specify the file extension:
When storing a raster dataset in a geodatabase, do not add a file extension to the name of the raster dataset. When storing your raster dataset to a JPEG file, a JPEG 2000 file, a TIFF file, or a geodatabase, you can specify a Compression Type and Compression Quality in the geoprocessing Environments. | Raster Dataset |
in_panchromatic_image | The higher-resolution panchromatic image. | Raster Layer |
pansharpening_type | The algorithm to fuse the panchromatic and multispectral bands together.
| String |
red_weight (Optional) | A value from 0 to 1 to weight the red band. | Double |
green_weight (Optional) | A value from 0 to 1 to weight the green band. | Double |
blue_weight (Optional) | A value from 0 to 1 to weight the blue band. | Double |
infrared_weight (Optional) | A value from 0 to 1 to weight the infrared band. | Double |
sensor (Optional) | When the Gram-Schmidt pan-sharpening method is chosen, you can also specify the sensor of the multiband raster input. Choosing the sensor type will set appropriate band weights.
| String |
Code sample
This is a Python sample for the CreatePansharpenedRasterDataset tool.
import arcpy
arcpy.CreatePansharpenedRasterDataset_management(
"c:/data/rgbn.tif","3","2","1","4", "c:/data/outpan.tif",
"c:/data/in_pan.img","Gram-Schmidt","","","","","QuickBird")
This is a Python script sample for the CreatePansharpenedRasterDataset tool.
#3 Band RGB Pansharpen with Brovey algorithm
import arcpy
arcpy.env.workspace = "C:/workspace"
arcpy.CreatePansharpenedRasterDataset_management(
"rgb.img","3","2","1","1", "output\\rgb_pan.img","pan.img","Brovey")
Environments
Licensing information
- Basic: Yes
- Standard: Yes
- Advanced: Yes