Creating a trained model - AWS Clean Rooms

Creating a trained model

After you have associated the configured model algorithm to a collaboration, then created and configured an ML input channel, you are ready create a trained model. A trained model is used by members of a collaboration to jointly analyze their data.

Console
To create a trained model in AWS Clean Rooms
  1. Sign in to the AWS Management Console and open the AWS Clean Rooms console with your AWS account (if you haven't yet done so).

  2. In the left navigation pane, choose Collaborations.

  3. On the Collaborations page, choose the collaboration that you want to create a trained model in.

  4. After the collaboration opens, choose the ML models tab, then choose Create trained model.

  5. For Create trained model, for Trained custom model details, enter a Name and optional Description.

  6. For Training data set, choose the ML input channel for this trained model.

  7. For Hyperparameters, specify any algorithm-specific parameters and their intended values. Hyperparameters are specific to the model being trained and are used to fine-tune model training.

  8. For Environment variables, specify any algorithm-specific variables and their intended values. Environment variables are set in the Docker container.

  9. For Service access, choose the Existing service role name that will be used to access this table or choose Create and use a new service role.

  10. For EC2 Resource configuration, specify information about the compute resources that are used for model training. You must specify the Instance type and Volume size that are used.

  11. Choose Create trained model.

API

The member with the ability to train a model starts training by selecting the ML input channel and the model algorithm:

import boto3 acr_ml_client= boto3.client('cleanroomsml') acr_ml_client.create_trained_model( membershipIdentifier= 'membership_id', configuredModelAlgorithmAssociationArn = 'arn:aws:cleanrooms-ml:region:account:membership/membershipIdentifier/configured-model-algorithm-association/identifier', name='trained_model_name', resourceConfig={ 'instanceType': "ml.m5.xlarge", 'volumeSizeInGB': 1 }, dataChannels=[ { "mlInputChannelArn": channel_arn_1, "channelName": "channel_name" }, { "mlInputChannelArn": channel_arn_2, "channelName": "channel_name" } ] )