chroma icon indicating copy to clipboard operation
chroma copied to clipboard

[Install issue]: Replit package fails to install and pip install results in error

Open ayk98 opened this issue 2 years ago • 0 comments

What happened?

pip install chromadb results in the following error: Failed to build hnswlib ERROR: Could not build wheels for hnswlib which use PEP 517 and cannot be installed directly

and using Replit's package manager also fails: Replit: Package operation failed.

Versions

python = ">=3.10.0,<3.11" chromadb = "0.3.21"

Relevant log output

In file included from ./hnswlib/hnswlib.h:198,
                   from ./python_bindings/bindings.cpp:6:
  ./hnswlib/bruteforce.h: In instantiation of ‘std::priority_queue<std::pair<dist_t, long unsigned int> > hnswlib::BruteforceSearch<dist_t>::searchKnn(const void*, size_t, hnswlib::BaseFilterFunctor*) const [with dist_t = float; typename std::vector<std::pair<dist_t, long unsigned int>, std::allocator<std::pair<dist_t, long unsigned int> > >::value_type = std::pair<float, long unsigned int>; size_t = long unsigned int]’:
  ./python_bindings/bindings.cpp:841:100:   required from ‘pybind11::object BFIndex<dist_t, data_t>::knnQuery_return_numpy(pybind11::object, size_t, const std::function<bool(long unsigned int)>&) [with dist_t = float; data_t = float; size_t = long unsigned int]’
  ./python_bindings/bindings.cpp:960:44:   required from here
  ./hnswlib/bruteforce.h:105:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
    105 |         for (int i = 0; i < k; i++) {
        |                         ~~^~~
  ./hnswlib/bruteforce.h:113:27: warning: comparison of integer expressions of different signedness: ‘int’ and ‘const size_t’ {aka ‘const long unsigned int’} [-Wsign-compare]
    113 |         for (int i = k; i < cur_element_count; i++) {
        |                         ~~^~~~~~~~~~~~~~~~~~~
  In file included from ./python_bindings/bindings.cpp:6:
  ./hnswlib/hnswlib.h: At global scope:
  ./hnswlib/hnswlib.h:80:13: warning: ‘bool AVX512Capable()’ defined but not used [-Wunused-function]
     80 | static bool AVX512Capable() {
        |             ^~~~~~~~~~~~~
  gcc: fatal error: Killed signal terminated program cc1plus
  compilation terminated.
  error: command '/nix/store/dq0xwmsk1g0i2ayg6pb7y87na2knzylh-gcc-wrapper-11.3.0/bin/gcc' failed with exit code 1
  ----------------------------------------
  ERROR: Failed building wheel for hnswlib
Failed to build hnswlib
ERROR: Could not build wheels for hnswlib which use PEP 517 and cannot be installed directly

ayk98 avatar May 01 '23 01:05 ayk98