显卡绘图器
Autonomys utilizes your drive storage, specifically SSD or NVMe drives, to store farms. After the plotting or replotting process is finished, your CPU then uses these farms to prove challenges. Farming is not particularly demanding on the CPU, enabling most modern processors to manage a substantial farm size. However, the farm creation process is highly resource intensive, which makes CPU plotting the main bottleneck.
Utilizing GPU plotting allows you to harness the power of compatible GPUs for farm generation and replotting, either in conjunction with or as a substitute for CPU processing. While many modern CPUs can complete the plotting of a sector in less than two minutes, a single high performance GPU can accomplish the same task in under five seconds, greatly improving efficiency and speed.
虽然显卡绘图不是强制性的,但与单纯依靠处理器相比,它提供了更高的能效和速度。
平台兼容性
平台 | 🐧 Linux | 🪟 Windows | Nvidia | AMD | Intel |
---|---|---|---|---|---|
CLI | ✅ | ✅ | ✅ | 🛠️ | 🔮 |
Space Acres | ✅ | ✅ | ✅ | 🔜 | 🔮 |
🛠 ️ 部分 AMD 支持**仅限Linux ** 在最近的测试版本中可以使用。最新的测试版本链接在论坛
见Discord farmer-chat 频道获得部分支持。
支持的显卡
- Nvidia
- AMD
- Intel
系列/型号 | 支持 |
---|---|
RTX 20xx 和更新的 | ✅ |
GTX 16 系列 | ✅ |
Nvidia drivers 550 版本或更高。不需要安装 CUDA 工具包
在AMD ROCm 支持方面有许多挑战需要克服。在 论坛 上有关于这个话题的更多信息
您必须使用最新的测试版本以支持AMD。
系列/型号 | Ubuntu | Windows |
---|---|---|
RX 7900 XTX | ✅ | ❌ |
RX 7600 XT | ✅ | ❌ |
RX 7600 | ✅ | ❌ |
RX 6800 | ✅ | ❌ |
RX 6700 XT | ❔ | ❌ |
RX 6700 XT | ✅ | ❌ |
RX 6600 | ✅ | ❌ |
RX 5700 XT | ❌ | ❌ |
RX 5700 | ❌ | ❌ |
RX 5600 | ❌ | ❌ |
AMD BC-250 | ❌ | ❌ |
- 🐧 Ubuntu
- 🪟 Windows
- 🐳 Docker
subspace-farmer-rocm-*
二进制文件提供ROCm 支持,并提供与 CUDA类似的命令行选项,并以--rocm
为前缀。
-
为了安装必要的库,请到 Ubuntu 本机安装 — ROCm install (Linux),并在您的 Ubuntu 版本中按照这些步骤进行:
- 包签名密钥
- 注册 ROCm 包 你不需要自定义驱动程序或完整的 ROCm 工具链来使用已编译的应用程序,因此跳过所有其他步骤。
-
接下来安装一个带ROCm 运行时的软件包:
sudo apt-get install --no-install-recommends hip-runtime-amd
注册库,以便农民可执行程序和其他应用能够找到它:
echo "/opt/rocm/lib" | sudo tee /etc/ld.so.conf.d/rocm.conf > /dev/null
sudo ldconfig -
然后,为了充许用户使用显卡用于计算,你需要把你的用户加入 render 用户组 (请永远不要使用sudo以root身份运行农民二进制程序 🙏 ):
sudo usermod -a -G render $LOGNAME
-
Now you'll need to log out of your user profile and log back in or simply reboot for group changes to take effect and you're ready to go.
AMD GPU 在 Windows 上(包括通过 WSL) 目前不支持。我们希望在未来添加支持。
交叉编译不再需要单独的 Dockerfiles(因此它们被删除),一个文件同时支持本地和交叉编译
容器镜像现在构建为多平台,意味着没有-aarch64后缀和与之相关的麻烦
Aarch64 农民容器镜像现在编译时即支持 CUDA (但常规可执行文件不是)
容器图像现在提供第二个可执行的/subspace-farmer-rocm
(见上文关于为何需要第二个二进制文件的解释)。
以后是如何在 Docker Compose 下使用的演示, 你可以将它作为其他使用案例的灵感:
services:
famer:
image: ghcr.io/autonomys/farmer:TAG
# Beginning of ROCm-specific options
devices:
- /dev/kfd:/dev/kfd
# This will make all GPUs accessible, you can also limit this
# to individual devices like `/dev/dri/renderD128`
- /dev/dri:/dev/dri
security_opt:
- seccomp:unconfined
# `root` user can be replaced with ID of the user on the host system
# that is in `render` group, needed to access `/dev/kfd` device
user: root
entrypoint: /subspace-farmer-rocm
# End of ROCm-specific options
...the rest of typical options you'd normally use
未来可能会支持Intel Arc 显卡,但具体的兼容性细节尚未公布。
常见绘图参数
启用显卡绘图
When a compatible GPU is detected, CPU plotting is automatically disabled by default, but can be re-enabled if needed by specifying number of concurrently encoded sectors: --cpu-sector-encoding-concurrency <SECTORS>
--cpu-sector-encoding-concurrency 2
禁用显卡绘图
--cuda-gpus ""
--cuda-gpus 99
指定具体显卡
Specify particular GPUs for plotting rather than using all available GPUs (the default configuration employs all compatible GPUs): --cuda-gpus <GPU_IDS>
--cuda-gpus 0,1,3
耕种集群
在使用 Farming Cluster 时,特别是使用多个或快速 GPU 时,您可能会遇到网络带宽的限制。高性能 GPU 可以轻松超过 1G 连接的容量。虽然这不会导致进程失败,但可能会导致 GPU 在等待数据传输时闲置。为了优化这种情况下的性能,请考虑将网络升级到 2.5G、10G 或更高。