create_tdapi_context | teradataml Azure Extension Library | API Integration - create_tdapi_context Method - Teradata Vantage

Teradata Vantageā„¢ - API Integration Guide for Cloud Machine Learning

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Teradata Vantage
Release Number
1.4
Published
September 2023
Language
English (United States)
Last Update
2023-09-28
dita:mapPath
mgu1643999543506.ditamap
dita:ditavalPath
ayr1485454803741.ditaval
dita:id
mgu1643999543506

Use the create_tdapi_context method to create a TDAPI context to be used to run TDApiClient functions.

Required Arguments:
  • type: Specifies the cloud type of the TDAPI context.

    If the cloud type is Azure, the only accepted value is "azure".

  • datastore_path: Specifies path in Azure datastore.
Optional Argument:
  • datastore_name: Specifies the name of Azure datastore.

    If not provided, default datastore in Azure workspace is used.

Environment Variables

Create the following environment variables before using the module.
  • Required environment variables:
    • AZURE_TENANT_ID: Specifies Azure tenant ID.
    • AZURE_CLIENT_ID: Specifies Azure client ID.
    • AZURE_CLIENT_SECRET: Specifies Azure client key.
    • AZURE_SUB_ID: Specifies Azure subscription ID.
    • AZURE_RG: Specifies Azure resource group.
    • AZURE_WS: Specifies Azure workspace.
    • AZURE_REGION: Specifies Azure region.

Example

This example creates Azure Machine Learning context using "model_data" as parent folder in default datastore.

from tdapiclient import create_tdapi_context, TDApiClient
create_tdapi_context("azure", datastore_path="model_data")