yanx27 / PointASNL

PointASNL: Robust Point Clouds Processing using Nonlocal Neural Networks with Adaptive Sampling (CVPR 2020)
MIT License
260 stars 34 forks source link

Bugs of the "train_scannet_grid.py" script #21

Closed mtli77 closed 4 years ago

mtli77 commented 4 years ago

Hi @yanx27 Thank you for sharing the code! During the train of the Scannet, errors occurs like here:

Traceback (most recent call last): File "train_scannet_grid.py", line 439, in <module> train() File "train_scannet_grid.py", line 246, in train iou, iou_whole = eval_one_epoch(pred, ops, sess, val_init_op, dataset, epoch % FLAGS.snapshot_gap == 0) File "train_scannet_grid.py", line 411, in eval_one_epoch Confs += confusion_matrix(labels, preds, dataset.label_values) File "/home/ubuntu/.conda/envs/tia36/lib/python3.6/site-packages/sklearn/metrics/classification.py", line 253, in confusion_matrix y_type, y_true, y_pred = _check_targets(y_true, y_pred) File "/home/ubuntu/.conda/envs/tia36/lib/python3.6/site-packages/sklearn/metrics/classification.py", line 81, in _check_targets "and {1} targets".format(type_true, type_pred)) ValueError: Classification metrics can't handle a mix of multiclass-multioutput and binary targets It seems that there's something wrong with the sklearn.metrics and confusion_matrix Could you please help me solve this problem? Waiting for your repply!

yanx27 commented 4 years ago

@Violetit Hi, try to update your sklearn to 0.19 version and re-process the data.

mtli77 commented 4 years ago

@Violetit Hi, try to update your sklearn to 0.19 version and re-process the data.

@yanx27 Hi, It has been fixed now, thank you.