win_det_heatmaps icon indicating copy to clipboard operation
win_det_heatmaps copied to clipboard

trainning error

Open zhu-xiao-di opened this issue 2 years ago • 2 comments

Hello, thank you for your work.

When I train my own dataset, the following errors are reported in the verification phase. Can you help me?

in valid in eval Param Tag_threshold 12.0 Param detection_threshold 0.2 Traceback (most recent call last): File "/mnt/Code/win_det_heatmaps/common_pytorch/net_modules.py", line 152, in evalNet rectify = test_config.rectify, winScoreThres = test_config.windowT) File "/mnt/Code/win_det_heatmaps/common_pytorch/group/tag_group.py", line 266, in group_corners_on_tags grouped = parser.parse(np.float32(dets), np.float32(tags), idx, ratio, rectify) # shape=(num_of_windows, 4, 4) File "/mnt/Code/win_det_heatmaps/common_pytorch/group/tag_group.py", line 242, in parse re = self.calc(det, tag, idx) File "/mnt/Code/win_det_heatmaps/common_pytorch/group/tag_group.py", line 178, in calc val_k = [c_pts[:, 2, np.newaxis] for c_pts in coords_in_patch_with_score_id] File "/mnt/Code/win_det_heatmaps/common_pytorch/group/tag_group.py", line 178, in val_k = [c_pts[:, 2, np.newaxis] for c_pts in coords_in_patch_with_score_id] IndexError: too many indices for array: array is 1-dimensional, but 2 were indexed

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "train.py", line 158, in main() File "train.py", line 135, in main config.train.patch_width, config.train.patch_height, final_output_path) File "/mnt/Code/win_det_heatmaps/common_pytorch/net_modules.py", line 155, in evalNet assert 0, (n_s, e, os.path.basename(imdb_list[n_s]['image'])) AssertionError: (0, IndexError('too many indices for array: array is 1-dimensional, but 2 were indexed'), 'result_toushi_2282_6_4.jpg')

zhu-xiao-di avatar Oct 20 '22 07:10 zhu-xiao-di

Hi @zhu-xiao-di , were you able to resolve this issue ?

charvi-077 avatar Jan 31 '24 12:01 charvi-077

Update : I figured out that this issue is same as related to issue #5 We need to have enough data to train again ( even in our case we are using both : our data and facade_dataset as provide in repository, to avoid this error ) , otherwise in evaluation it would not be able to detect the corner points for a given image and end up in this error.

Thanks.

charvi-077 avatar Feb 03 '24 04:02 charvi-077