Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
This PR makes a small change to
environment.yml
so thatconda install
is installed usingconda install
, instead ofpip install
I also modified the supported python versions in
pyproject.toml
to reflect the fact that we aren't supporting <=3.8 as far as I can tell.Finally, I've slightly tweaked the installation instructions in
README.md
.Dependencies
Issues like the one we've just encountered with
chromadb
0.5.4 are going to occur, and it's in these situations where I always seem to end up rediscovering how brittle conda environments with mixed conda and pip dependencies are - see e.g. this article. Concretely, it took me about 5 attempts to create an environment that passed the tests by manually installing the packages in the existingenvironment.yml
.Acknowledging that there is a reasonable case for using conda here since there are several non-Python dependencies that we might one day want to exert control over (but like... will we?), I've changed
environment.yml
so as to useconda install
instead ofpip
wherever possible.I think the direct dependencies we need are
mkl=2024.0
to fix this bugThe rest are I think indirect.
Of the direct dependencies, only scivision and resnet50_cefas cannot be installed using
conda install
.So to me a sensible
environment.yml
looks something like thisIf I then run the following in the root of the repository,
$ conda env create -f environment.yml $ conda activate cyto_39 $ python -m pip install . $ python -m pytest
I get
1 failed, 4 passed, 9 warnings in 4.74s
where the failed test is just the device mismatch mentioned in #5, and easily fixable.Notes
I also have
channel_priority
set tostrict
in my.condarc
, which is now recommended.Some of the failed attempts resulted in
IOError: [Errno 9] Bad file descriptor
for reasons I failed to understand.