:doc:`SageMakergeospatialcapabilities <../../sagemaker-geospatial>` / Client / search_raster_data_collection

*****************************
search_raster_data_collection
*****************************



.. py:method:: SageMakergeospatialcapabilities.Client.search_raster_data_collection(**kwargs)

  

  Allows you run image query on a specific raster data collection to get a list of the satellite imagery matching the selected filters.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/sagemaker-geospatial-2020-05-27/SearchRasterDataCollection>`_  


  **Request Syntax**
  ::

    response = client.search_raster_data_collection(
        Arn='string',
        NextToken='string',
        RasterDataCollectionQuery={
            'AreaOfInterest': {
                'AreaOfInterestGeometry': {
                    'MultiPolygonGeometry': {
                        'Coordinates': [
                            [
                                [
                                    [
                                        123.0,
                                    ],
                                ],
                            ],
                        ]
                    },
                    'PolygonGeometry': {
                        'Coordinates': [
                            [
                                [
                                    123.0,
                                ],
                            ],
                        ]
                    }
                }
            },
            'BandFilter': [
                'string',
            ],
            'PropertyFilters': {
                'LogicalOperator': 'AND',
                'Properties': [
                    {
                        'Property': {
                            'EoCloudCover': {
                                'LowerBound': ...,
                                'UpperBound': ...
                            },
                            'LandsatCloudCoverLand': {
                                'LowerBound': ...,
                                'UpperBound': ...
                            },
                            'Platform': {
                                'ComparisonOperator': 'EQUALS'|'NOT_EQUALS'|'STARTS_WITH',
                                'Value': 'string'
                            },
                            'ViewOffNadir': {
                                'LowerBound': ...,
                                'UpperBound': ...
                            },
                            'ViewSunAzimuth': {
                                'LowerBound': ...,
                                'UpperBound': ...
                            },
                            'ViewSunElevation': {
                                'LowerBound': ...,
                                'UpperBound': ...
                            }
                        }
                    },
                ]
            },
            'TimeRangeFilter': {
                'EndTime': datetime(2015, 1, 1),
                'StartTime': datetime(2015, 1, 1)
            }
        }
    )
    
  :type Arn: string
  :param Arn: **[REQUIRED]** 

    The Amazon Resource Name (ARN) of the raster data collection.

    

  
  :type NextToken: string
  :param NextToken: 

    If the previous response was truncated, you receive this token. Use it in your next request to receive the next set of results.

    

  
  :type RasterDataCollectionQuery: dict
  :param RasterDataCollectionQuery: **[REQUIRED]** 

    RasterDataCollectionQuery consisting of `AreaOfInterest(AOI) <https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_geospatial_AreaOfInterest.html>`__, `PropertyFilters <https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_geospatial_PropertyFilter.html>`__ and `TimeRangeFilterInput <https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_geospatial_TimeRangeFilterInput.html>`__ used in `SearchRasterDataCollection <https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_geospatial_SearchRasterDataCollection.html>`__.

    

  
    - **AreaOfInterest** *(dict) --* 

      The Area of interest to be used in the search query.

      .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``AreaOfInterestGeometry``. 

    
      - **AreaOfInterestGeometry** *(dict) --* 

        A GeoJSON object representing the geographic extent in the coordinate space.

        .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``MultiPolygonGeometry``, ``PolygonGeometry``. 

      
        - **MultiPolygonGeometry** *(dict) --* 

          The structure representing the MultiPolygon Geometry.

          

        
          - **Coordinates** *(list) --* **[REQUIRED]** 

            The coordinates of the multipolygon geometry.

            

          
            - *(list) --* 

            
              - *(list) --* 

              
                - *(list) --* 

                
                  - *(float) --* 

                  
              
            
          
        
        
        - **PolygonGeometry** *(dict) --* 

          The structure representing Polygon Geometry.

          

        
          - **Coordinates** *(list) --* **[REQUIRED]** 

            Coordinates representing a Polygon based on the `GeoJson spec <https://www.rfc-editor.org/rfc/rfc7946#section-3.1.6>`__.

            

          
            - *(list) --* 

            
              - *(list) --* 

              
                - *(float) --* 

                
            
          
        
        
      
    
    - **BandFilter** *(list) --* 

      The list of Bands to be displayed in the result for each item.

      

    
      - *(string) --* 

      
  
    - **PropertyFilters** *(dict) --* 

      The Property Filters used in the search query.

      

    
      - **LogicalOperator** *(string) --* 

        The Logical Operator used to combine the Property Filters.

        

      
      - **Properties** *(list) --* 

        A list of Property Filters.

        

      
        - *(dict) --* 

          The structure representing a single PropertyFilter.

          

        
          - **Property** *(dict) --* **[REQUIRED]** 

            Represents a single property to match with when searching a raster data collection.

            .. note::    This is a Tagged Union structure. Only one of the     following top level keys can be set: ``EoCloudCover``, ``LandsatCloudCoverLand``, ``Platform``, ``ViewOffNadir``, ``ViewSunAzimuth``, ``ViewSunElevation``. 

          
            - **EoCloudCover** *(dict) --* 

              The structure representing EoCloudCover property filter containing a lower bound and upper bound.

              

            
              - **LowerBound** *(float) --* **[REQUIRED]** 

                Lower bound for EoCloudCover.

                

              
              - **UpperBound** *(float) --* **[REQUIRED]** 

                Upper bound for EoCloudCover.

                

              
            
            - **LandsatCloudCoverLand** *(dict) --* 

              The structure representing Land Cloud Cover property filter for Landsat collection containing a lower bound and upper bound.

              

            
              - **LowerBound** *(float) --* **[REQUIRED]** 

                The minimum value for Land Cloud Cover property filter. This will filter items having Land Cloud Cover greater than or equal to this value.

                

              
              - **UpperBound** *(float) --* **[REQUIRED]** 

                The maximum value for Land Cloud Cover property filter. This will filter items having Land Cloud Cover less than or equal to this value.

                

              
            
            - **Platform** *(dict) --* 

              The structure representing Platform property filter consisting of value and comparison operator.

              

            
              - **ComparisonOperator** *(string) --* 

                The ComparisonOperator to use with PlatformInput.

                

              
              - **Value** *(string) --* **[REQUIRED]** 

                The value of the platform.

                

              
            
            - **ViewOffNadir** *(dict) --* 

              The structure representing ViewOffNadir property filter containing a lower bound and upper bound.

              

            
              - **LowerBound** *(float) --* **[REQUIRED]** 

                The minimum value for ViewOffNadir property filter. This filters items having ViewOffNadir greater than or equal to this value.

                

              
              - **UpperBound** *(float) --* **[REQUIRED]** 

                The maximum value for ViewOffNadir property filter. This filters items having ViewOffNadir lesser than or equal to this value.

                

              
            
            - **ViewSunAzimuth** *(dict) --* 

              The structure representing ViewSunAzimuth property filter containing a lower bound and upper bound.

              

            
              - **LowerBound** *(float) --* **[REQUIRED]** 

                The minimum value for ViewSunAzimuth property filter. This filters items having ViewSunAzimuth greater than or equal to this value.

                

              
              - **UpperBound** *(float) --* **[REQUIRED]** 

                The maximum value for ViewSunAzimuth property filter. This filters items having ViewSunAzimuth lesser than or equal to this value.

                

              
            
            - **ViewSunElevation** *(dict) --* 

              The structure representing ViewSunElevation property filter containing a lower bound and upper bound.

              

            
              - **LowerBound** *(float) --* **[REQUIRED]** 

                The lower bound to view the sun elevation.

                

              
              - **UpperBound** *(float) --* **[REQUIRED]** 

                The upper bound to view the sun elevation.

                

              
            
          
        
    
    
    - **TimeRangeFilter** *(dict) --* **[REQUIRED]** 

      The TimeRange Filter used in the search query.

      

    
      - **EndTime** *(datetime) --* **[REQUIRED]** 

        The end time for the time-range filter.

        

      
      - **StartTime** *(datetime) --* **[REQUIRED]** 

        The start time for the time-range filter.

        

      
    
  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'ApproximateResultCount': 123,
          'Items': [
              {
                  'Assets': {
                      'string': {
                          'Href': 'string'
                      }
                  },
                  'DateTime': datetime(2015, 1, 1),
                  'Geometry': {
                      'Coordinates': [
                          [
                              [
                                  123.0,
                              ],
                          ],
                      ],
                      'Type': 'string'
                  },
                  'Id': 'string',
                  'Properties': {
                      'EoCloudCover': ...,
                      'LandsatCloudCoverLand': ...,
                      'Platform': 'string',
                      'ViewOffNadir': ...,
                      'ViewSunAzimuth': ...,
                      'ViewSunElevation': ...
                  }
              },
          ],
          'NextToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **ApproximateResultCount** *(integer) --* 

        Approximate number of results in the response.

        
      

      - **Items** *(list) --* 

        List of items matching the Raster DataCollectionQuery.

        
        

        - *(dict) --* 

          The structure representing the items in the response for SearchRasterDataCollection.

          
          

          - **Assets** *(dict) --* 

            This is a dictionary of Asset Objects data associated with the Item that can be downloaded or streamed, each with a unique key.

            
            

            - *(string) --* 
              

              - *(dict) --* 

                The structure containing the asset properties.

                
                

                - **Href** *(string) --* 

                  Link to the asset object.

                  
            
        
      
          

          - **DateTime** *(datetime) --* 

            The searchable date and time of the item, in UTC.

            
          

          - **Geometry** *(dict) --* 

            The item Geometry in GeoJson format.

            
            

            - **Coordinates** *(list) --* 

              The coordinates of the GeoJson Geometry.

              
              

              - *(list) --* 
                

                - *(list) --* 
                  

                  - *(float) --* 
              
            
          
            

            - **Type** *(string) --* 

              GeoJson Geometry types like Polygon and MultiPolygon.

              
        
          

          - **Id** *(string) --* 

            A unique Id for the source item.

            
          

          - **Properties** *(dict) --* 

            This field contains additional properties of the item.

            
            

            - **EoCloudCover** *(float) --* 

              Estimate of cloud cover.

              
            

            - **LandsatCloudCoverLand** *(float) --* 

              Land cloud cover for Landsat Data Collection.

              
            

            - **Platform** *(string) --* 

              Platform property. Platform refers to the unique name of the specific platform the instrument is attached to. For satellites it is the name of the satellite, eg. landsat-8 (Landsat-8), sentinel-2a.

              
            

            - **ViewOffNadir** *(float) --* 

              The angle from the sensor between nadir (straight down) and the scene center. Measured in degrees (0-90).

              
            

            - **ViewSunAzimuth** *(float) --* 

              The sun azimuth angle. From the scene center point on the ground, this is the angle between truth north and the sun. Measured clockwise in degrees (0-360).

              
            

            - **ViewSunElevation** *(float) --* 

              The sun elevation angle. The angle from the tangent of the scene center point to the sun. Measured from the horizon in degrees (-90-90). Negative values indicate the sun is below the horizon, e.g. sun elevation of -10° means the data was captured during `nautical twilight <https://www.timeanddate.com/astronomy/different-types-twilight.html>`__.

              
        
      
    
      

      - **NextToken** *(string) --* 

        If the previous response was truncated, you receive this token. Use it in your next request to receive the next set of results.

        
  
  **Exceptions**
  
  *   :py:class:`SageMakergeospatialcapabilities.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`SageMakergeospatialcapabilities.Client.exceptions.ValidationException`

  
  *   :py:class:`SageMakergeospatialcapabilities.Client.exceptions.ThrottlingException`

  
  *   :py:class:`SageMakergeospatialcapabilities.Client.exceptions.InternalServerException`

  
  *   :py:class:`SageMakergeospatialcapabilities.Client.exceptions.ResourceNotFoundException`

  