learned-triangulation icon indicating copy to clipboard operation
learned-triangulation copied to clipboard

Can't work

Open devildonkey1392 opened this issue 5 years ago • 9 comments

Can you write a detail build description?

I can't work when I follow the README.

Thanks !

devildonkey1392 avatar Oct 18 '20 04:10 devildonkey1392

Hi!

Can you be any more specific about the issue you're having?

This repo follows a fairly typical python / pytorch workflow. You should be able to run the scripts as in the examples after downloading dependencies. You can either install these dependencies manually, or via the environment.yml file. I suggest using conda to manage dependencies.

nmwsharp avatar Oct 19 '20 02:10 nmwsharp

I build the code in colab.

I use conda to create an environment with environment.yml. Then I want to generate mesh. I use the command

"python src/main_generate_mesh.py path/to/points.ply --weights=saved_model/"

But it doesn't work, the error say that it needs input path.

I try to use command

"python src/main_generate_mesh.py saved_models/ Human_skeleton.ply"

It returns the error about RuntimeError: [polyscope] ERROR: Failed to initialize glfw.

How to fix it?

Thanks for response !

devildonkey1392 avatar Oct 19 '20 08:10 devildonkey1392

Ah, I see. I have never used colab before, though I believe in theory it should work.

I think the error you're seeing is because that program tries to open a GUI window to show you the result. Of course, the GUI cannot be initialized in the colab environment.

A workaround should be to use the --output flag, like

python src/main_generate_mesh.py saved_models/Human_skeleton.ply --output result

this will skip visualization, and save the outputs to a couple of files with names like result_pred_mesh.ply.

nmwsharp avatar Oct 21 '20 02:10 nmwsharp

After using the --output result, the same error occurs.

devildonkey1392 avatar Oct 21 '20 10:10 devildonkey1392

Hm okay, I'm not sure then. I'm confused, because that shouldn't be touching the GUI code at all. Perhaps there is some silly bug.

I'll have to try to get this running on colab myself to debug further... I'll let you know

nmwsharp avatar Oct 21 '20 16:10 nmwsharp

Hello, When I use Miniconda3 to create env with environment.yml, the error happen. Many packages were not found.

My os is window 10.

ResolvePackageNotFound:

  • gstreamer==1.14.0=hb453b48_1
  • kiwisolver==1.0.1=py38he6710b0_0
  • gst-plugins-base==1.14.0=hbbd80ab_1
  • ld_impl_linux-64==2.33.1=h53a641e_7
  • scipy==1.4.1=py38h0b6359f_0
  • mkl-service==2.3.0=py38he904b0f_0
  • mkl_fft==1.0.15=py38ha843d7b_0
  • scikit-learn==0.22.1=py38hd81dba3_0
  • ninja==1.9.0=py38hfd86e86_0
  • libgfortran-ng==7.3.0=hdf63c60_0
  • numpy-base==1.18.1=py38hde5b4d6_1
  • libedit==3.1.20181209=hc058e9b_0
  • libgcc-ng==9.1.0=hdf63c60_0
  • glib==2.63.1=h5a9c865_0
  • mkl_random==1.1.0=py38h962f231_0
  • tk==8.6.8=hbc83047_0
  • pillow==7.0.0=py38hb39fc2d_0
  • readline==7.0=h7b6447c_5
  • sqlite==3.31.1=h7b6447c_0
  • python==3.8.1=h0371630_1
  • tornado==6.0.3=py38h7b6447c_3
  • jpeg==9b=h024ee3a_2
  • grpcio==1.27.2=py38hf8bcb03_0
  • sip==4.19.13=py38he6710b0_0
  • qt==5.9.7=h5867ecd_1
  • zstd==1.3.7=h0b5b093_0
  • libstdcxx-ng==9.1.0=hdf63c60_0
  • libpng==1.6.37=hbc83047_0
  • dbus==1.13.12=h746ee38_0
  • igl==0.4.1=py38h6dc7ae4_0
  • c-ares==1.15.0=h7b6447c_1001
  • pcre==8.43=he6710b0_0
  • freetype==2.9.1=h8a8886c_1
  • libuuid==1.0.3=h1bed415_2
  • ncurses==6.2=he6710b0_0
  • openssl==1.1.1g=h7b6447c_0
  • zlib==1.2.11=h7b6447c_3
  • libxcb==1.13=h1bed415_1
  • expat==2.2.6=he6710b0_0
  • libffi==3.2.1=hd88cf55_4
  • numpy==1.18.1=py38h4f9e942_0
  • pytorch==1.4.0=py3.8_cuda10.1.243_cudnn_0
  • cffi==1.14.0=py38h2e261b9_0
  • fontconfig==2.13.0=h9420a91_0
  • cryptography==2.8=py38h1ba5d50_0
  • libtiff==4.1.0=h2733197_0
  • icu==58.2=h9c2bf20_1
  • protobuf==3.11.4=py38he6710b0_0
  • xz==5.2.4=h14c3975_4
  • cudatoolkit==10.1.243=h6bb024c_0
  • matplotlib-base==3.1.3=py38hef1b27d_0
  • libxml2==2.9.9=hea5a465_1
  • libprotobuf==3.11.4=hd408876_0
  • pyqt==5.9.2=py38h05f1152_4

How can I fix it?

Thanks for response !

lui-shex avatar Oct 24 '20 06:10 lui-shex

@lui-shex

So it turns out, for some crazy reason by default conda includes build-hashes which are specific to your platform in the generated environment.yml. This means that when you try to install on a slightly-different platorm, there are no matching packages, leading to exactly the error you listed---all the packages with hashes have failed.

Apparently you can ask conda to not include the hashes by exporting the environment file with:

conda env export -f environment.yml --no-builds

I regenerated the environment file using that command in 1996e62aaff6d3e2b56c47e4828bc7298d75572a, and also removed a bunch of unneeded packages from the environment.

It should work for you now, let me know if not!

nmwsharp avatar Oct 27 '20 03:10 nmwsharp

@devildonkey1392

Sure enough, there was a silly bug in the script causing it to try to initialize the GUI even with --output specified :) Fixed in eb47e4e255b29442f644b7ac79af632532b27ed1.

It should work now, please give it a try and let me know if anything else seems off!

nmwsharp avatar Oct 27 '20 03:10 nmwsharp

@nmwsharp

It can work ! Thanks for your assistance !

devildonkey1392 avatar Oct 28 '20 11:10 devildonkey1392