Skip to main content

projects

Creates, updates, deletes, gets or lists a projects resource.

Overview

Nameprojects
TypeResource
Idaws.rekognition.projects

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
auto_updatestringIndicates whether automatic retraining will be attempted for the versions of the project. Applies only to adapters. (ENABLED, DISABLED)
creation_timestampstring (date-time)The Unix timestamp for the date and time that the project was created.
datasetsarrayInformation about the training and test datasets in the project.
featurestringSpecifies the project that is being customized. (CONTENT_MODERATION, CUSTOM_LABELS)
project_arnstringThe Amazon Resource Name (ARN) of the project. (pattern: <code>(^arn:[a-z\d-]+:rekognition:[a-z\d-]+:\d{12}:project/[a-zA-Z0-9_.-]{1,255}/[0-9]+$)</code>)
statusstringThe current status of the project. (CREATING, CREATED, DELETING)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_projectsselectregionGets information about your Rekognition projects. This operation requires permissions to perform the rekognition:DescribeProjects action.
create_projectinsertregion, ProjectNameCreates a new Amazon Rekognition project. A project is a group of resources (datasets, model versions) that you use to create and manage a Amazon Rekognition Custom Labels Model or custom adapter. You can specify a feature to create the project with, if no feature is specified then Custom Labels is used by default. For adapters, you can also choose whether or not to have the project auto update by using the AutoUpdate argument. This operation requires permissions to perform the rekognition:CreateProject action.
delete_projectdeleteregionDeletes a Amazon Rekognition project. To delete a project you must first delete all models or adapters associated with the project. To delete a model or adapter, see DeleteProjectVersion. DeleteProject is an asynchronous operation. To check if the project is deleted, call DescribeProjects. The project is deleted when the project no longer appears in the response. Be aware that deleting a given project will also delete any ProjectPolicies associated with that project. This operation requires permissions to perform the rekognition:DeleteProject action.
copy_project_versionexecregion, SourceProjectArn, SourceProjectVersionArn, DestinationProjectArn, VersionName, OutputConfigThis operation applies only to Amazon Rekognition Custom Labels. Copies a version of an Amazon Rekognition Custom Labels model from a source project to a destination project. The source and destination projects can be in different AWS accounts but must be in the same AWS Region. You can't copy a model to another AWS service. To copy a model version to a different AWS account, you need to create a resource-based policy known as a project policy. You attach the project policy to the source project by calling PutProjectPolicy. The project policy gives permission to copy the model version from a trusting AWS account to a trusted account. For more information creating and attaching a project policy, see Attaching a project policy (SDK) in the Amazon Rekognition Custom Labels Developer Guide. If you are copying a model version to a project in the same AWS account, you don't need to create a project policy. Copying project versions is supported only for Custom Labels models. To copy a model, the destination project, source project, and source model version must already exist. Copying a model version takes a while to complete. To get the current status, call DescribeProjectVersions and check the value of Status in the ProjectVersionDescription object. The copy operation has finished when the value of Status is COPYING_COMPLETED. This operation requires permissions to perform the rekognition:CopyProjectVersion action.
start_project_versionexecregion, ProjectVersionArn, MinInferenceUnitsThis operation applies only to Amazon Rekognition Custom Labels. Starts the running of the version of a model. Starting a model takes a while to complete. To check the current state of the model, use DescribeProjectVersions. Once the model is running, you can detect custom labels in new images by calling DetectCustomLabels. You are charged for the amount of time that the model is running. To stop a running model, call StopProjectVersion. This operation requires permissions to perform the rekognition:StartProjectVersion action.
stop_project_versionexecregion, ProjectVersionArnThis operation applies only to Amazon Rekognition Custom Labels. Stops a running model. The operation might take a while to complete. To check the current status, call DescribeProjectVersions. Only applies to Custom Labels projects. This operation requires permissions to perform the rekognition:StopProjectVersion action.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Gets information about your Rekognition projects. This operation requires permissions to perform the rekognition:DescribeProjects action.

SELECT
auto_update,
creation_timestamp,
datasets,
feature,
project_arn,
status
FROM aws.rekognition.projects
WHERE region = '{{ region }}' -- required
;

INSERT examples

Creates a new Amazon Rekognition project. A project is a group of resources (datasets, model versions) that you use to create and manage a Amazon Rekognition Custom Labels Model or custom adapter. You can specify a feature to create the project with, if no feature is specified then Custom Labels is used by default. For adapters, you can also choose whether or not to have the project auto update by using the AutoUpdate argument. This operation requires permissions to perform the rekognition:CreateProject action.

INSERT INTO aws.rekognition.projects (
ProjectName,
Feature,
AutoUpdate,
Tags,
region
)
SELECT
'{{ ProjectName }}' /* required */,
'{{ Feature }}',
'{{ AutoUpdate }}',
'{{ Tags }}',
'{{ region }}'
RETURNING
project_arn
;

DELETE examples

Deletes a Amazon Rekognition project. To delete a project you must first delete all models or adapters associated with the project. To delete a model or adapter, see DeleteProjectVersion. DeleteProject is an asynchronous operation. To check if the project is deleted, call DescribeProjects. The project is deleted when the project no longer appears in the response. Be aware that deleting a given project will also delete any ProjectPolicies associated with that project. This operation requires permissions to perform the rekognition:DeleteProject action.

DELETE FROM aws.rekognition.projects
WHERE region = '{{ region }}' --required
;

Lifecycle Methods

This operation applies only to Amazon Rekognition Custom Labels. Copies a version of an Amazon Rekognition Custom Labels model from a source project to a destination project. The source and destination projects can be in different AWS accounts but must be in the same AWS Region. You can't copy a model to another AWS service. To copy a model version to a different AWS account, you need to create a resource-based policy known as a project policy. You attach the project policy to the source project by calling PutProjectPolicy. The project policy gives permission to copy the model version from a trusting AWS account to a trusted account. For more information creating and attaching a project policy, see Attaching a project policy (SDK) in the Amazon Rekognition Custom Labels Developer Guide. If you are copying a model version to a project in the same AWS account, you don't need to create a project policy. Copying project versions is supported only for Custom Labels models. To copy a model, the destination project, source project, and source model version must already exist. Copying a model version takes a while to complete. To get the current status, call DescribeProjectVersions and check the value of Status in the ProjectVersionDescription object. The copy operation has finished when the value of Status is COPYING_COMPLETED. This operation requires permissions to perform the rekognition:CopyProjectVersion action.

EXEC aws.rekognition.projects.copy_project_version
@region='{{ region }}' --required
@@json=
'{
"SourceProjectArn": "{{ SourceProjectArn }}",
"SourceProjectVersionArn": "{{ SourceProjectVersionArn }}",
"DestinationProjectArn": "{{ DestinationProjectArn }}",
"VersionName": "{{ VersionName }}",
"OutputConfig": "{{ OutputConfig }}",
"Tags": "{{ Tags }}",
"KmsKeyId": "{{ KmsKeyId }}"
}'
;