How to create and deploy AWS Sagemaker using terraform

Is anyone using terraform to create and deploy in Sagemaker? I created a python script to deploy in sagemake but trying to do the same with terraform.

import sagemaker

role = sagemaker.get_execution_role()

model = sagemaker.model.Model(image_uri="xxxxx.dkr.ecr.eu-west-2.amazonaws.com/sagemakerdemo",
                              model_data="s3://sagemaker.test.models/test.tar.gz",
                              role=role
                              )
model.deploy(initial_instance_count=1, instance_type="ml.m5.2xlarge", accelerator_type="ml.eia2.xlarge")