-
Notifications
You must be signed in to change notification settings - Fork 998
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
Registering ODFV UDFs that operate on lists of numbers (e.g., cosine similarity of embeddings/vectors) throws an error #1995
Comments
thanks for filing this! we'll take a look at this |
@adchia Thanks! I actually have the fix ready 😄 But feel free to submit it before I do. |
Similar to #1640 . @judahrand @karlhigley , FYI, you may be interested in this as well. |
Yeah, I ran into this today - it looks like an easy fix. I'll stick a PR in over the next few days if you don't get it in. There are plenty of other issues with ODFVs though. |
@judahrand 's comment in #2013 is a good point. Adopting Arrow's data types as a standard could potentially prevent a whole class of type conversion-related bugs, which the linked PR here was related to. And if Arrow Flight RPC is adopted all the way through the client SDKs, that could also potentially remove the need for type conversion related code and improve performance. |
Expected Behavior
Registering ODFV UDFs that operate on lists of numbers (e.g., cosine similarity of embeddings/vectors) should not
throw errors.
Current Behavior
Defining a ODFV UDF such as cosine similarity and then running
feast apply
will result in the following error:Steps to reproduce
Define an ODFV UDF for cosine similarity and try to register it:
Specifications
Possible Solution
Add the following 2 lines to
feast_value_type_to_pandas_type()
intype_map.py
:The text was updated successfully, but these errors were encountered: