Skip to content

Commit

Permalink
Preliminary fix for setup on Apple M1/M2 silicon
Browse files Browse the repository at this point in the history
Please wait for my confirmation before merging. Tests are currently running.
  • Loading branch information
mgbckr authored Jul 1, 2024
1 parent c6836b4 commit 28b910e
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,25 @@ We generally recommend to use a `conda` environment. It makes installing require

```bash
# setup `conda` repository
conda create -n spacec python==3.9
conda create -n spacec
conda activate spacec

# on Apple M1/M2: make sure things run in an x64 environment
# note: certain algorithms (e.g., clustering) might be very slow on Apple M1/M2
# conda config --env --set subdir osx-64

# install Python
conda install python==3.9

# install `graphviz`
conda install graphviz

# install 'libvips' - only on Mac and Linux
conda install -c conda-forge libvips pyvips openslide-python

# on Apple M1/M2
# pip install numpy==1. werkzeug==2.3.6

# install `SPACEc` from pypi
pip install spacec

Expand All @@ -27,7 +37,7 @@ pip install spacec

# on Apple M1/M2
# conda install tensorflow=2.10.0
# and always import spacec first before importing other packages
# IMPORTANT: always import spacec first before importing any other packages
```

Example tonsil data on [dryad](https://datadryad.org/stash/share/OXTHu8fAybiINGD1S3tIVUIcUiG4nOsjjeWmrvJV-dQ)
Expand Down Expand Up @@ -75,6 +85,10 @@ pip install pyg_lib torch_scatter torch_sparse torch_cluster torch_spline_conv -

```bash
pip install pytest pytest-cov

# Note: before you run `pytest` you might have to deactivate and activate the conda environment first
# conda deactivate; conda activate spacec

pytest
```

Expand Down

0 comments on commit 28b910e

Please sign in to comment.