ListDatasetEntries - Amazon Lookout for Vision API Reference

ListDatasetEntries

Lists the JSON Lines within a dataset. An Amazon Lookout for Vision JSON Line contains the anomaly information for a single image, including the image location and the assigned label.

This operation requires permissions to perform the lookoutvision:ListDatasetEntries operation.

Request Syntax

GET /2020-11-20/projects/projectName/datasets/datasetType/entries?anomalyClass=AnomalyClass&createdAfter=AfterCreationDate&createdBefore=BeforeCreationDate&labeled=Labeled&maxResults=MaxResults&nextToken=NextToken&sourceRefContains=SourceRefContains HTTP/1.1

URI Request Parameters

The request uses the following URI parameters.

AfterCreationDate

Only includes entries after the specified date in the response. For example, 2020-06-23T00:00:00.

AnomalyClass

Specify normal to include only normal images. Specify anomaly to only include anomalous entries. If you don't specify a value, Amazon Lookout for Vision returns normal and anomalous images.

Length Constraints: Minimum length of 1. Maximum length of 10.

Pattern: (normal|anomaly)

BeforeCreationDate

Only includes entries before the specified date in the response. For example, 2020-06-23T00:00:00.

datasetType

The type of the dataset that you want to list. Specify train to list the training dataset. Specify test to list the test dataset. If you have a single dataset project, specify train.

Length Constraints: Minimum length of 1. Maximum length of 10.

Pattern: train|test

Required: Yes

Labeled

Specify true to include labeled entries, otherwise specify false. If you don't specify a value, Lookout for Vision returns all entries.

MaxResults

The maximum number of results to return per paginated call. The largest value you can specify is 100. If you specify a value greater than 100, a ValidationException error occurs. The default value is 100.

Valid Range: Minimum value of 1. Maximum value of 100.

NextToken

If the previous response was incomplete (because there is more data to retrieve), Amazon Lookout for Vision returns a pagination token in the response. You can use this pagination token to retrieve the next set of dataset entries.

Length Constraints: Maximum length of 2048.

Pattern: ^[a-zA-Z0-9\/\+\=]{0,2048}$

projectName

The name of the project that contains the dataset that you want to list.

Length Constraints: Minimum length of 1. Maximum length of 255.

Pattern: [a-zA-Z0-9][a-zA-Z0-9_\-]*

Required: Yes

SourceRefContains

Perform a "contains" search on the values of the source-ref key within the dataset. For example a value of "IMG_17" returns all JSON Lines where the source-ref key value matches *IMG_17*.

Length Constraints: Minimum length of 1. Maximum length of 2048.

Pattern: .*\S.*

Request Body

The request does not have a request body.

Response Syntax

HTTP/1.1 200 Content-type: application/json { "DatasetEntries": [ "string" ], "NextToken": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

DatasetEntries

A list of the entries (JSON Lines) within the dataset.

Type: Array of strings

Length Constraints: Minimum length of 2. Maximum length of 8192.

Pattern: ^\{.*\}$

NextToken

If the response is truncated, Amazon Lookout for Vision returns this token that you can use in the subsequent request to retrieve the next set ofdataset entries.

Type: String

Length Constraints: Maximum length of 2048.

Pattern: ^[a-zA-Z0-9\/\+\=]{0,2048}$

Errors

For information about the errors that are common to all actions, see Common Errors.

AccessDeniedException

You are not authorized to perform the action.

HTTP Status Code: 403

ConflictException

The update or deletion of a resource caused an inconsistent state.

HTTP Status Code: 409

InternalServerException

Amazon Lookout for Vision experienced a service issue. Try your call again.

HTTP Status Code: 500

ResourceNotFoundException

The resource could not be found.

HTTP Status Code: 404

ThrottlingException

Amazon Lookout for Vision is temporarily unable to process the request. Try your call again.

HTTP Status Code: 429

ValidationException

An input validation error occured. For example, invalid characters in a project name, or if a pagination token is invalid.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: