if-net icon indicating copy to clipboard operation
if-net copied to clipboard

errors of running SVR test inference

Open Bingoang opened this issue 4 years ago • 8 comments

Hi,Julian

I really appreciate your great work! I want to run the SVR test inference, but met some problems: I downloaded your SVR trained model "checkpoint_epoch_6.tar" , and the input data "test_inference_example". And I make the folder "if-net-master/experiments/iPC3000_dist-0.5_0.5_sigmas-0.2_0.015_v256_mSVR/checkpoints", and put the "checkpoint_epoch_6.tar" "BMan0201-HD2-O04P05-S_3DSV_H250_W250_res256.npz" "BMan0201-HD2-O04P05-S_3DSV_H250_W250_res256.off" all in the folder. Then I run the command: python generate.py -pointcloud -pc_samples 3000 -std_dev 0.2 0.015 -res 256 -m SVR -checkpoint 6 -batch_points 100000 But something goes wrong:

Loaded checkpoint from: /home/ang/if-net-master/models/../experiments/iPC3000_dist-0.5_0.5_sigmas-0.2_0.015_v256_mSVR/checkpoints/checkpoint_epoch_6.tar
experiments/iPC3000_dist-0.5_0.5_sigmas-0.2_0.015_v256_mSVR/evaluation_6_@256/
<torch.utils.data.dataloader.DataLoader object at 0x7f33bc5d7dd0>
0it [00:00, ?it/s]
Traceback (most recent call last):
  File "generate.py", line 63, in <module>
    gen_iterator(out_path, dataset, gen)
  File "/home/ang/if-net-master/generation_iterator.py", line 29, in gen_iterator
    for i, data in tqdm(enumerate(loader)):
  File "/home/ang/anaconda3/envs/if-net/lib/python3.7/site-packages/tqdm/std.py", line 1165, in __iter__
    for obj in iterable:
  File "/home/ang/anaconda3/envs/if-net/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 560, in __next__
    batch = self.collate_fn([self.dataset[i] for i in indices])
  File "/home/ang/anaconda3/envs/if-net/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 560, in <listcomp>
    batch = self.collate_fn([self.dataset[i] for i in indices])
  File "/home/ang/if-net-master/models/data/voxelized_data_shapenet.py", line 55, in __getitem__
    occupancies = np.unpackbits(np.load(voxel_path)['compressed_occupancies'])
  File "/home/ang/anaconda3/envs/if-net/lib/python3.7/site-packages/numpy/lib/npyio.py", line 422, in load
    fid = open(os_fspath(file), "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'shapenet/data//04256520/8918d572cff6b15df36ecf951968a8b0/voxelized_point_cloud_256res_3000points.npz'

I'm really new to this, and I hope you can give me some advice. Thanks a lot! 2020-11-07 22-21-29folder 2020-11-07 22-22-04error

Bingoang avatar Nov 07 '20 14:11 Bingoang

Hi, you're welcome - looks good.

I'm currently working on a deadline but will come back to you after that. I'll update the code with logic for loading the checkpoint. Might take until start of December though.

Best, Julian

jchibane avatar Nov 07 '20 16:11 jchibane

@jchibane Sounds great! Thank you for your reply and look forward to your update!!

Bingoang avatar Nov 08 '20 00:11 Bingoang

Hi

I was wondering where I can download the test_inference_example. I only found the pretrained models.

kfarivar avatar Nov 19 '20 08:11 kfarivar

I just looked at the generate.py code and saw that the dataset is literally created by a function in the voxelized_data_shapenet.py so it is not surprising it is not working for the single view point cloud input and SVR model. hope we can get the single view human point cloud inference script soon.

kfarivar avatar Nov 19 '20 11:11 kfarivar

Hi

I was wondering where I can download the test_inference_example. I only found the pretrained models.

Oh, there may be something wrong with github. You commented 7 days ago, but it just shows now.╭( T □ T )╮ I downloaded the test_inference_example in this issue: https://github.com/jchibane/if-net/issues/5

Bingoang avatar Nov 26 '20 01:11 Bingoang

Hi all,

I gave you some bits and pieces in Issue #27 that should get you started - I'd also like to include official support for own point clouds in IF-Nets. A PR is welcome or I might do it myself at some point when I find some more time hopefully.

Best, Julian

jchibane avatar Dec 01 '20 14:12 jchibane

Will leave the issue open as a feature request.

jchibane avatar Dec 01 '20 14:12 jchibane

I get the same error: No such file or directory: 'shapenet/data/04379243/e834ef941f7bc9c9e7df9f1005942e3d/boundary_0.1_samples.npz' or No such file or directory: 'shapenet/data/02958343/b0945cdea946d1a363c65629bee30ef9/voxelization_32.npy' while running generate.py or train.py: FileNotFoundError: [Errno 2] No such file or directory: 'shapenet/data/02958343/25de320e58cb3898f43db49cede9f847/voxelization_32.npy'

Can someone please help me. Thanks.

elhamravanbakhsh avatar Aug 12 '22 16:08 elhamravanbakhsh