菜鸟zcc跑DL与报错大战八百回合

1. git clone时出现的“error: RPC failed; curl 92 HTTP/2 stream 5 was not closed cleanly: CANCEL (err 8)”

解决方法:把git地址的https: 改成http:

2. error: 2912 bytes of body are still expectediB | 1.84 MiB/s

解决方法:(1)增容 git config --global http.postBuffer 16000M

(2)深度  git clone url --depth 1

【2024.6.16】3.昨天pytorch3d一直安装不上,报错千奇百怪不管是conda install还是pip install还是clone进来都不行,然后看了一下他要求的

因为MVControl要install的requirements太多了,cuda版本torch版本什么的很容易不兼容,最后发现是我torch是2.3.0所以兼容不了。

所以今天又开了个新环境先装了cuda+torch,紧接着把pytorch3d装上了。

4.tiny-cuda-nn装不上

报错是“ERROR: Could not build wheels for tinycudann, which is required to install pyproject.toml-based projects`”

查了一下还是说我各种版本不兼容的问题。

目前的cuda=12.1,torch=2.2.0+cu121,

有人说把gcc版本升级成8,但我是9.4

【最后解决方法是又开了一个新环境从头开始配的,install完torch torchvision啥的就直接install的tinycuda,安上了】

【2024.6.18】5.配上tinycuda,但是跑的时候出现报错:“undefined symbol: _ZN3c104cuda9SetDeviceEi”

查了半天又是说torch什么的版本不对了。。。。。。。。。。。。。b溃了。。。可能是在装完tinycuda之后install别的东西的时候把torch版本又更改了。不信邪 先重新装一下torch。

pip install torch==2.1.0+cu121 torchvision==0.16.0+cu121 torchaudio==2.1.0+cu121 -f https://download.pytorch.org/whl/torch_stable.html

然后卸了tinycuda重新装一下(再装不上就要紫砂了

好的,重新install成功了

6. ValueError: Could not find a format to read the specified file in single-image mode

程序无法找到适合读取指定文件的格式。这里出现的情况是加载hdr贴图时没有找到加载这个格式图像的方法。解决办法在 util.py 中,改进 load_image_raw 方法以支持多种图像读取方式.

import imageio
from PIL import Image
import numpy as np
import cv2

def load_image_raw(fn):
    try:
        # 尝试使用 imageio 读取图像
        return imageio.imread(fn, format='HDR-FI')
    except Exception as e:
        print(f"imageio 读取失败: {e}")
        try:
            # 尝试使用 PIL 读取图像
            img = Image.open(fn)
            return np.array(img)
        except Exception as e:
            print(f"PIL 读取失败: {e}")
            try:
                # 尝试使用 OpenCV 读取图像
                img = cv2.imread(fn, cv2.IMREAD_UNCHANGED)
                if img is None:
                    raise ValueError(f"无法使用 OpenCV 读取文件 {fn}")
                return img
            except Exception as e:
                print(f"OpenCV 读取失败: {e}")
                raise

def load_image(fn):
    return load_image_raw(fn)

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值