Commit 5d0dbdb0 authored by Your Name's avatar Your Name
Browse files

add whl build and test

parent 57cb8405
...@@ -15,6 +15,8 @@ export LD_LIBRARY_PATH=${ROCM_PATH}/llvm/lib:$LD_LIBRARY_PATH ...@@ -15,6 +15,8 @@ export LD_LIBRARY_PATH=${ROCM_PATH}/llvm/lib:$LD_LIBRARY_PATH
export BUILD_DIR=`pwd` export BUILD_DIR=`pwd`
#######################
#CXX=hipcc CC=hipcc cmake -DFAISS_ENABLE_GPU=ON -DBUILD_SHARED_LIBS=ON -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=DEBUG -DCMAKE_MODULE_PATH="${ROCM_PATH}/hip/cmake/" -DMKL_LIBRARIES=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/ .. #CXX=hipcc CC=hipcc cmake -DFAISS_ENABLE_GPU=ON -DBUILD_SHARED_LIBS=ON -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=DEBUG -DCMAKE_MODULE_PATH="${ROCM_PATH}/hip/cmake/" -DMKL_LIBRARIES=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/ ..
CXX=hipcc CC=hipcc cmake -DFAISS_ENABLE_GPU=ON -DBUILD_SHARED_LIBS=ON -DFAISS_OPT_LEVEL=avx -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=RELEASE -DCMAKE_MODULE_PATH="${ROCM_PATH}/hip/cmake/" -DCMAKE_INSTALL_PREFIX=${BUILD_DIR}/install -DMKL_LIBRARIES=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/libmkl_rt.so .. CXX=hipcc CC=hipcc cmake -DFAISS_ENABLE_GPU=ON -DBUILD_SHARED_LIBS=ON -DFAISS_OPT_LEVEL=avx -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=RELEASE -DCMAKE_MODULE_PATH="${ROCM_PATH}/hip/cmake/" -DCMAKE_INSTALL_PREFIX=${BUILD_DIR}/install -DMKL_LIBRARIES=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/libmkl_rt.so ..
...@@ -29,3 +31,9 @@ cd - ...@@ -29,3 +31,9 @@ cd -
./test_gpu.sh ./test_gpu.sh
cd build/faiss/python
#python3 setup.py -v bdist_wheel
pip3 install dist/faiss-1.7.2-py3-none-any.whl --no-deps --force
cd -
./test_gpu_python.sh
source /opt/dtk-22.04.2/env.sh source /opt/dtk-22.04.2/env.sh
cd /opt/dtk-22.04.2/.hip/
./replace_origin.sh
cd -
export CPLUS_INCLUDE_PATH=${ROCM_PATH}/include:${ROCM_PATH}:/opencl/include export CPLUS_INCLUDE_PATH=${ROCM_PATH}/include:${ROCM_PATH}:/opencl/include
export LD_LIBRARY_PATH=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/:$LD_LIBRARY_PATH export LD_LIBRARY_PATH=/public/software/compiler/intel-compiler-2017.5.239/mkl/lib/intel64_lin/:$LD_LIBRARY_PATH
...@@ -20,14 +25,13 @@ export HIP_VISIBLE_DEVICES=3 ...@@ -20,14 +25,13 @@ export HIP_VISIBLE_DEVICES=3
#export AMD_LOG_LEVEL=4 #export AMD_LOG_LEVEL=4
#export AMD_OCL_WAIT_COMMAND=1 #export AMD_OCL_WAIT_COMMAND=1
#export MKL_DEBUG_CPU_TYPE=5
export MKL_DEBUG_CPU_TYPE=5 #cd build/faiss/python && python3 setup.py build
#cd -
cd build/faiss/python && python3 setup.py build
cd -
#PYTHONPATH="$(ls -d ./build/faiss/python/build/lib*/)" pytest tests/test_*.py #PYTHONPATH="$(ls -d ./build/faiss/python/build/lib*/)" pytest tests/test_*.py
export PYTHONPATH="$(ls -d ./build/faiss/python/build/lib*/)" #export PYTHONPATH="$(ls -d ./build/faiss/python/build/lib*/)"
#pytest -v -s --capture=no -q tests/test_index_accuracy.py #pytest -v -s --capture=no -q tests/test_index_accuracy.py
pytest tests/test_*.py pytest tests/test_*.py
#pytest -v tests/test_fast_scan.py #pytest -v tests/test_fast_scan.py
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment