There are no argument to pass Feature Group name into get_features() to get multiple feature, in case of duplicate feature name across Feature Group.
Here I have 2 feature group (“iris” and “iris_id_only”) with same name feature “id”.
I tried to get feature “id” and “sepalwidthcm”
df_get_id = featurestore.get_features(["id", "sepalwidthcm"])
I get error:
An error was encountered:
Found the feature with name 'id' in more than one of the featuregroups of the featurestore: 'mewo_project_featurestore', please specify the optional argument 'featuregroup=', the matched featuregroups were: iris_1,iris_id_only_1
Traceback (most recent call last):
File "/srv/hops/anaconda/envs/theenv/lib/python3.6/site-packages/hops/featurestore.py", line 368, in get_features
online=online)
File "/srv/hops/anaconda/envs/theenv/lib/python3.6/site-packages/hops/featurestore_impl/core.py", line 613, in _do_get_features
logical_query_plan.create_logical_plan()
File "/srv/hops/anaconda/envs/theenv/lib/python3.6/site-packages/hops/featurestore_impl/query_planner/logical_query_plan.py", line 32, in create_logical_plan
self._features_query()
File "/srv/hops/anaconda/envs/theenv/lib/python3.6/site-packages/hops/featurestore_impl/query_planner/logical_query_plan.py", line 145, in _features_query
featuregroups_parsed.values())
File "/srv/hops/anaconda/envs/theenv/lib/python3.6/site-packages/hops/featurestore_impl/query_planner/query_planner.py", line 64, in _find_feature
featuregroups_matched_str))
hops.featurestore_impl.exceptions.exceptions.FeatureNameCollisionError: Found the feature with name 'id' in more than one of the featuregroups of the featurestore: 'mewo_project_featurestore', please specify the optional argument 'featuregroup=', the matched featuregroups were: iris_1,iris_id_only_1
The error said I need argument featuregroup
because there are feature name id
in multiple feature_group
. However, when input with featuregroup
df_get_id = featurestore.get_features(["id", "sepalwidthcm"], featuregroup="iris")
get_features
don’t have featuregroup
An error was encountered:
get_features() got an unexpected keyword argument 'featuregroup'
Traceback (most recent call last):
TypeError: get_features() got an unexpected keyword argument 'featuregroup'
Calling get_feature single feature each time is not convenient because I have to do the joining manually. If I cannot get id
with another feature, how I am suppose to do the joinning ?
Happen on demo cluster version 1.4