Skip to content

Commit

Permalink
[DOCS] TVM install addenda for M1 Macs (#8568)
Browse files Browse the repository at this point in the history
* instructiosn for m1 mac

* typos

* above to below

* nits, link against python issue on github

* correct link

* more cleanup

* correct source

* address chrishoge suggestions

Co-authored-by: Andrew Zhao Luo <andrewzhaoluo@system76-pc.localdomain>
  • Loading branch information
AndrewZhaoLuo and Andrew Zhao Luo authored Aug 3, 2021
1 parent 804ba27 commit 09e234d
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion docs/install/from_source.rst
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ The minimal building requirements for the ``TVM`` libraries are:
- CMake 3.5 or higher
- We highly recommend to build with LLVM to enable all the features.
- If you want to use CUDA, CUDA toolkit version >= 8.0 is required. If you are upgrading from an older version, make sure you purge the older version and reboot after installation.
- On macOS, you may want to install `Homebrew <https://brew.sh>` to easily install and manage dependencies.
- On macOS, you may want to install `Homebrew <https://brew.sh>`_ to easily install and manage dependencies.
- Python is also required. Avoid using Python 3.9.X+ which is not `supported <https://github.com/apache/tvm/issues/8577>`_. 3.7.X+ and 3.8.X+ should be well supported however.

To install the these minimal pre-requisites on Ubuntu/Debian like
linux operating systems, execute (in a terminal):
Expand All @@ -73,6 +74,15 @@ linux operating systems, execute (in a terminal):
sudo apt-get update
sudo apt-get install -y python3 python3-dev python3-setuptools gcc libtinfo-dev zlib1g-dev build-essential cmake libedit-dev libxml2-dev
Use Homebrew to install the required dependencies for macOS running either the Intel or M1 processors. You must follow the post-installation steps specified by
Homebrew to ensure the dependencies are correctly installed and configured:

.. code:: bash
brew install gcc git cmake
brew install llvm
brew install python@3.8
We use cmake to build the library.
The configuration of TVM can be modified by editing `config.cmake` and/or by passing cmake flags to the command line:
Expand Down Expand Up @@ -293,6 +303,21 @@ like ``virtualenv``.
pip3 install --user tornado psutil xgboost cloudpickle
Note on M1 macs, you may have trouble installing xgboost / scipy. scipy and xgboost requires some additional dependencies to be installed,
including openblas and its dependencies. Use the following commands to install scipy and xgboost with the required dependencies and
configuration. A workaround for this is to do the following commands:

.. code:: bash
brew install openblas gfortran
pip install pybind11 cython pythran  
export OPENBLAS=/opt/homebrew/opt/openblas/lib/
pip install scipy --no-use-pep517
pip install xgboost
Install Contrib Libraries
-------------------------
Expand Down

0 comments on commit 09e234d

Please sign in to comment.