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

Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab

這篇具有很好參考價值的文章主要介紹了Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab。希望對大家有所幫助。如果存在錯誤或未考慮完全的地方,請大家不吝賜教,您也可以點擊"舉報違法"按鈕提交疑問。

Stable diffusion 報 Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check 錯誤 及 排查解決

背景

先說一下我的顯卡配置 3060Ti ,當剛開始報這個錯誤的時候,發(fā)現(xiàn)基本上很多博主說的都是在 launch.py 或者 webui-user.bat加一個參數(shù) --precision full --no-half --skip-torch-cuda-test ,webui-user.bat是在 set COMMANDLINE_ARGS=后面加或者launch.py是在index_url = os.environ.get('INDEX_URL', "")加。
加上之后確實不報錯了,也能啟動起來,但是簡單跑了一張圖之后,發(fā)現(xiàn)cpu奇高,gpu卻變化不大,而且速度特別慢,這用cpu跑圖也太浪費我的3060Ti了

加參數(shù)治標不治本

發(fā)現(xiàn)問題

偶然間看到這篇文章,看報錯信息和torch有關, 是不是我沒用到GPU的torch,用的是cpu的

Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab
原文地址:https://blog.csdn.net/zcs2632008/article/details/127025294

安裝步驟

因為之前環(huán)境安裝的差不多了,能啟動,cuda也安裝了。所以重點是三四五步

一、NVIDIA一般電腦上都有

二、安裝對應版本的CUDA,我是3060Ti對應的12.0版本,默認路徑是在C盤下的

三、下載對應版本的cuDNN(它是GPU的加速庫)壓縮包,解壓后會看到幾個文件夾 ,內容放到CUDA對應的文件夾(網(wǎng)上很多教程)

四、安裝GPU 版的torch 和torchversion 。主要版本不好找,我CUDA是12.0,但是現(xiàn)在最高的才11.8 ,所以用的11.8

可以參考別人的這篇文章:https://blog.csdn.net/qq_43575504/article/details/129559776

五、用命令卸載掉torch 和torchversion

因為最開始大家安裝的方式不同,我是最普通的安裝方式,有人是直接用的別人封裝好的,我說一下我的接下來是怎么操作

  1. 把項目導入PyCharm
  2. 把torch和torchversion兩個whl文件放到 \stable-diffusion-webui\venv\Lib\site-packages下面了
  3. 在控制臺運行卸載命令和安裝命令
    Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab

先卸載再安裝,路徑改成自己的,別用我的路徑

pip uninstall torch #卸載之前安裝的torch
pip uninstall torchversion

pip install D:\ruanjian\Stable-Diffusion\stable-diffusion-webui\venv\Lib\site-packages\torch-2.0.1+cu1
18-cp310-cp310-win_amd64.whl

 pip install D:\ruanjian\Stable-Diffusion\stable-diffusion-webui\venv\Lib\site-packages\torchvision-0.1
5.2+cu118-cp310-cp310-win_amd64.whl

六、再啟動

把之前添加的--precision full --no-half --skip-torch-cuda-test刪掉
再啟動
Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab
這時候就沒有報錯信息了,再跑圖,也發(fā)現(xiàn)明顯快了不少,而且cpu是正常的。
不熟悉可能會耽誤幾個小時,諸位多點耐心文章來源地址http://www.zghlxwxcb.cn/news/detail-483480.html

深夜解決了這個問題,覺得有網(wǎng)友會有跟我一樣的問題,所以就寫了這篇文章,寫的有些簡略(每一步都能百度到),望海涵,不過知道問題所在了,就好解決了

到了這里,關于Stable diffusion報Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variab的文章就介紹完了。如果您還想了解更多內容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關文章,希望大家以后多多支持TOY模板網(wǎng)!

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

領支付寶紅包贊助服務器費用

相關文章

  • Cause: compileSdkVersion is not specified. Please add it to build.gradle

    新建了個項目,過一段時間之后再去編譯,提示錯誤: 很詫異,啥都沒改,為什么突然就報錯了呢? 于是一一排查,終于找到問題了,我項目APP中,依賴如下: 重點就是這個+,代表一直使用最新的版本,而最新版本有可能對compileSdk,tools版本產生各種要求,從而導致最終的

    2024年02月16日
    瀏覽(25)
  • 解決:Unable to add window -- token android.os.BinderProxy is not valid; is your activity running?

    這個問題是我想存儲已經創(chuàng)建過的彈窗進行復用過程當中出現(xiàn)的報錯,具體代碼請看: 在查看報錯之后可以確定是 Context 上下文的問題。 在創(chuàng)建Dialog時需要在構造方法當中傳遞一個Context,如果這個上下文被銷毀即這個Activity已經走了OnDestroy方法。那么這個上下文就無效了,

    2024年02月09日
    瀏覽(24)
  • Add a spring.config.import=nacos: property to your configuration. If configuration is not required

    Add a spring.config.import=nacos: property to your configuration. If configuration is not required

    問題描述 產生問題的原因是bootstrap.properties比application.properties的優(yōu)先級要高 由于bootstrap.properties是系統(tǒng)級的資源配置文件,是用在程序引導執(zhí)行時更加早期配置信息讀??; 而application.properties是用戶級的資源配置文件,是用來后續(xù)的一些配置所需要的公共參數(shù)。 但是在Sprin

    2024年02月05日
    瀏覽(56)
  • 解決‘_AxesStack‘ object is not callable while using networkx to plot

    在使用 networkx 進行圖數(shù)據(jù)可視化時報錯如題 \\\'_AxesStack\\\' object is not callable while using networkx to plot 。其中matplotlib為3.6.2版本,networkx版本為2.7。 將netwokx升級為最新版本 或直接將 nx.draw 改為 nx.draw_networkx [1] ‘_AxesStack’ object is not callable while using networkx to plot. stackoverflow

    2024年02月15日
    瀏覽(24)
  • Stable Diffusion使用“面部修復”時報TypeError: ‘NoneType‘ object is not subscriptable錯

    Stable Diffusion使用“面部修復”時報TypeError: ‘NoneType‘ object is not subscriptable錯

    Stable Diffusion使用“面部修復”時報TypeError: ‘NoneType’ object is not subscriptable錯 下載【detection_Resnet50_Final.pth】和【parsing_parsenet.pth】到【repositoriesCodeFormerweightsfacelib】目錄下,并重新運行項目即可。 https://github.com/xinntao/facexlib/releases/download/v0.1.0/detection_Resnet50_Final.pth https:/

    2024年02月12日
    瀏覽(26)
  • Error: The user of this service-type is not allowed to use a reversible encryption algorithm

    Error: The user of this service-type is not allowed to use a reversible encryption algorithm

    在交換機或者路由器進行AAA認證時,修改用戶密碼出現(xiàn)以下狀況改如何解決“Error: The user of this service-type is not allowed to use a reversible encryption algorithm”。 配置local-user 用戶名 password cipher報錯.....--此時需要把cipher換成irreversible-cipher。 于是,重新連接交換機修改密碼,換個命令

    2024年02月14日
    瀏覽(21)
  • Stable Diffusion圖生圖報錯TypeError: argument of type ‘NoneType‘ is not iterable如何解決?

    Stable Diffusion圖生圖報錯TypeError: argument of type ‘NoneType‘ is not iterable如何解決?

    之前運行都沒事,突然莫名開始報錯,試了很多方法找不到原因,求大神指路~ ? ?

    2024年02月04日
    瀏覽(26)
  • AnyConnect was not able to establish connection to the specified secure gateway

    AnyConnect was not able to establish connection to the specified secure gateway

    講述一下在使用?Cisco AnyConnect Secure Mobility Client連接公司VPN遇到AnyConnect was not able to establish connection to the specified secure gateway的解決方法。 我的是Win11系統(tǒng)。安裝的版本是3.0。 1:去掉Internet連接共享的勾勾 控制面板-網(wǎng)絡和Internet-網(wǎng)絡和共享中心-更改適配器設置-右擊,點擊屬

    2024年02月11日
    瀏覽(21)
  • 【Ubuntu】【問題】Gitlab:You won‘t be able to pull or push repositories via SSH until you add an SSH key t

    【問題】 Gitlab:You won\\\'t be able to pull or push repositories via SSH until you add an SSH key to your profile 解決辦法: 1 安裝Git sudo apt-get install git-core #驗證是否成功安裝,輸出版本信息即成功。 git --version 2 初始化本地用戶 git config --global user.name 用戶名 git config --global user.email 用戶郵箱 3 生成

    2024年02月05日
    瀏覽(17)
  • 解決gopls was not able to find modules in your workspace.

    解決gopls was not able to find modules in your workspace.

    ?如圖所示,當我的工作區(qū)需要生成兩個go.mod時,就會出現(xiàn)這種情況。即使兩個go.mod不在同一個文件夾下。但只要兩個go.mod所在的文件夾在同一個目錄中就會出現(xiàn)這種報錯,導致程序無法運行。 看網(wǎng)上說,去go的setting.json中添加如下,但嘗試無果。 ?后翻閱相應的go的技術文檔

    2024年02月14日
    瀏覽(28)

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

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

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

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

二維碼1

領取紅包

二維碼2

領紅包