具体报错:
Traceback (most recent call last):
File "infer.py", line 29, in
from ICON import ICON
File "/home/siyuan/ICON/apps/ICON.py", line 36, in
from lib.dataset.mesh_util import SMPLX, update_mesh_shape_prior_losses, get_visibility
File "/home/siyuan/ICON/apps/../lib/dataset/mesh_util.py", line 28, in
from kaolin.ops.mesh import check_sign
File "/home/siyuan/ICON-master/kaolin-master/kaolin/__init__.py", line 1, in
from . import io
File "/home/siyuan/ICON-master/kaolin-master/kaolin/io/__init__.py", line 5, in
from . import render
File "/home/siyuan/ICON-master/kaolin-master/kaolin/io/render.py", line 23, in
from ..render.camera import generate_perspective_projection
File "/home/siyuan/ICON-master/kaolin-master/kaolin/render/__init__.py", line 2, in
from . import mesh
File "/home/siyuan/ICON-master/kaolin-master/kaolin/render/mesh/__init__.py", line 1, in
from .utils import *
File "/home/siyuan/ICON-master/kaolin-master/kaolin/render/mesh/utils.py", line 22, in
from ... import ops
File "/home/siyuan/ICON-master/kaolin-master/kaolin/ops/__init__.py", line 2, in
from . import conversions
File "/home/siyuan/ICON-master/kaolin-master/kaolin/ops/conversions/__init__.py", line 2, in
from .trianglemesh import *
File "/home/siyuan/ICON-master/kaolin-master/kaolin/ops/conversions/trianglemesh.py", line 18, in
from ..mesh.trianglemesh import _unbatched_subdivide_vertices
File "/home/siyuan/ICON-master/kaolin-master/kaolin/ops/mesh/__init__.py", line 3, in
from .check_sign import check_sign
File "/home/siyuan/ICON-master/kaolin-master/kaolin/ops/mesh/check_sign.py", line 42, in
from . import triangle_hash
File "kaolin/cython/ops/mesh/triangle_hash.pyx", line 1, in init kaolin.ops.mesh.triangle_hash
这个报错是由于当前numpy版本较低,网上一般建议升级numpy版本。然而由于其他的依赖原因,我不能升级numpy,最后解决方法为:
从上面可以看到,报错位置在python kaolin库。当时安装kaolin库的时候需要用到numpy,我用的是1.22的numpy安装的。现在用1.21运行报错
卸载kaolin库,先安装1.21版本numpy,再安装kaolin库,运行,不报错!
所以要具体看报错信息,那些库报错具体去改