nv-tlabs / NKSR

[CVPR 2023 Highlight] Neural Kernel Surface Reconstruction
https://research.nvidia.com/labs/toronto-ai/NKSR
Other
735 stars 43 forks source link

Deploy the environment on the cpu #29

Open tqlhq opened 1 year ago

tqlhq commented 1 year ago

How do I install nksr if I only have a cpu (no gpu) on my computer?

When I run the following code, I get the wrong nksr:

pip install -U nksr -f https://nksr.huangjh.tech/whl/torch-2.0.0+cpu.html

heiwang1997 commented 1 year ago

Hey could you please let us know what are the error messages? What does pip tell you?

tqlhq commented 1 year ago

为了方便描述,我还是用中文吧。 我运行上面说的那行代码之后,终端显示下载成功,但显示下载的nksr版本是0.0.0 这个里面是没有代码里需要的库的。 但是如果我根据readme中提供的指令去下载: pip install -U nksr -f https://nksr.huangjh.tech/whl/torch-2.0.0+cu118.html 我能得到正确的版本,但即使我根据文档内提供的代码: device = torch.device("cpu") reconstructor = nksr.Reconstructor(device) reconstructor.chunk_tmp_device = torch.device("cpu")

input_xyz = ... input_sensor = ...

field = reconstructor.reconstruct( input_xyz, sensor=input_sensor, ..., chunk_size=50.0, # This could be smaller preprocess_fn=nksr.get_estimate_normal_preprocess_fn(64, 85.0) )

Put everything onto CPU.

field.to_("cpu") reconstructor.network.to("cpu")

[WARNING] Slow operation...

mesh = field.extract_dual_mesh(mise_iter=1)

即使我这样修改代码,运行后终端也会报错,大意是找不到nvidia驱动文件。 所以求问大佬,在只有cpu的机器上要怎么部署/运行nksr项目

heiwang1997 commented 1 year ago

感谢你的描述哈,我大概明白了,确实我们写的时候没有考虑只有cpu的情况 我这几天试着弄个cpu的版本哈,稍等

tqlhq commented 1 year ago

好的好的 多谢大佬提供的帮助!!!!

onesahbi commented 10 months ago

你好,我也遇到了下载了0.0.0的版本,然后不能使用的问题,请问对环境有跟电脑的配置有要求吗?例如只能在linux下运行或者pytorch和cude的版本要求