Skip to content

[8.0] [MOD-8198] Introduce INT8 distance functions #570

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

Closed
wants to merge 1 commit into from

Conversation

github-actions[bot]
Copy link

Description

Backport of #560 to 8.0.

* naive implementation of L2

* update

* implment naive disatnce for int8

add cosine to spaces

fix typos in calculator

* imp choose L2 int8 with 256bit loop

add spaces unit tests for int8 L2
add compilation flags
introduce tests/utils for general utils

* imp space bm for int8

change INITIALIZE_BENCHMARKS_SET to INITIALIZE_BENCHMARKS_SET_L2_IP
introduce INITIALIZE_BENCHMARKS_SET_COSINE
fix typos in Choose_INT8_L2_implementation_AVX512F_BW_VL_VNNI name

* fix INITIALIZE_BENCHMARKS_SET_L2_IP and add include to F_BW_VL_VNNI

* rename unit/test_utuils to unit_test_utils

* seed create vec

* format

* implmenet IP + unit test

* ip bm

* format

* implement cosine in ip API

change create_int8_vec to  populate_int8_vec

add compute norm

* use mask sub instead of msk load

* loop size = 512
minimal dim = 32

* add int8 to bm

* reanme to simd64

* convert to int before multiplication

* review comments:

align to vector size ncluding the norm in cosine dist

unit test cover small dim in cosine chooser

* use sizeof(float)instead of 4

* remove int conversion in test_utils::compute_norm

* REVERT!!! malicious test to see if we get to the code

* assert dummt

* fix alignemnt test

* remove assert

* remove cosine alignment

(cherry picked from commit afb5250)
@GuyAv46 GuyAv46 marked this pull request as draft December 17, 2024 05:47
@GuyAv46 GuyAv46 marked this pull request as ready for review December 17, 2024 05:47
@GuyAv46 GuyAv46 requested a review from meiravgri December 17, 2024 05:47
Copy link

codecov bot commented Dec 17, 2024

Codecov Report

Attention: Patch coverage is 95.86207% with 6 lines in your changes missing coverage. Please review.

Project coverage is 96.94%. Comparing base (882c06f) to head (0d0c5ec).

Files with missing lines Patch % Lines
src/VecSim/spaces/spaces.cpp 33.33% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              8.0     #570      +/-   ##
==========================================
- Coverage   96.97%   96.94%   -0.03%     
==========================================
  Files         100      103       +3     
  Lines        5297     5442     +145     
==========================================
+ Hits         5137     5276     +139     
- Misses        160      166       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@meiravgri
Copy link
Collaborator

will backport the entire feature branch

@meiravgri meiravgri closed this Dec 17, 2024
@GuyAv46 GuyAv46 deleted the backport-560-to-8.0 branch May 13, 2025 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant