aarch64 arm64 部署 stable diffusion webui 笔记 【1】准备 venv 安装pytorch 验证cuda

这篇具有很好参考价值的文章主要介绍了aarch64 arm64 部署 stable diffusion webui 笔记 【1】准备 venv 安装pytorch 验证cuda。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

aarch64 pytorch(没有aarch64对应版本,自行编译)

pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记【2】验证cuda安装 成功_hkNaruto的博客-CSDN博客

创建venv

[root@ceph3 stable-diffusion-webui]# /usr/local/Python-3.10.12/bin/python3 -m venv venv

[root@ceph3 stable-diffusion-webui]# source venv/bin/activate
(venv)[root@ceph3 stable-diffusion-webui]# python3
Python 3.10.12 (main, Sep  4 2023, 10:01:29) [GCC 9.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'torch'
>>> 

发现torch未安装到venv,

安装pyyaml

(venv) [root@ceph3 stable-diffusion-webui]# cd /home/yeqiang/pyyaml-6.0.1/
(venv) [root@ceph3 pyyaml-6.0.1]# python3 setup.py install
日志

(venv) [root@ceph3 pyyaml-6.0.1]# python3 setup.py install
running install
/home/yeqiang/stable-diffusion-webui/venv/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
/home/yeqiang/stable-diffusion-webui/venv/lib/python3.10/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
running bdist_egg
running egg_info
writing lib/PyYAML.egg-info/PKG-INFO
writing dependency_links to lib/PyYAML.egg-info/dependency_links.txt
writing top-level names to lib/PyYAML.egg-info/top_level.txt
reading manifest file 'lib/PyYAML.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'README'
adding license file 'LICENSE'
writing manifest file 'lib/PyYAML.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-aarch64/egg
running install_lib
running build_py
running build_ext
building 'yaml._yaml' extension
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/home/yeqiang/stable-diffusion-webui/venv/include -I/usr/local/Python-3.10.12/include/python3.10 -c yaml/_yaml.c -o build/temp.linux-aarch64-cpython-310/yaml/_yaml.o
gcc: 错误:yaml/_yaml.c:没有那个文件或目录
gcc: 致命错误:没有输入文件
编译中断。
Error compiling module, falling back to pure Python
creating build/bdist.linux-aarch64/egg
creating build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/__init__.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/composer.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/constructor.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/cyaml.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/dumper.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/emitter.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/error.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/events.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/loader.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/nodes.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/parser.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/reader.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/representer.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/resolver.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/scanner.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/serializer.py -> build/bdist.linux-aarch64/egg/yaml
copying build/lib.linux-aarch64-cpython-310/yaml/tokens.py -> build/bdist.linux-aarch64/egg/yaml
creating build/bdist.linux-aarch64/egg/_yaml
copying build/lib.linux-aarch64-cpython-310/_yaml/__init__.py -> build/bdist.linux-aarch64/egg/_yaml
byte-compiling build/bdist.linux-aarch64/egg/yaml/__init__.py to __init__.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/composer.py to composer.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/constructor.py to constructor.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/cyaml.py to cyaml.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/dumper.py to dumper.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/emitter.py to emitter.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/error.py to error.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/events.py to events.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/loader.py to loader.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/nodes.py to nodes.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/parser.py to parser.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/reader.py to reader.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/representer.py to representer.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/resolver.py to resolver.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/scanner.py to scanner.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/serializer.py to serializer.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/yaml/tokens.py to tokens.cpython-310.pyc
byte-compiling build/bdist.linux-aarch64/egg/_yaml/__init__.py to __init__.cpython-310.pyc
creating build/bdist.linux-aarch64/egg/EGG-INFO
copying lib/PyYAML.egg-info/PKG-INFO -> build/bdist.linux-aarch64/egg/EGG-INFO
copying lib/PyYAML.egg-info/SOURCES.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
copying lib/PyYAML.egg-info/dependency_links.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
copying lib/PyYAML.egg-info/top_level.txt -> build/bdist.linux-aarch64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating 'dist/PyYAML-6.0.1-py3.10-linux-aarch64.egg' and adding 'build/bdist.linux-aarch64/egg' to it
removing 'build/bdist.linux-aarch64/egg' (and everything under it)
Processing PyYAML-6.0.1-py3.10-linux-aarch64.egg
Copying PyYAML-6.0.1-py3.10-linux-aarch64.egg to /home/yeqiang/stable-diffusion-webui/venv/lib/python3.10/site-packages
Adding PyYAML 6.0.1 to easy-install.pth file

Installed /home/yeqiang/stable-diffusion-webui/venv/lib/python3.10/site-packages/PyYAML-6.0.1-py3.10-linux-aarch64.egg
Processing dependencies for PyYAML==6.0.1
Finished processing dependencies for PyYAML==6.0.1

安装typing_extensions

(venv) [root@ceph3 yeqiang]# python3 -m pip install /home/yeqiang/typing_extensions-4.7.1-py3-none-any.whl 
Processing ./typing_extensions-4.7.1-py3-none-any.whl
Installing collected packages: typing-extensions
Successfully installed typing-extensions-4.7.1
 

venv内安装编译好的pytorch

(venv) [root@ceph3 ~]# cd /home/yeqiang/pytorch
(venv) [root@ceph3 pytorch]# export PATH=/usr/local/cmake-3.27.4-linux-aarch64/bin:$PATH
(venv) [root@ceph3 pytorch]# python3 setup.py install
当前成果

aarch64 arm64 部署 stable diffusion webui 笔记 【1】准备 venv 安装pytorch 验证cuda,ai,nvidia,stable diffusion,stable diffusion,笔记,pytorch

pip list显示torch未2.0.0a0,实际上是在v2.0.1分支上编译的。

安装import torch需要的依赖

(venv) [root@ceph3 stable-diffusion-webui]# cd /home/yeqiang/pytorch-libs/
(venv) [root@ceph3 pytorch-libs]# python3 -m pip install *.whl
Processing ./filelock-3.12.3-py3-none-any.whl
Processing ./Jinja2-3.1.2-py3-none-any.whl
Processing ./MarkupSafe-2.1.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Processing ./mpmath-1.3.0-py3-none-any.whl
Processing ./networkx-3.1-py3-none-any.whl
Processing ./sympy-1.12-py3-none-any.whl
Requirement already satisfied: typing-extensions>=4.7.1 in /home/yeqiang/stable-diffusion-webui/venv/lib/python3.10/site-packages (from filelock==3.12.3) (4.7.1)
Installing collected packages: mpmath, sympy, networkx, MarkupSafe, filelock, Jinja2
Successfully installed Jinja2-3.1.2 MarkupSafe-2.1.3 filelock-3.12.3 mpmath-1.3.0 networkx-3.1 sympy-1.12

[notice] A new release of pip is available: 23.0.1 -> 23.2.1
[notice] To update, run: pip install --upgrade pip
 

验证venv内的torch+cuda

aarch64 arm64 部署 stable diffusion webui 笔记 【1】准备 venv 安装pytorch 验证cuda,ai,nvidia,stable diffusion,stable diffusion,笔记,pytorch

其他依赖安装待续。文章来源地址https://www.toymoban.com/news/detail-726695.html

到了这里,关于aarch64 arm64 部署 stable diffusion webui 笔记 【1】准备 venv 安装pytorch 验证cuda的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包赞助服务器费用

相关文章

  • pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记

    pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记

    Kylin Linux Advanced Server V10 (Tercel) aarch64安装NVIDIA-Linux-aarch64-520.61.05.run驱动Tesla T4 16G笔记_hkNaruto的博客-CSDN博客 Ubuntu 22.04 x86_64 源码编译 pytorch-v2.0.1 笔记_hkNaruto的博客-CSDN博客 Ubuntu 22.04 x86_64 源码编译 pytorch-v2.0.1 笔记【2】编译成功_hkNaruto的博客-CSDN博客 环境 安装依赖 编译pytho

    2024年02月09日
    浏览(13)
  • D2000 debian 11 arm64 aarch64 wine-ce编译安装,运行win32程序 笔记 【失败】

    D2000 debian 11 arm64 aarch64 wine-ce编译安装,运行win32程序 笔记 【失败】

    下载源码 yeqiang@debian:~/Downloads$ git clone https://gitee.com/wine-ce/wine-ce Cloning into \\\'wine-ce\\\'... remote: Enumerating objects: 102, done. remote: Counting objects: 100% (89/89), done. remote: Compressing objects: 100% (83/83), done. remote: Total 102 (delta 54), reused 1 (delta 1), pack-reused 13 Receiving objects: 100% (102/102), 32.75 KiB | 56

    2024年01月18日
    浏览(18)
  • 飞腾 kylin-server v10 arm64 aarch64 anaconda3 conda 非法指令 Illegal instruction 笔记

    原因: chenghlee  commented on Jun 15, 2021 It\\\'s likely related to the compiler options used to build the linux-aarch64 packages on defaults; basically, Anaconda uses options that target the server-class Neoverse N1/N2 microarchitecture, rather than the application-class Cortex-A* CPUs. Some thought that needs to be put into the  linux-aarch64  and ho

    2024年02月09日
    浏览(19)
  • pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记【2】验证cuda安装 成功

    pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记【2】验证cuda安装 成功

    接上篇 pytorch-v2.0.1 cuda arm64 aarch64 torch 2.0.1+cu118 源码编译笔记_hkNaruto的博客-CSDN博客 由于采用/usr/local/bin/gcc编译,先设置LD_LIBRARY_PATH,再启动python3 import torch报错 # /usr/local/Python-3.10.12/bin/python3 Python 3.10.12 (main, Sep  4 2023, 10:01:29) [GCC 9.2.0] on linux Type \\\"help\\\", \\\"copyright\\\", \\\"credits\\\" or \\\"l

    2024年02月09日
    浏览(20)
  • Ubuntu 20.04 LTS x86_64 安装 stable-diffusion-webui

    Ubuntu 20.04 LTS x86_64 安装 stable-diffusion-webui

    Stability AI GitHub - Stability-AI/stablediffusion: High-Resolution Image Synthesis with Latent Diffusion Models https://github.com/AUTOMATIC1111/stable-diffusion-webui Ubuntu 20.04 LTS 安装 nvidia 驱动 + cuda 11.8 从开始到放弃!_hkNaruto的博客-CSDN博客 打开一个新终端,配置源  编辑~/.condarc 内容如下即可。 注意: 以下方

    2024年02月12日
    浏览(9)
  • Stable Diffusion WebUI 本地部署

    Stable Diffusion WebUI 本地部署

    系统windows10,显卡NVIDIA RTX 2060s,分享一下stable diffusion webui 本地部署过程以及遇到的问题。其中一些环境已搭建或者软件已安装过的,可以直接跳过。 1. 安装git git下载地址 2. 克隆Stable Diffusion WebUI  找一个磁盘空间充裕的目录,如d:,右键点击 git bash here,执行命令: 3

    2024年02月04日
    浏览(8)
  • stable diffusion webui安装部署教程

    stable diffusion webui安装部署教程

    腾讯云服务器,centos 7.6 (默认安装的是1.8 版本的。没有 -c 命令,需要升级) 参考: https://blog.csdn.net/qq_28903377/article/details/86148687 https://blog.csdn.net/qq_42881737/article/details/125803162 无法生效时,把 /usr/bin/git 删除 参考: https://blog.csdn.net/zltliqi/article/details/126449120 修改 python 指向到

    2024年01月23日
    浏览(39)
  • stable diffusion webui的本地部署

    stable diffusion webui的本地部署

    操作系统:windows10,显卡:RTX2060super ,安装时间:2024年3月30日,磁盘占用:20G,+科学上网 安装过程及本文部段落来自: https://github.com/AUTOMATIC1111/stable-diffusion-webui https://www.bilibili.com/read/cv21908940/ https://blog.csdn.net/qq_40276082/article/details/130202548 1.安装python 推荐版本是 3.10.6 ,可

    2024年04月11日
    浏览(11)
  • stable-diffusion-webui部署

    stable-diffusion-webui部署

    Stable Diffusion于2022-08-23开源,点击体验 扩散模型的定义与采样方法 扩散模型通过定义一个不断加噪声的前向过程来将图片逐步变为高斯噪声,再通过定义了一个逆向过程将高斯噪声逐步去噪变为清晰图片以得到采样。 在采样过程中,根据是否添加额外的噪声,可以将扩散模

    2024年01月17日
    浏览(24)
  • Stable Diffusion stable-diffusion-webui开发笔记

    Stable Diffusion stable-diffusion-webui开发笔记

    Stable Diffusion用来文字生成图片,ControlNet就是用来控制构图的,LoRA就是用来控制风格的 。 国内加速官网: mirrors / AUTOMATIC1111 / stable-diffusion-webui · GitCode 安装参考: Stable Diffusion安装与常见错误(+Lora使用)2023年最新安装教程_cycyc123的博客-CSDN博客 保姆级教程:从0到1搭建St

    2024年02月10日
    浏览(23)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包