mirror of
https://git.freebsd.org/ports.git
synced 2025-04-27 17:16:37 -04:00
math/{,py-}faiss: update 1.9.0 → 1.11.0
Reported by: portscout
This commit is contained in:
parent
7959bc22b2
commit
7a2dc2f8e9
7 changed files with 77 additions and 13 deletions
|
@ -1,11 +1,10 @@
|
|||
PORTNAME= faiss
|
||||
DISTVERSIONPREFIX= v
|
||||
DISTVERSION= 1.9.0
|
||||
PORTREVISION= 1
|
||||
DISTVERSION= 1.11.0
|
||||
CATEGORIES= math
|
||||
|
||||
#PATCH_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/
|
||||
#PATCHFILES= 70c5de13cd9e2ce94181fe67d9a70eb371ecd554.patch:-p1 # fix GTest linkage
|
||||
PATCH_SITES= https://github.com/${GH_ACCOUNT}/${GH_PROJECT}/commit/
|
||||
PATCHFILES= 01c7e647388f9e23fc828059a3fd9c61b43c0740.patch:-p1 # FreeBSD compatibility patch, https://github.com/facebookresearch/faiss/pull/4316
|
||||
|
||||
MAINTAINER= yuri@FreeBSD.org
|
||||
COMMENT= Library for efficient similarity search & clustering of dense vectors
|
||||
|
@ -20,7 +19,9 @@ BROKEN= requires OpenMP support that is missing on this architecture
|
|||
|
||||
BUILD_DEPENDS= openblas>0:math/openblas # faiss links with libopenblasp-rN.N.N.so (installed by default only on amd64,i386), so use non-filename-specific DEPENDS commands
|
||||
RUN_DEPENDS= openblas>0:math/openblas
|
||||
TEST_DEPENDS= googletest>0:devel/googletest
|
||||
TEST_DEPENDS= benchmark>0:devel/benchmark \
|
||||
gflags>0:devel/gflags \
|
||||
googletest>0:devel/googletest
|
||||
|
||||
USES= cmake:testing compiler:c++11-lang localbase:ldflags # tests fail to compile, see https://github.com/facebookresearch/faiss/issues/3913
|
||||
|
||||
|
@ -32,4 +33,6 @@ GH_ACCOUNT= facebookresearch
|
|||
CMAKE_ON= BUILD_SHARED_LIBS
|
||||
CMAKE_OFF= BUILD_TESTING FAISS_ENABLE_GPU FAISS_ENABLE_PYTHON
|
||||
|
||||
# tests as of 1.11.0: 99% tests passed, 1 tests failed out of 132, TestMemoryLeak.ivfflat (Timeout)
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
TIMESTAMP = 1728188633
|
||||
SHA256 (facebookresearch-faiss-v1.9.0_GH0.tar.gz) = a6c3c60811aeec2dd8943a41f3df244bfed12371453d9b10eaf6ba55fafad1d2
|
||||
SIZE (facebookresearch-faiss-v1.9.0_GH0.tar.gz) = 1084439
|
||||
TIMESTAMP = 1745711436
|
||||
SHA256 (facebookresearch-faiss-v1.11.0_GH0.tar.gz) = c5d517da6deb6a6d74290d7145331fc7474426025e2d826fa4a6d40670f4493c
|
||||
SIZE (facebookresearch-faiss-v1.11.0_GH0.tar.gz) = 1138777
|
||||
SHA256 (01c7e647388f9e23fc828059a3fd9c61b43c0740.patch) = 6248c0d69b2309c5b977d6cd0ff75788a6e668b6c6c87c3113bb2e5603273ea4
|
||||
SIZE (01c7e647388f9e23fc828059a3fd9c61b43c0740.patch) = 795
|
||||
|
|
17
math/faiss/files/patch-perf__tests_CMakeLists.txt
Normal file
17
math/faiss/files/patch-perf__tests_CMakeLists.txt
Normal file
|
@ -0,0 +1,17 @@
|
|||
--- perf_tests/CMakeLists.txt.orig 2025-04-26 22:25:16 UTC
|
||||
+++ perf_tests/CMakeLists.txt
|
||||
@@ -7,13 +7,7 @@ set(BENCHMARK_ENABLE_TESTING OFF)
|
||||
project(faiss_perf_tests)
|
||||
set(BENCHMARK_ENABLE_TESTING OFF)
|
||||
|
||||
-include(FetchContent)
|
||||
-FetchContent_Declare(googlebenchmark
|
||||
- GIT_REPOSITORY https://github.com/google/benchmark.git
|
||||
- GIT_TAG main) # need main for benchmark::benchmark
|
||||
-FetchContent_MakeAvailable(
|
||||
- googlebenchmark)
|
||||
-
|
||||
+find_package(benchmark)
|
||||
|
||||
find_package(Threads REQUIRED)
|
||||
find_package(OpenMP REQUIRED)
|
27
math/faiss/files/patch-tests_CMakeLists.txt
Normal file
27
math/faiss/files/patch-tests_CMakeLists.txt
Normal file
|
@ -0,0 +1,27 @@
|
|||
--- tests/CMakeLists.txt.orig 2025-04-26 22:40:11 UTC
|
||||
+++ tests/CMakeLists.txt
|
||||
@@ -50,15 +50,7 @@ endif()
|
||||
target_link_libraries(faiss_test PUBLIC faiss_example_external_module)
|
||||
endif()
|
||||
|
||||
-include(FetchContent)
|
||||
-FetchContent_Declare(
|
||||
- googletest
|
||||
- GIT_REPOSITORY https://github.com/google/googletest.git
|
||||
- GIT_TAG 58d77fa8070e8cec2dc1ed015d66b454c8d78850 # release-1.12.1
|
||||
- OVERRIDE_FIND_PACKAGE)
|
||||
-set(BUILD_GMOCK CACHE BOOL OFF)
|
||||
-set(INSTALL_GTEST CACHE BOOL OFF)
|
||||
-FetchContent_MakeAvailable(googletest)
|
||||
+find_package(GTest CONFIG REQUIRED)
|
||||
|
||||
if(NOT EXISTS ${CMAKE_FIND_PACKAGE_REDIRECTS_DIR}/gtest-config.cmake
|
||||
AND NOT EXISTS ${CMAKE_FIND_PACKAGE_REDIRECTS_DIR}/GTestConfig.cmake)
|
||||
@@ -79,7 +71,6 @@ find_package(OpenMP REQUIRED)
|
||||
endif()
|
||||
|
||||
find_package(OpenMP REQUIRED)
|
||||
-find_package(GTest CONFIG REQUIRED)
|
||||
|
||||
target_link_libraries(faiss_test PRIVATE
|
||||
OpenMP::OpenMP_CXX
|
|
@ -25,14 +25,17 @@ include/faiss/IndexIVFIndependentQuantizer.h
|
|||
include/faiss/IndexIVFPQ.h
|
||||
include/faiss/IndexIVFPQFastScan.h
|
||||
include/faiss/IndexIVFPQR.h
|
||||
include/faiss/IndexIVFRaBitQ.h
|
||||
include/faiss/IndexIVFSpectralHash.h
|
||||
include/faiss/IndexLSH.h
|
||||
include/faiss/IndexLattice.h
|
||||
include/faiss/IndexNNDescent.h
|
||||
include/faiss/IndexNSG.h
|
||||
include/faiss/IndexNeuralNetCodec.h
|
||||
include/faiss/IndexPQ.h
|
||||
include/faiss/IndexPQFastScan.h
|
||||
include/faiss/IndexPreTransform.h
|
||||
include/faiss/IndexRaBitQ.h
|
||||
include/faiss/IndexRefine.h
|
||||
include/faiss/IndexReplicas.h
|
||||
include/faiss/IndexRowwiseMinMax.h
|
||||
|
@ -61,18 +64,23 @@ include/faiss/impl/ProductAdditiveQuantizer.h
|
|||
include/faiss/impl/ProductQuantizer-inl.h
|
||||
include/faiss/impl/ProductQuantizer.h
|
||||
include/faiss/impl/Quantizer.h
|
||||
include/faiss/impl/RaBitQuantizer.h
|
||||
include/faiss/impl/ResidualQuantizer.h
|
||||
include/faiss/impl/ResultHandler.h
|
||||
include/faiss/impl/ScalarQuantizer.h
|
||||
include/faiss/impl/ThreadedIndex-inl.h
|
||||
include/faiss/impl/ThreadedIndex.h
|
||||
include/faiss/impl/code_distance/code_distance-avx2.h
|
||||
include/faiss/impl/code_distance/code_distance-avx512.h
|
||||
include/faiss/impl/code_distance/code_distance-generic.h
|
||||
include/faiss/impl/code_distance/code_distance-sve.h
|
||||
include/faiss/impl/code_distance/code_distance.h
|
||||
include/faiss/impl/index_read_utils.h
|
||||
include/faiss/impl/io.h
|
||||
include/faiss/impl/io_macros.h
|
||||
include/faiss/impl/kmeans1d.h
|
||||
include/faiss/impl/lattice_Zn.h
|
||||
include/faiss/impl/maybe_owned_vector.h
|
||||
include/faiss/impl/platform_macros.h
|
||||
include/faiss/impl/pq4_fast_scan.h
|
||||
include/faiss/impl/residual_quantizer_encode_steps.h
|
||||
|
@ -86,6 +94,7 @@ include/faiss/invlists/InvertedListsIOHook.h
|
|||
include/faiss/invlists/OnDiskInvertedLists.h
|
||||
include/faiss/utils/AlignedTable.h
|
||||
include/faiss/utils/Heap.h
|
||||
include/faiss/utils/NeuralNet.h
|
||||
include/faiss/utils/WorkerThread.h
|
||||
include/faiss/utils/approx_topk/approx_topk.h
|
||||
include/faiss/utils/approx_topk/avx2-inl.h
|
||||
|
@ -106,6 +115,7 @@ include/faiss/utils/fp16.h
|
|||
include/faiss/utils/hamming-inl.h
|
||||
include/faiss/utils/hamming.h
|
||||
include/faiss/utils/hamming_distance/avx2-inl.h
|
||||
include/faiss/utils/hamming_distance/avx512-inl.h
|
||||
include/faiss/utils/hamming_distance/common.h
|
||||
include/faiss/utils/hamming_distance/generic-inl.h
|
||||
include/faiss/utils/hamming_distance/hamdis-inl.h
|
||||
|
@ -117,10 +127,13 @@ include/faiss/utils/quantize_lut.h
|
|||
include/faiss/utils/random.h
|
||||
include/faiss/utils/simdlib.h
|
||||
include/faiss/utils/simdlib_avx2.h
|
||||
include/faiss/utils/simdlib_avx512.h
|
||||
include/faiss/utils/simdlib_emulated.h
|
||||
include/faiss/utils/simdlib_neon.h
|
||||
include/faiss/utils/simdlib_ppc64.h
|
||||
include/faiss/utils/sorting.h
|
||||
include/faiss/utils/transpose/transpose-avx2-inl.h
|
||||
include/faiss/utils/transpose/transpose-avx512-inl.h
|
||||
include/faiss/utils/utils.h
|
||||
lib/libfaiss.so
|
||||
%%DATADIR%%/faiss-config-version.cmake
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
PORTNAME= faiss
|
||||
DISTVERSIONPREFIX= v
|
||||
DISTVERSION= 1.9.0
|
||||
DISTVERSION= 1.11.0
|
||||
CATEGORIES= math
|
||||
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
||||
|
||||
|
@ -30,7 +30,7 @@ WRKSRC_SUBDIR= faiss/python
|
|||
|
||||
CMAKE_ARGS= -DPython_EXECUTABLE:STRING=${PYTHON_CMD}
|
||||
|
||||
TEST_WRKSRC= ${WRKSRC}/../..
|
||||
TEST_WRKSRC= ${WRKSRC}/../../tests
|
||||
TEST_ENV= ${MAKE_ENV} PYTHONPATH=${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}
|
||||
|
||||
post-patch: # remove GPU testcases
|
||||
|
@ -44,4 +44,6 @@ do-install: # see https://github.com/facebookresearch/faiss/issues/2194
|
|||
.endfor
|
||||
cd ${BUILD_WRKSRC} && ${COPYTREE_SHARE} contrib ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/${PORTNAME}
|
||||
|
||||
# tests are broken, see https://github.com/facebookresearch/faiss/issues/4317
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
TIMESTAMP = 1728191400
|
||||
SHA256 (facebookresearch-faiss-v1.9.0_GH0.tar.gz) = a6c3c60811aeec2dd8943a41f3df244bfed12371453d9b10eaf6ba55fafad1d2
|
||||
SIZE (facebookresearch-faiss-v1.9.0_GH0.tar.gz) = 1084439
|
||||
TIMESTAMP = 1745711421
|
||||
SHA256 (facebookresearch-faiss-v1.11.0_GH0.tar.gz) = c5d517da6deb6a6d74290d7145331fc7474426025e2d826fa4a6d40670f4493c
|
||||
SIZE (facebookresearch-faiss-v1.11.0_GH0.tar.gz) = 1138777
|
||||
|
|
Loading…
Add table
Reference in a new issue