Feature group definitions and feature ingestion
Now that we have the feature set ready for ingestion, let's create the feature definitions and ingest the features into a feature store. For this exercise, as mentioned before, we will be using the SageMaker Feature Store. If you recall from the previous chapters, we always kept feature definitions in a separate notebook, as it is a one-time activity. In this exercise, we are going to try a different method, which is using a conditional statement to create a feature group if it doesn't exist. You can use either of the approaches.
Let's continue in the same notebook and initialize the boto3 session and check whether our feature group exists already or not:
import boto3
FEATURE_GROUP_NAME = "telcom-customer-features"
feature_group_exist = False
client = boto3.client('sagemaker')
response = client.list_feature_groups(
NameContains=FEATURE_GROUP_NAME)
if FEATURE_GROUP_NAME...