国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.

這篇具有很好參考價值的文章主要介紹了【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.。希望對大家有所幫助。如果存在錯誤或未考慮完全的地方,請大家不吝賜教,您也可以點擊"舉報違法"按鈕提交疑問。

  • lap是使用Jonker-Volgenant算法求解稠密(LAPJV)或稀疏(LAPMOD)矩陣的線性分配問題求解器
  • 為了使用模塊lap,結(jié)果pip install lap安裝失敗,命令行提示如下:
ERROR: Command errored out with exit status 1:
     command: 'D:\Anaconda3\envs\tensorflow\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\MSI\\AppData\\Local\\Temp\\pip-req-build-9w1k0u2r\\setup.py'"'"'; __file__='"'"'C:\\Users\\MSI\\AppData\\Local\\Temp\\pip-req-build-9w1k0u2r\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\MSI\AppData\Local\Temp\pip-record-xqcdmil9\install-record.txt' --single-version-externally-managed --compile --install-headers 'D:\Anaconda3\envs\tensorflow\Include\lap'
         cwd: C:\Users\MSI\AppData\Local\Temp\pip-req-build-9w1k0u2r\
    Complete output (30 lines):
    Partial import of lap during the build process.
    Generating cython files
    running install
    running build
    running config_cc
    unifing config_cc, config, build_clib, build_ext, build commands --compiler options
    running config_fc
    unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
    running build_src
    build_src
    building extension "lap._lapjv" sources
    building data_files sources
    build_src: building npy-pkg config files
    running build_py
    creating build
    creating build\lib.win-amd64-3.7
    creating build\lib.win-amd64-3.7\lap
    copying lap\lapmod.py -> build\lib.win-amd64-3.7\lap
    copying lap\__init__.py -> build\lib.win-amd64-3.7\lap
    running build_ext
    No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
    customize MSVCCompiler
    customize MSVCCompiler using build_ext
    No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
    customize MSVCCompiler
    Missing compiler_cxx fix for MSVCCompiler
    customize MSVCCompiler using build_ext
    building 'lap._lapjv' extension
    compiling C sources
    error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'D:\Anaconda3\envs\tensorflow\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\MSI\\AppData\\Local\\Temp\\pip-req-build-9w1k0u2r\\setup.py'"'"'; __file__='"'"'C:\\Users\\MSI\\AppData\\Local\\Temp\\pip-req-build-9w1k0u2r\\setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\MSI\AppData\Local\Temp\pip-record-xqcdmil9\install-record.txt' --single-version-externally-managed --compile --install-headers 'D:\Anaconda3\envs\tensorflow\Include\lap' Check the logs for full command output.

一開始在lap的github官網(wǎng)上看見說需要有c的編譯器:lap的官方鏈接

Install from source
Install a C++ compiler (e.g., g++)

Python headers (e.g., python-dev package on Debian/Ubuntu)

Install Cython (>=0.21)

考慮到電腦上并沒有安裝有關(guān)C編譯的軟件,看了下面的解決方案之后:

https://stackoverflow.com/questions/66838238/cython-setup-py-cant-find-installed-visual-c-build-tools/68553226#68553226

  • 首先在命令行中查看自己的MSVC version
python -c "import sys; print(sys.version)"

我的是1916的版本

D:\Program Files (x86)\Microsoft Visual Studio\2017\Community>python -c "import sys; print(sys.version)"
3.7.11 (default, Jul 27 2021, 09:42:29) [MSC v.1916 64 bit (AMD64)]

對應(yīng)的Visual Studio版本是2017,可以在下面的網(wǎng)址自行查看:

https://en.wikipedia.org/wiki/Microsoft_Visual_C%2B%2B

重點來了?。?!
在安裝Visual Studio一開始要選擇工作負(fù)載!我一開始直接默認(rèn),導(dǎo)致我又失敗了!
后面看了這篇博客Microsoft visual C++ build tools安裝包丟失
我已經(jīng)安裝好了,所以需要重新從這里進(jìn)去工作負(fù)載選擇:
【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.

注意!!勾選只用C++的桌面開發(fā)!旁邊的可選保持默認(rèn)就可以了!

【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.文章來源地址http://www.zghlxwxcb.cn/news/detail-443565.html

  • 重新回到命令行pip安裝,安裝成功!
    【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.
    看完之后如果解決問題啦!記得評論點個贊!

到了這里,關(guān)于【python】安裝模塊lap出錯: error: Microsoft Visual C++ 14.0 or greater is required.的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實不符,請點擊違法舉報進(jìn)行投訴反饋,一經(jīng)查實,立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費用

相關(guān)文章

  • 安裝第三方庫,出現(xiàn)“error: Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual……”解決方案

    安裝第三方庫,出現(xiàn)“error: Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual……”解決方案

    .我們再安裝python的各種包時,有時候會出現(xiàn)如下圖情況: 從報錯可以看出,需要安裝 Microsoft Visual C++ 14.0,但是安裝后還是沒有解決。因此只能退一步,從Python安裝包大全中,找到我們想要安裝的包進(jìn)行安裝。步驟如下: 1.在網(wǎng)址中下載安裝包。 2.,這里我選擇gdal包下載。

    2024年02月13日
    瀏覽(33)
  • Python中pip報錯: error: Microsoft Visual C++ 14.0 is required

    Python中pip報錯: error: Microsoft Visual C++ 14.0 is required

    環(huán)境說明 環(huán)境和版本很重要,大量的博客沒有環(huán)境說明和版本介紹,對新人很不友好 系統(tǒng)版本:Windows server 2008r2 Python版本:Python3.7 隨著報錯提示鏈接進(jìn)去一看,居然是按照visual studio的鏈接,我的天,別人不知道這個東西有多大,我tmd是.net開發(fā)人員啊,我不知道它有多大?

    2024年02月11日
    瀏覽(38)
  • 解決yolov5運行環(huán)境——pycocotools >= 2.0 安裝失敗問題 error: Microsoft Visual C++ 14.0 or greater is required.
