等烈日重来 2025-10-13 10:59 采纳率: 0%
浏览 9

安装diff-gaussian-rasterzation报错

3DGS相关项目已经跑通,但是最近突然出现段错误,询问chatgpt说污染了底层内核,让我重装conda环境。不知道会不会有这个影响。在重装conda过程中使用requirements.txt安装diff-gaussian-rasterzation和simple-knn一直报错.在原项目路径里安装又报了段错误和每次都不同的错误。所以重建了文件夹重新拉取了源代码再重新建了conda虚拟环境。仍然报错如下:

Resolved https://github.com/graphdeco-inria/diff-gaussian-rasterization.git to commit 59f5f77e3ddbac3ed9db93ec2cfe99ed6c5d121d
  Running command git submodule update --init --recursive -q
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error
  
  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [16 lines of output]
……
 File "/home/xxx/miniconda3/envs/gs/lib/python3.9/sre_compile.py", line 804, in compile
          return _sre.compile(
      RuntimeError: invalid SRE code
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

再运行一次又报不同的错

 Resolved https://github.com/graphdeco-inria/diff-gaussian-rasterization.git to commit 59f5f77e3ddbac3ed9db93ec2cfe99ed6c5d121d
  Running command git submodule update --init --recursive -q
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error
  
  × python setup.py egg_info did not run successfully.
  │ exit code: -11
  ╰─> [0 lines of output]
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.


尝试降级setuptools为57.5.0仍然报错


```bash
File "/home/xxx/miniconda3/envs/gs/lib/python3.9/enum.py", line 12, in _is_descriptor
          def _is_descriptor(obj):
      SystemError: unknown opcode
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.


有没有遇到相似问题的朋友指导一下,该怎么解决?

  • 写回答

4条回答 默认 最新

  • 阿里嘎多学长 2025-10-13 10:59
    关注

    阿里嘎多学长整理AIGC生成,因移动端显示问题导致当前答案未能完全显示,请使用PC端查看更加详细的解答过程

    问题分析

    你遇到的问题是安装 diff-gaussian-rasterzation 时出现了段错误,之前的 3DGS 项目已经跑通,但是在重装 Conda 环境后仍然出现了问题。

    解决方案

    1. 检查环境: 确保你的 Conda 环境已经重装完成,并且所有依赖包都已经安装。
    2. 检查 requirements.txt: 确保 requirements.txt 文件中的依赖包版本正确,并且没有任何冲突。
    3. 检查 diff-gaussian-rasterzation: 检查 diff-gaussian-rasterzation 的源代码和文档,是否有任何更新或修复。
    4. 尝试降级或升级: 尝试降级或升级 diff-gaussian-rasterzation 到最新或旧版本,观察是否能解决问题。
    5. 检查系统环境: 检查系统环境是否有任何变化,例如系统版本、依赖包版本等。

    核心代码

    # 重装 Conda 环境
    conda create --name myenv --file requirements.txt
    
    # 安装 diff-gaussian-rasterzation
    pip install diff-gaussian-rasterzation
    

    注意

    • 确保在重装 Conda 环境之前备份所有数据和配置。
    • 如果问题仍然存在,请尝试在其他环境中安装 diff-gaussian-rasterzation,观察是否能解决问题。
    评论

报告相同问题?

问题事件

  • 创建了问题 10月13日