Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test the pretrained model with own point cloud data #29

Open
harris56 opened this issue Jul 8, 2022 · 0 comments
Open

Test the pretrained model with own point cloud data #29

harris56 opened this issue Jul 8, 2022 · 0 comments

Comments

@harris56
Copy link

harris56 commented Jul 8, 2022

Hi!
I tried to use my own test ply data(All renamed as the shown format) uploaded to the directory dataset/scannetv2/test to run the test with pretrained model. And I met some bugs when I run test.py. More information is listed below:

CUDA_VISIBLE_DEVICES=0 python test.py --config config/hais_run1_scannet.yaml --pretrain ~/HAIS/HAIS/pretrain/hais_ckpt.pth
/home/harris_huang/HAIS/HAIS/util/config.py:22: YAMLLoadWarning: calling yaml.load() without Loader=... is deprecated, as the default Loader is unsafe. Please read https://msg.pyyaml.org/load for full details.
config = yaml.load(f)
[2022-07-08 13:12:37,754 INFO log.py line 39 8284] ************************ Start Logging ************************
[2022-07-08 13:12:37,768 INFO test.py line 27 8284] Namespace(TEST_NMS_THRESH=0.3, TEST_NPOINT_THRESH=100, TEST_SCORE_THRESH=0.09, batch_size=4, bg_thresh=0.0, block_reps=2, block_residual=True, cal_iou_based_on_mask=True, cal_iou_based_on_mask_start_epoch=200, classes=20, cluster_shift_meanActive=300, config='config/hais_run1_scannet.yaml', data_root='dataset', dataset='scannetv2', dataset_dir='data/scannetv2_inst.py', dist=False, epochs=500, eval=False, exp_path='exp/scannetv2/hais/hais_run1_scannet', fg_thresh=1.0, filename_suffix='_inst_nostuff.pth', fix_module=[], full_scale=[128, 512], ignore_label=-100, input_channel=3, local_rank=0, loss_weight=[1.0, 1.0, 1.0, 1.0], lr=0.001, manual_seed=123, mask_filter_score_feature_thre=0.5, max_npoint=250000, max_proposal_num=200, mode=4, model_dir='model/hais/hais.py', model_name='hais', momentum=0.9, multiplier=0.5, optim='Adam', point_aggr_radius=0.03, prepare_epochs=100, pretrain='/home/harris_huang/HAIS/HAIS/pretrain/hais_ckpt.pth', pretrain_module=[], pretrain_path=None, save_dir='exp', save_freq=16, save_instance=True, save_pt_offsets=False, save_semantic=False, scale=50, score_fullscale=20, score_mode=4, score_scale=50, split='test', step_epoch=200, task='test', test_epoch=500, test_mask_score_thre=-0.5, test_seed=567, test_workers=16, train_workers=8, use_coords=True, use_mask_filter_score_feature=True, use_mask_filter_score_feature_start_epoch=200, using_NMS=False, using_set_aggr_in_testing=True, using_set_aggr_in_training=False, weight_decay=0.0001, width=32)
[2022-07-08 13:12:37,769 INFO test.py line 242 8284] => creating model ...
[2022-07-08 13:12:37,769 INFO test.py line 243 8284] Classes: 20
[2022-07-08 13:12:38,722 INFO test.py line 255 8284] cuda available: True
[2022-07-08 13:12:42,480 INFO test.py line 259 8284] #classifier parameters (model): 30837785
[2022-07-08 13:12:42,563 INFO utils.py line 67 8284] Restore from /home/harris_huang/HAIS/HAIS/pretrain/hais_ckpt.pth
[2022-07-08 13:12:42,825 INFO test.py line 36 8284] >>>>>>>>>>>>>>>> Start Evaluation >>>>>>>>>>>>>>>>
[2022-07-08 13:12:42,882 INFO scannetv2_inst.py line 95 8284] Testing samples (test): 0
Traceback (most recent call last):
File "test.py", line 268, in
test(model, model_fn, data_name, cfg.test_epoch)
File "test.py", line 179, in test
logger.info("whole set inference time: {:.2f}s, latency per frame: {:.2f}ms".format(total_end1, total_end1 / len(dataloader) * 1000))
ZeroDivisionError: float division by zero

It seems like no test data is loaded, how can I solve this issue? thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant