babf7c9f50282143ab8efee96a587bf5cb74123f,chainercv/evaluations/eval_semantic_segmentation_iou.py,,calc_semantic_segmentation_confusion,#Any#Any#Any#,6
Before Change
try:
pred_label = next(pred_labels)
gt_label = next(gt_labels)
except StopIteration:
break
if pred_label.ndim != 2 or gt_label.ndim != 2:
raise ValueError("ndim of inputs should be two.")
After Change
for iter_ in (pred_labels, gt_labels):
// This code assumes any iterator does not contain None as its items.
if next(iter_, None) is not None:
raise ValueError("Length of input iterables need to be same")
return confusion
def calc_semantic_segmentation_iou(confusion):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: chainer/chainercv
Commit Name: babf7c9f50282143ab8efee96a587bf5cb74123f
Time: 2017-06-01
Author: yuyuniitani@gmail.com
File Name: chainercv/evaluations/eval_semantic_segmentation_iou.py
Class Name:
Method Name: calc_semantic_segmentation_confusion
Project Name: GPflow/GPflow
Commit Name: be119b0bb043be437f9619c26cf0f9878a6a9090
Time: 2017-09-14
Author: art.art.v@gmail.com
File Name: GPflow/misc.py
Class Name:
Method Name: get_tensor_by_name
Project Name: google/deepvariant
Commit Name: e9e47a5f7f8833a57620d9901515864adc69ec2d
Time: 2019-10-24
Author: pichuan@google.com
File Name: deepvariant/make_examples.py
Class Name: RegionProcessor
Method Name: region_reads