Skip to content

Commit dd47cda

Browse files
committed
Updated README.md for pmcx.
1 parent 82ef430 commit dd47cda

File tree

1 file changed

+32
-21
lines changed

1 file changed

+32
-21
lines changed

pmcx/README.md

Lines changed: 32 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ and Qianqian Fang (2019-2022) <q.fang at neu.edu>
1111
[![Build Status](https://travis-ci.com/fangq/mcx.svg?branch=master)](https://travis-ci.com/fangq/mcx)
1212

1313
This module provides a Python binding for Monte Carlo eXtreme (MCX).
14-
For other binaries, including standalone executable and the MATLAB bindings, see [our website](http://mcx.space).
14+
For other binaries, including the standalone executable and the MATLAB bindings, see [our website](http://mcx.space).
1515

1616
Monte Carlo eXtreme (MCX) is a fast photon transport simulation software for 3D
1717
heterogeneous turbid media. By taking advantage of the massively parallel
@@ -25,9 +25,9 @@ optimized CPU-based MC implementation.
2525
* PIP: ```pip install pmcx``` see https://pypi.org/project/pmcx/
2626

2727
## Runtime Dependencies
28-
* **NVIDIA GPU Driver**: A CUDA-capable NVIDIA GPU and driver is required to run MCX. An up-to-date driver is desired.
29-
The binary wheel distributed over pip runs on drivers with CUDA 10.1 support on Windows and CUDA 9.2 support on Linux,
30-
respectively. For more details on driver versions, see the
28+
* **NVIDIA GPU Driver**: A CUDA-capable NVIDIA GPU and driver is required to run MCX. An up-to-date driver is recommended.
29+
The binary wheel distributed over pip runs on NVIDIA drivers with CUDA 10.1 support on Windows, CUDA 9.2 support on Linux, and
30+
CUDA 10.2 support on macOS, respectively. For more details on driver versions and their CUDA support, see the
3131
[CUDA Release Notes](https://docs.nvidia.com/cuda/cuda-toolkit-release-notes/index.html).
3232
To download the latest driver for your system, see the
3333
[NVIDIA Driver Download Page](https://www.nvidia.com/download/index.aspx).
@@ -47,37 +47,48 @@ using apt-get: `sudo apt-get install python3-bjdata`. See https://pypi.org/proje
4747
## Build Instructions
4848

4949
### Build Dependencies
50-
* **Operating System**: Windows and Linux are fully supported; For macOS, only 10.13 (High Sierra) is supported since
51-
it is the last version of macOS with NVIDIA CUDA support, and only the C/C++ compiler shipped with macOS 10.13 works
52-
with the CUDA toolkit.
53-
* **NVIDIA CUDA Toolkit**: CUDA 7.5 or newer is required. On macOS, 10.2 is the last available CUDA version.
50+
* **Operating System**: Windows and Linux are fully supported; For building MCX on macOS, OSX 10.13 (High Sierra) and
51+
older are highly recommended since 10.13 was the last version of macOS with NVIDIA CUDA support, and matching the CUDA
52+
compiler version with the C/C++ compiler shipped with Xcode is easier. Newer macOS versions can be used for building MCX,
53+
but need to have System Integrity Protection disabled prior to installing the CUDA toolkit due to the NVIDIA installer copying
54+
its payload under the ```/Developer``` directory under root.
55+
* **NVIDIA CUDA Toolkit**: CUDA 7.5 or newer is required. On macOS, 10.2 is the last available CUDA version.
5456
For details on how to install CUDA, see the [CUDA Download Page](https://developer.nvidia.com/cuda-downloads).
5557
The NVIDIA GPU driver of the target system must support the selected CUDA toolkit.
5658
* **Python Interpreter**: Python 3.6 or above. The ```pip``` Python package manager and the ```wheel``` package (available
5759
via ```pip```) are not required but recommended.
5860
* **C/C++ Compiler**: CUDA Toolkit supports only the following compilers:
5961
* GNU GCC for Linux-based distributions.
60-
* Microsoft Visual Studio C/C++ Compiler for Windows
61-
* Apple Clang for macOS
62-
Refer to each OS's online documentations on how to install these compilers.
62+
* Microsoft Visual Studio C/C++ Compiler for Windows.
63+
* Apple Clang for macOS, available via Xcode. The last Xcode version supported by CUDA 10.2 is 10.3. If using an OSX
64+
version higher than 10.15 it can be downloaded and installed from [Apple's Developer Website](https://developer.apple.com/download/)
65+
with an Apple ID. After installation, select the proper Xcode version from the commandline, and set the ```SDKROOT```
66+
environment variable:
67+
```zsh
68+
sudo xcode-select -s /Applications/Xcode_10.3.app/Contents/Developer/
69+
export SDKROOT=/Applications/Xcode_10.3.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
70+
```
71+
72+
Refer to each OS's online documentations for more in-depth information on how to install these compilers.
6373
Note that the version of the C/C++ compiler used must be supported by the CUDA toolkit version. If not, compilation
64-
will fail and the error will notify you of this problem. See the [CUDA Installation Guides](https://developer.nvidia.com/cuda-toolkit-archive)
65-
for more details
74+
will fail with an error notifying you of this problem. See the [CUDA Installation Guides](https://developer.nvidia.com/cuda-toolkit-archive)
75+
for more details.
6676
* **OpenMP**: The installed C/C++ Compiler should have support for [OpenMP](https://www.openmp.org/).
6777
GCC and Microsoft Visual Studio compiler support OpenMP out of the box. Apple Clang, however, requires manual
68-
installation of OpenMP libraries for Apple Clang. The easiest way to do this is via the [Brew](https://brew.sh/) pacakge
69-
manager:
78+
installation of OpenMP libraries for Apple Clang. The easiest way to do this is via the [Brew](https://brew.sh/) package
79+
manager, preferably after selecting the correct Xcode version:
7080
```zsh
7181
brew install libomp
7282
brew link --force libomp
7383
```
7484
75-
* **CMake**: CMake version 3.15 and later is required. Refer to the [CMake website](https://cmake.org/download/) on how to download.
85+
* **CMake**: CMake version 3.15 and later is required. Refer to the [CMake website](https://cmake.org/download/) for more information on how to download.
7686
CMake is also widely available on package managers across all operating systems.
77-
Additionally, on Windows, make sure **C++ CMake tools for Windows** is also installed.
87+
Additionally, on Windows, make sure **Visual Studio's C++ CMake tools for Windows** is also installed by selecting its option
88+
during installation.
7889
* **Zlib Compression Development Headers**: On Linux, this is generally available via the built-in package manager. For
79-
example, on Debian-based distributions like Ubuntu it is available with ```apt``` under the name ```zlib1g-dev```. On
80-
macOS, brew provides it under the name ```zlib```. No packaged versions are available for windows, therefore it must be
90+
example, on Debian-based distributions like Ubuntu it is available via ```apt``` under the name ```zlib1g-dev```. On
91+
macOS, brew provides it under the name ```zlib```. No packaged versions of Zlib are available for windows, therefore it must be
8192
downloaded manually and added to the CMake environment variables in your working Powershell session:
8293
```powershell
8394
curl.exe --retry 3 -kL https://cytranet.dl.sourceforge.net/project/gnuwin32/zlib/1.2.3/zlib-1.2.3-lib.zip --output zlib.zip
@@ -88,7 +99,7 @@ The NVIDIA GPU driver of the target system must support the selected CUDA toolki
8899

89100
### Build Steps
90101
1. Ensure that ```cmake```, ```nvcc``` (NVIDIA CUDA Compiler) and the C/C++ compiler are all located over your ```PATH```.
91-
This can be queried via ```echo $env:PATH``` on Windows or ```echo $PATH```. If not, locate them and add them to the ```PATH```.
102+
This can be queried via ```echo $env:PATH``` on Windows or ```echo $PATH``` on Linux. If not, locate them and add their folder to the ```PATH```.
92103

93104
2. Clone the repository and switch to the ```pmcx/``` folder:
94105
```bash
@@ -97,7 +108,7 @@ This can be queried via ```echo $env:PATH``` on Windows or ```echo $PATH```. If
97108
```
98109

99110
3. Either run ```python setup.py install``` or ```pip install .``` to directly install, or run ```pip wheel .``` to only
100-
build the Python wheels.
111+
build the Python wheel without installing it.
101112

102113

103114
## How to use

0 commit comments

Comments
 (0)