get_entity() | FeatureStore Get Method | Teradata Package for Python - get_entity() - Teradata Package for Python

Teradata® Package for Python User Guide

Deployment
VantageCloud
VantageCore
Edition
VMware
Enterprise
IntelliFlex
Product
Teradata Package for Python
Release Number
20.00
Publication Date
March 2025
Content Type
User Guide
Publication ID
B700-4006-200K
ft:locale
en-US
ft:lastEdition
2026-08-13
dita:mapPath
nvi1706202040305.ditamap
dita:ditavalPath
plt1683835213376.ditaval
ft:sourceId
dita
dita:id
rkb1531260709148
Product Category
Teradata Vantage

Use the get_entity() method to retrieve the entity.

Required Parameter

name
Specifies the name of the entity to get.

Example setup

>>> from teradataml import DataFrame, FeatureStore, load_example_data

Example: Retrieve the name of the entity

Create DataFrame on admissions data.

>>> load_example_data("dataframe", "admissions_train")
>>> df = DataFrame("admissions_train")
>>> df
   masters   gpa     stats programming  admitted
id
34     yes  3.85  Advanced    Beginner         0
32     yes  3.46  Advanced    Beginner         0
11      no  3.13  Advanced    Advanced         1
40     yes  3.95    Novice    Beginner         0
38     yes  2.65  Advanced    Beginner         1
36      no  3.00  Advanced      Novice         0
7      yes  2.33    Novice      Novice         1
26     yes  3.57  Advanced    Advanced         1
19     yes  1.98  Advanced    Advanced         0
13      no  4.00  Advanced      Novice         1

Create FeatureStore for repo 'vfs_v1'.

>>> fs = FeatureStore("vfs_v1")
Repo vfs_v1 does not exist. Run FeatureStore.setup() to create the repo and setup FeatureStore.

Set up FeatureStore for this repository.

>>> fs.setup()
True

Create Entity for column 'id' with name 'admissions_id'.

>>> entity = Entity(name='admissions_id', description="Entity for admissions", columns=df.id)

Apply the Entity to FeatureStore 'vfs_v1'.

>>> fs.apply(entity)
True

Get the Entity 'admissions_id' from repo 'vfs_v1'.

>>> entity = fs.get_entity('admissions_id')
>>> entity
Entity(name=admissions_id)