Python 無痛安裝Dlib (包含Mac 和 Windows)
第一個建議安裝Anaconda!!!Python的版本 推薦為3.6 (其他版本也都可以)
MAC系統
注:我的mac當時已經裝Visual Studio 但我感覺不裝好像沒問題?是以沒寫作為必要步驟但是如果報錯了的兄弟 請自覺安裝visual studio
步驟一 安裝Cmake
步驟二 須安裝的包 (按照從上到下順序)
conda/pip install cmake
conda/pip install boost
conda/pip install dlib
(如果出現 CalledProcessError: Command '[‘cmake’, ‘–build’,o exit status 1. 表示你的dlib 與 python 版本不比對 需要下載下傳 對應版本的 dlib wheel)
Windows系統
對于C語言很不友好的系統總是有很多破事
步驟一 安裝 Visual Studio
https://visualstudio.microsoft.com/
下面這個使用C++的Linux開發 可以先不裝 如果還是報錯裝上就完事(對于不在于記憶體的同學請自己主動的安裝它)
步驟二 安裝Cmake
https://cmake.org/download/
步驟三 接下來則是相同的操作
須安裝的包(按照從上到下順序)
conda/pip install cmake
conda/pip install boost
conda/pip install dlib
(如果出現 CalledProcessError: Command '[‘cmake’, ‘–build’,o exit status 1. 表示你的dlib 與 python 版本不比對 需要下載下傳 對應版本的 dlib wheel)
python 3.8 :
連結:https://pan.baidu.com/s/1wbkYVHNnbDV8hQpoyyUgDw
提取碼:8iql
python 3.7 :
連結:https://pan.baidu.com/s/1QpD6eosOquWKviID6brrDQ
提取碼:xlhb