cancel
Showing results for 
Search instead for 
Did you mean: 
Machine Learning
Dive into the world of machine learning on the Databricks platform. Explore discussions on algorithms, model training, deployment, and more. Connect with ML enthusiasts and experts.
cancel
Showing results for 
Search instead for 
Did you mean: 

Problem creating FeatureStore

Cirsa
New Contributor II

Hi,

When trying to create the first table in the Feature Store i get a message: ''DataFrame' object has no attribute 'isEmpty'... but it is not.

So I cannot use the function: feature_store.create_table()

With this code you should be able to reproduce the problem:

#CHUNK 1

raw_data = spark.read.format("delta").load("/databricks-datasets/nyctaxi-with-zipcodes/subsampled")

# CHUNK 2

%sql 

CREATE DATABASE IF NOT EXISTS FS1;

# CHUNK 3

from databricks import feature_store

fs = feature_store.FeatureStoreClient()

fs.create_table(

  name="FS1.XX",

  primary_keys = ["dropoff_zip"],

  df = raw_data ,

  description = "Titanic Passenger Features")

AttributeError: 'DataFrame' object has no attribute 'isEmpty'

1 ACCEPTED SOLUTION

Accepted Solutions

Hubert-Dudek
Esteemed Contributor III

There is no df_train in your code. I have included the link to the feature store API doc. It can be helpful for you. Also, please set DBR to 11.3 LTS, as the API for FeatureStoreClient has changed. https://docs.databricks.com/_static/documents/feature-store-python-api-reference-0-7-0.pdf

View solution in original post

3 REPLIES 3

Hubert-Dudek
Esteemed Contributor III

There is no df_train in your code. I have included the link to the feature store API doc. It can be helpful for you. Also, please set DBR to 11.3 LTS, as the API for FeatureStoreClient has changed. https://docs.databricks.com/_static/documents/feature-store-python-api-reference-0-7-0.pdf

Cirsa
New Contributor II

@Hubert Dudek​Sry about the 'df_train', I forgot to change it (the error I commented is real with the proper DF). 

Changing the DBR to 11.3 LTS solved the problem. Thanks!

Hubert-Dudek
Esteemed Contributor III

Great. Would you mind selecting my answer as the best one?

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group