lancedb / lance

Modern columnar data format for ML and LLMs implemented in Rust. Convert from parquet in 2 lines of code for 100x faster random access, vector index, and data versioning. Compatible with Pandas, DuckDB, Polars, Pyarrow, with more integrations coming..
https://lancedb.github.io/lance/
Apache License 2.0
3.37k stars 175 forks source link

chore: remove type restriction from ArrowFloatType over distance traits #2320

Closed eddyxu closed 3 weeks ago

eddyxu commented 3 weeks ago

No logic change in this PR. It only changes the types used for L2 / Dot / Cosine. This is part of the cleanup to make the code simpler to support Hamming / KMode.

codecov-commenter commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 89.36170% with 15 lines in your changes are missing coverage. Please review.

Project coverage is 80.71%. Comparing base (65221e3) to head (2283b7f).

Files Patch % Lines
rust/lance-linalg/src/distance/cosine.rs 61.53% 10 Missing :warning:
rust/lance-linalg/src/distance/dot.rs 80.76% 5 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #2320 +/- ## ========================================== + Coverage 80.70% 80.71% +0.01% ========================================== Files 191 191 Lines 56695 56654 -41 Branches 56695 56654 -41 ========================================== - Hits 45753 45726 -27 + Misses 8385 8373 -12 + Partials 2557 2555 -2 ``` | [Flag](https://app.codecov.io/gh/lancedb/lance/pull/2320/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=lancedb) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/lancedb/lance/pull/2320/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=lancedb) | `80.71% <89.36%> (+0.01%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=lancedb#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.