Skip to content

Commit cf16ade

Browse files
committed
setup/readme: Add pure pip-based installation path
1 parent eb0cb5e commit cf16ade

File tree

3 files changed

+29
-7
lines changed

3 files changed

+29
-7
lines changed

Diff for: README.md

+20-4
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,31 @@ This repository contains code for the machine learning part of the paper "Geneti
66

77
## Installation
88

9-
- Get the project from GitHub (either clone or download zip and extract), then `cd` to the project root.
9+
First obtain the project sources (either clone or download zip and extract) and `cd` to the project root. Then choose one of the following installation paths:
1010

11-
- From the project directory execute:
1211

13-
```
12+
### Option 1: with `pip` / virtual environment
13+
14+
Create and activate a new virtual environment, then from the project directory execute:
15+
16+
pip install .
17+
18+
If you encounter PyTorch issues with this setup, please [install PyTorch manually following the official instructions](https://pytorch.org/get-started/locally/)
19+
20+
If you want to use the napari-based GUI, you will also need to [install one of qtpy's supported Qt backends](https://github.com/spyder-ide/qtpy/blob/master/README.md#requirements), for example PyQt5:
21+
22+
pip install pyqt5
23+
24+
This has to be done manually since none of the backends is compatible with all platforms and pip can't auto-select an optimal one.
25+
26+
27+
### Option 2: with `conda`
28+
29+
From the project directory execute:
30+
1431
conda env create -f environment.yml
1532
conda activate emcaps
1633
pip install --no-deps -e .
17-
```
1834

1935

2036
## Running the code

Diff for: pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ classifiers = [
1313
"Programming Language :: Python :: 3",
1414
"License :: OSI Approved :: MIT License",
1515
"Topic :: Scientific/Engineering :: Image Processing",
16-
16+
"Topic :: Scientific/Engineering :: Image Recognition",
1717
]
1818
dynamic = ["version", "dependencies"]
1919

Diff for: requirements.txt

+8-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@ albumentations>=1.0.3
55
hydra-core>=1.2.0
66
imageio>=2.19.3
77
ipython>=8.4.0
8-
magicgui>=0.5.1
9-
napari>=0.4.16
108
matplotlib>=3.5.2
119
numpy>=1.22.4
1210
omegaconf>=2.2.1
@@ -22,3 +20,11 @@ torch>=1.12.1
2220
tqdm>=4.64.0
2321
typing_extensions>=4.2.0
2422
ubelt>=1.1.2
23+
openpyxl>=3.0
24+
25+
# Only needed for napari GUI
26+
magicgui>=0.5.1
27+
napari>=0.4.16
28+
# pyqt5 can be replaced by any other supported qtpy backend depending on your system
29+
# (https://github.com/spyder-ide/qtpy/blob/master/README.md#requirements)
30+
# pyqt5>=5.15.7

0 commit comments

Comments
 (0)