GeoEco.DataProducts.NASA.PODAAC.GHRSSTLevel4.InterpolateAtArcGISPoints
- classmethod GHRSSTLevel4.InterpolateAtArcGISPoints(username, password, shortName, variableName, points, tField, valueField, method='Nearest', where=None, noDataValue=None, convertToCelsius=True, datasetType='netcdf', timeout=60, maxRetryTime=300, cacheDirectory=None, metadataCacheLifetime=86400.0, orderByFields=None, numBlocksToCacheInMemory=256, xBlockSize=64, yBlockSize=64, tBlockSize=1)
Interpolates values of a GHRSST Level 4 product published by NASA JPL PO.DAAC at points.
Given a desired GHRSST L4 product, this tool interpolates the value of that product at the given points. This tool performs the same basic operation as the ArcGIS Spatial Analyst’s
ExtractValuestoPoints()tool, but it reads the data from NASA’s servers rather than reading rasters stored on your machine.The Group for High-Resolution Sea Surface Temperature (GHRSST) provides a new generation of global high-resolution (<10km) SST products to the operational oceanographic, meteorological, climate and general scientific community. The overall aim of the GHRSST is to provide the best quality sea surface temperature data for applications in short, medium and decadal/climate time scales in the most cost effective and efficient manner through international collaboration and scientific innovation.
This tool accesses Level 4 (L4) gap-free gridded SST products published in near real-time by the GHRSST Global Data Assembly Center (GDAC) at the NASA JPL Physical Oceanography Distributed Active Archive Center (PO.DAAC) and subsequently hosted and distributed by NASA Earthdata. These products provide regional and global daily cloud-free estimates of SST at spatial resolutions ranging from 0.25 degrees to down 1 km. To fill in cloudy areas, data from multiple satellite and in-situ sensors are combined and regions without any data are filled in various interpolation and modeling techniques.
All products accessed by this tool are published at a daily timestep. Some products are updated on a continual basis and available in near real time; others are updated infrequently and are intended mainly for historical analysis. The temporal extent, spatial resolution and extent, and sensors and interpolation technique used vary by product. All products use the WGS 1984 geographic coordinate system. GHRSST temperatures are published in kelvin. By default, this tool converts them to degrees Celsius but provides an option to obtain the original kelvin values.
This tool supports many but not all of the GHRSST L4 published by PO.DAAC. If you see a GHRSST L4 product on PO.DAAC that is not available with this tool, please contact the MGET development team for assistance.
Please see these instructions on how to acknowledge your use of PO.DAAC products.
Requires: ArcGIS Pro 3.2.0 or later or ArcGIS Server equivalent to ArcGIS Pro 3.2.0 or later, Python numpy module, Python requests module, Python netCDF4 module.
- Parameters:
username (
str) – NASA Earthdata account user name. Minimum length꞉ 1.password (
str) – NASA Earthdata account password. Minimum length꞉ 1.shortName (
str) –PO.DAAC Short Name of the GHRSST L4 product to access. Currently, the following products are supported:
All products use the WGS 1984 geographic coordinate system and are published at a daily time-step. Some products are updated on a continual basis and available in near real time; others are updated infrequently and are intended mainly for historical analysis. The temporal extent, spatial resolution and extent, sensors and, interpolation technique used vary by product. Please see the products’ documentation for details.
This tool supports many but not all of the GHRSST L4 products published by PO.DAAC. If you see a product on PO.DAAC that is not available with this tool, please contact the MGET development team for assistance.
Allowed values꞉
'AVHRR_OI-NCEI-L4-GLOB-v2.0','AVHRR_OI-NCEI-L4-GLOB-v2.1','CMC0.1deg-CMC-L4-GLOB-v3.0','CMC0.2deg-CMC-L4-GLOB-v2.0','DMI_OI-DMI-L4-GLOB-v1.0','GAMSSA_28km-ABOM-L4-GLOB-v01','Geo_Polar_Blended-OSPO-L4-GLOB-v1.0','Geo_Polar_Blended_Night-OSPO-L4-GLOB-v1.0','K10_SST-NAVO-L4-GLOB-v01','MUR-JPL-L4-GLOB-v4.1','MUR25-JPL-L4-GLOB-v04.2','MW_IR_OI-REMSS-L4-GLOB-v5.0','MW_IR_OI-REMSS-L4-GLOB-v5.1','MW_OI-REMSS-L4-GLOB-v5.0','MW_OI-REMSS-L4-GLOB-v5.1','OISST_HR_NRT-GOS-L4-BLK-v2.0','OISST_HR_NRT-GOS-L4-MED-v2.0','OISST_UHR_NRT-GOS-L4-BLK-v2.0','OISST_UHR_NRT-GOS-L4-MED-v2.0','OSTIA-UKMO-L4-GLOB-REP-v2.0','OSTIA-UKMO-L4-GLOB-v2.0','RAMSSA_09km-ABOM-L4-AUS-v01'. Case sensitive.variableName (
str) –GHRSST variable to access, one of:
analysed_sst- product-specific estimate of SST.analysis_error- product-specific estimate of of the error in the SST estimate.
Please see the product documentation for details about what these variables mean and how they were calculated. These variable names are case-sensitive.
Allowed values꞉
'analysed_sst','analysis_error'. Case sensitive.points (
str) –Feature class or layer containing the points at which GHRSST values should be interpolated. The points must have a field that contains the date of each point and a field to receive the value interpolated from the raster.
The GHRSST data use the WGS 1984 geographic coordinate system. It is recommended but not required that the points use the same coordinate system. If they do not, this tool will attempt to project the points to the WGS 1984 coordinate system prior to doing the interpolation. This may fail if a datum transformation is required, in which case you will have to manually project the points to the WGS 1984 coordinate system before using this tool.
Minimum length꞉ 1. Must exist.
tField (
str) – Field of the points that specifies the date and time of the point. The field must have a datetime data type. If the field can only represent dates with no time component, the time will assumed to be 00:00:00. Minimum length꞉ 1. Must exist.valueField (
str) – Field of the points to receive the interpolated values. The field must have a floating-point or integer data type. If the field cannot represent the interpolated value at full precision, the closest approximation will be stored and a warning will be issued. This will happen, for example, when you interpolate floating-point values into an integer field. Minimum length꞉ 1. Must exist.method (
str, optional) –Interpolation method to use, one of:
Nearest- nearest neighbor interpolation. The interpolated value will simply be the value of the cell that contains the point. This is the default.Linear- linear interpolation (also known as trilinear interpolation). This method is suitable for continuous data such as sea surface temperature, but not for categorical data such as pixel quality flags (use nearest neighbor instead). This method averages the values of the eight nearest cells in the x, y, and time dimensions, weighting the contribution of each cell by the area of it that would be covered by a hypothetical cell centered on the point being interpolated. If the cell containing the point contains NoData, the result is NoData. Otherwise, and the result is based on the weighted average of the eight nearest cells that do contain data, including the one that contains the cell. If any of the other seven cells contain NoData, they are omitted from the average. This a 3D version of the bilinear interpolation implemented by the ArcGIS Spatial Analyst’sExtractValuestoPoints()tool.
Allowed values꞉
'Nearest','Linear'.where (
str, optional) –SQL WHERE clause expression that specifies the subset of points to process. If not provided, all of the points will be processed. If provided but the underlying storage format does not support WHERE clauses, an exception will be raised.
The exact syntax of this expression depends on the underlying storage format. If the underlying data store will be accessed through ArcGIS, this article may document some of the possible syntax, but not all of it may be supported through ArcGIS’s underlying Python API.
Minimum length꞉ 1.
noDataValue (
float, optional) – Value to use when the interpolated value is NoData. If a value is not provided for this parameter, a database NULL value will be stored in the field when the interpolated value is NoData. If the field cannot store NULL values, as is the case with shapefiles, the value -9999 will be used.convertToCelsius (
bool, optional) – If True (the default), temperature values will be converted from kelvin to degrees Celsius. If False, temperature values will be in the original kelvin values.datasetType (
str, optional) –Dataset type to access. Currently only
netCDFis supported. netCDF files will be downloaded and cached locally. If you specify a Cache Directory, they will be stored there and not deleted. Otherwise a temporary directory will be created to hold the files while the download is in progress and deleted when the relevent data are extracted and execution is complete.The disadvantage with this approach is that when your study area is small and you’re accessing a global product, a lot of bandwidth and disk space is wasted. This problem can become acute if you’re accessing a global product with very high resolution, such as one of the 1 km resolution datasets. If this proves too problematic, contact the MGET development team for assistance. We may be able to implement an alternative access method that allows downloads to be limited to a geographic bounding box.
Allowed values꞉
'netCDF'.timeout (
int, optional) –Number of seconds to wait for the server to respond before failing with a timeout error.
If you also provide a Maximum Retry Time and it is larger than the timeout value, the failed request will be retried automatically (with the same timeout value) until it succeeds or the Maximum Retry Time has elapsed.
If you receive a timeout error you should investigate the server to determine if it is malfunctioning or just slow. Check the Earthdata website to see if NASA has posted a notice about the problem, or contact the NASA directly. If the server just slow, increase the timeout value to a larger number, to give the server more time to respond.
Minimum value꞉ 1.
maxRetryTime (
int, optional) –Number of seconds to retry requests to the server before giving up.
Use this parameter to cope with transient failures. For example, you may find that the server is rebooted nightly during a maintenance cycle. If you start a long running operation and want it to run overnight without failing, set the maximum retry time to a duration that is longer than the time that the server is offline during the maintenance cycle.
To maximize performance while minimizing load during failure situations, retries are scheduled with progressive delays:
The first retry is issued immediately.
Then, so long as fewer than 10 seconds have elapsed since the original request was issued, retries are issued every second.
After that, retries are issued every 30 seconds until the maximum retry time is reached or the request succeeds.
Minimum value꞉ 1.
cacheDirectory (
str, optional) –Directory for caching local copies of downloaded data. A cache directory is optional but highly recommended if you plan to repeatedly access data for the same range of dates.
When data are requested, the cache directory will be checked for data that was downloaded and cached during prior requests. If cached data exists that can fulfill part of the current request, the request will be serviced by reading from cache files rather than downloading from the server. If the entire request can be serviced from the cache, the server will not be accessed at all and the request will be completed extremely quickly. Any parts of the request that cannot be serviced from the cache will be downloaded from the server and added to the cache, speeding up future requests for the same data.
If you use a cache directory, be aware of these common pitfalls:
The caching algorithm permits the cache to grow to infinite size and never deletes any cached data. If you access a large amount of data (e.g. an entire 20 terabyte collection of satellite images) it will all be added to the cache. Be careful that you do not fill up your hard disk. To mitigate this, manually delete the entire cache or selected directories or files within it.
The caching algorithm stores data in uncompressed files, so that subsets of those files may be quickly accessed. To save space on your hard disk, you can enable compression of the cache directory using the operating system. On Windows, right click on the directory in Windows Explorer, select Properties, click Advanced, and enable “Compress contents to save disk space”.
The caching algorithm cannot detect when portions of a dataset have been replaced on the server, thereby making the cached data obsolete. Thus, if a data provider republishes a dataset with improved data values, the caching algorithm will continue to use the old, obsolete values. To mitigate this, you should monitor when data providers reprocess their datasets, and delete the cached files when they become obsolete.
Minimum length꞉ 1.
metadataCacheLifetime (
float, optional) –Maximum amount of time, in seconds, that granule metadata downloaded from the NASA Earthdata Common Metadata Repository (CMR) will be cached.
Downloading metadata from the NASA Earthdata CMR can be slow. If this parameter and a cache directory are both provided, when the CMR is queried for all granule metadata for a given collection_concept_id, the downloaded metadata will be cached in the directory for this amount of time. During this period, the cached metadata will be accessed instead of the server, which can greatly speed up processing involving NASA Earthdata granules. However, if new datasets are stored in the CMR, they will not be discovered until the cached metadata has expired.
If this parameter is not provided (the default), then granule metadata will not be cached.
Minimum value꞉ 1.0.
orderByFields (
listofstr, optional) – Fields for defining the order in which the points are processed. The points may be processed faster if they are ordered geographically, such that points that are close in geographic space are processed sequentially. Ordering the points this way increases the probability that the value of a given point can be interpolated from data that is cached in memory, rather than from data that must be read from the disk or network, which is much slower. Choose fields that facilitate this. For example, if your points represent the locations of animals tracked by satellite telemetry, order the processing first by the animal ID and then by the transmission date or number. Minimum length꞉ 1.numBlocksToCacheInMemory (
int, optional) –Maximum number of blocks of data to cache in memory.
To minimize the number of times that the disk or network must be accessed, this tool employs a simple caching strategy. When it processes the first point, it reads a square block of cells centered on that point and caches it in memory. When it processes the second and subsequent points, it first checks whether the cells needed for that point are contained by the block cached in memory. If so, it processes that point using the in-memory block, rather than reading from disk or the network again. If not, it reads another square block centered on that point and adds it to the cache.
The tool processes the remaining points, adding additional blocks to the cache, as needed. To prevent the cache from exhausting all memory, it is only permitted to grow to the size specified by this parameter. When the cache is full but a new block is needed, the oldest block is discarded to make room for the newest block.
If this parameter is 0, no blocks will be cached in memory.
Minimum value꞉ 0.
xBlockSize (
int, optional) – Size of the blocks of data to cache in memory in thexdirection. The size is given as the number of cells. If this parameter is 0, no blocks will be cached in memory. Minimum value꞉ 0.yBlockSize (
int, optional) – Size of the blocks of data to cache in memory in theydirection. The size is given as the number of cells. If this parameter is 0, no blocks will be cached in memory. Minimum value꞉ 0.tBlockSize (
int, optional) – Size of the blocks of data to cache in memory in thet(time) direction. The size is given as the number of cells. If this parameter is 0, no blocks will be cached in memory. This parameter is ignored if the grids do not have atdimension. Minimum value꞉ 0.
- Returns:
Updated points.
- Return type: