-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FSTORE-980] Helper, primary key and event time columns with feature view #1111
Conversation
python/hsfs/feature_view.py
Outdated
""" | ||
if ( | ||
self._batch_vectors_server is None | ||
or self._single_vector_server._helper_column_prepared_statements is None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe initialise _helper_column_prepared_statements
by default? My concern is when calling init_serving
again, it may interrupt the concurrent call to get_feature_vector.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
python/hsfs/core/vector_server.py
Outdated
self, entries, return_type=None, passed_features=[], allow_missing=False | ||
): | ||
"""Assembles serving vector from online feature store.""" | ||
return result_dict, serving_vector |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
result_dict
only stores the result of the last prepared statement. same for the batch case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure I understood. I just put this in a function to not duplicate the code. It must do the same as here https://github.com/logicalclocks/feature-store-api/blob/master/python/hsfs/core/vector_server.py#L248
Am I missing something?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here
result_dict
store the value of transformed serving_vector
result_dict = self._apply_transformation(serving_vector)
but in the code above
for row in result_proxy:
result_dict = self.deserialize_complex_features(
self._complex_features, row._asdict()
)
serving_vector.update(result_dict)
the last assignment to result_dict is inside a for loop.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is exactly the same code here
for row in result_proxy:
result_dict = self.deserialize_complex_features(
self._complex_features, row._asdict()
)
serving_vector.update(result_dict)
python/hsfs/core/vector_server.py
Outdated
entries, self._helper_column_prepared_statements | ||
) | ||
|
||
# drop serving key names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why drop serving key here even though they are requested by users?
@@ -315,14 +319,14 @@ def get_feature_vectors( | |||
def get_inference_helper(self, entry, return_type): | |||
"""Assembles serving vector from online feature store.""" | |||
|
|||
result_dict, _ = self._vector_result( | |||
serving_vector = self._vector_result( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
need to filter out features which are not helper columns?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
This PR adds/fixes/changes...
JIRA Issue: -
Priority for Review: -
Related PRs: -
How Has This Been Tested?
Checklist For The Assigned Reviewer: