-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[improve](function)Refactor distance function return types to float #55442
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
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
run buildall |
Possible file(s) that should be tracked in LFS detected: 🚨The following file(s) exceeds the file size limit:
Consider using |
TPC-H: Total hot run time: 34199 ms |
TPC-DS: Total hot run time: 187005 ms |
ClickBench: Total hot run time: 32.98 s |
FE UT Coverage ReportIncrement line coverage |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
What problem does this PR solve?
This pull request standardizes the return type of all vector distance functions to float across the codebase, ensuring consistency and improving performance for vector similarity search operations.
Related PR: #54276
Release note
None
Check List (For Author)
Test
Behavior changed:
The array type in the distance function parameter cannot contain null values, otherwise a runtime error will occur.
If the sum of squares of x or y in cosine_distance is 0, in this case, return distance 2 directly to avoid division by zero.
Check List (For Reviewer who merge this PR)