error: Microsoft Visual C++ 14.0 or greater is required.

    解決yolov5運行環(huán)境——pycocotools >= 2.0 安裝失敗問題 error: Microsoft Visual C++ 14.0 or greater is required. error: Microsoft Visual C++ 14.0 or greater is required.

    在使用pip install pycocotools 安裝時總是失敗 當(dāng)出現(xiàn)該問題時,本人嘗試去百度上搜索相關(guān)的解決方案,嘗試了好多方法還是安裝失敗,失敗的嘗試如下: 嘗試1: 安裝Microsoft Visual C++ Build Tools 2015 ?????????????顯示安裝包都是丟失或損壞,然后本人就去尋找別的版本的M

    2024年02月05日
    瀏覽(34)
  • 安裝pycocotools模塊報錯:Microsoft Visual C++ 14.0 or greater is required

    安裝pycocotools模塊報錯:Microsoft Visual C++ 14.0 or greater is required

    安裝pycocotools模塊,出現(xiàn)報錯: 報錯原因:編譯pycocotools模塊中出現(xiàn)編譯錯誤,需要安裝C++的編譯 解決辦法:安裝確實的C++編譯依賴 安裝Microsoft Visual C++ 14.0對應(yīng)的包: 選擇依賴進(jìn)行安排: 點擊修改或者安裝 可以全部安裝,不過其實沒有必要,因為很多是為了進(jìn)行C++的代碼

    2024年02月12日
    瀏覽(20)
  • 【pycocotools包安裝問題】error: Microsoft Visual C++ 14.0 or greater is required

    【pycocotools包安裝問題】error: Microsoft Visual C++ 14.0 or greater is required

    問題描述: Windows安裝 pip install pycocotools 出現(xiàn)問題。顯示? error: Microsoft Visual C++ 14.0 or greater is required. Get it with \\\"Microsoft C++ Build Tools\\\": https://visualstudiomicrosoft.com/visual-cpp-build-tools/ 解決方法:如果現(xiàn)在你很著急,建議跳過方法一直接看方法二。如果你經(jīng)常去復(fù)現(xiàn)他人的程序,建

    2024年02月06日
    瀏覽(26)
  • python pip error:Microsoft Visual C++ 14.0 or greater is required

    python pip error:Microsoft Visual C++ 14.0 or greater is required

    windows 10平臺下 其他win系列平臺也可參考,因為我用的是Windows10 再安裝python的一些依賴包的時候,突然會報以下錯誤 error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/ 博主是在安裝 package requirements \\\'padd

    2024年02月03日
    瀏覽(26)
  • python install錯誤:error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++

    python install錯誤:error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++

    當(dāng)我們通過“pip install xxx”安裝一些包含C++代碼的包時,通常會發(fā)生安裝失敗并報錯“ error: Microsoft Visual C++ 14.0 or greater is required. Get it with “Microsoft C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/ ” 的情況,這里給出兩種解決方法: Method 1:直接通過鏈接 “h

    2024年02月11日
    瀏覽(27)
  • 已經(jīng)安裝vs依然顯示error: Microsoft Visual C++ 14.0 or greater is required.

    在 Windows 下的 Conda 環(huán)境中 pip install 一些需要現(xiàn)場編譯的庫時經(jīng)常會報錯: 上圖為安裝 pyopenjtalk 時的報錯信息。 我之前遇到這種問題的解決方法是直接下載已經(jīng)在Windows上編譯好的whl文件,然后: 然而該網(wǎng)站并沒有編譯好的 pyopenjtalk 包,因此這次必須解決該錯誤。 根據(jù)微軟

    2024年02月13日
    瀏覽(23)
  • 解決pip安裝報錯 “error: microsoft visual c++ 14.0 or greater is required”

    解決pip安裝報錯 “error: microsoft visual c++ 14.0 or greater is required”

    今天在Windows的anaconda中使用pip安裝工具包的時候出現(xiàn)報錯信息,如下圖所示: 經(jīng)排查發(fā)現(xiàn)主要錯誤是由 “error: microsoft visual c++ 14.0 or greater is required. get it with “microsoft c++ build tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/” 引起的,而這個工具是Microsoft Build Tools for

    2024年02月02日
    瀏覽(52)
  • wordcloud安裝error:Microsoft Visual C++ 14.0 or greater is required.Get it with Microsoft C++ Build解決方

    wordcloud安裝error:Microsoft Visual C++ 14.0 or greater is required.Get it with Microsoft C++ Build解決方

    ??大家好,我是愛編程的喵喵。雙985碩士畢業(yè),現(xiàn)擔(dān)任全棧工程師一職,熱衷于將數(shù)據(jù)思維應(yīng)用到工作與生活中。從事機器學(xué)習(xí)以及相關(guān)的前后端開發(fā)工作。曾在阿里云、科大訊飛、CCF等比賽獲得多次Top名次。喜歡通過博客創(chuàng)作的方式對所學(xué)的知識進(jìn)行總結(jié)與歸納,不僅形

    2024年02月05日
    瀏覽(23)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包