Skip to content

faiss installation issues in conda env #254

@felixsh

Description

@felixsh

I'm trying to install OpenOOD in a conda environment per yaml file, like so:

name: env
channels:
  - pytorch
  - nvidia
  - defaults
dependencies:
  - python=3.12
  - numpy
  - matplotlib
  - scikit-learn
  - scipy
  - tqdm
  - pytorch:pytorch
  - pytorch:torchvision
  - nvidia:pytorch-cuda=12.1
  - pytorch::faiss-gpu
  - cython
  - pip
  - pip:
    - git+https://github.com/Jingkang50/OpenOOD

Building with conda env create --file=env.yaml throws an error saying faiss-gpu>=1.7.2 can not be satisfied.
Changing this to faiss>=1.7.2 in setup.py resolves the issue.

The problem is probably somewhere between pip and conda.
On inspection conda list | grep faiss --> faiss-gpu, but pip list | grep faiss --> faiss and pip can not find the faiss-gpu package.

Not sure if this needs fixing or is a packaging issue with conda, either way the trinity of faiss, faiss-cpu, faiss-gpu is confusing. Maybe this helps somebody else trying to install OpenOOD in a conda env.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions