5b1cfa22c1dc08e92f8a21311728397cfb84ffe1,finetune/utils.py,,finetune_to_indico_sequence,#Any#Any#Any#Any#Any#Any#,298
Before Change
]
if prob_seq is not None:
annotation.append(("confidence", prob_seq))
doc_annotations.add(tuple(annotation) )
doc_annotations = sorted([dict(items) for items in doc_annotations], key=lambda x: x["start"])
annotations.append(doc_annotations)
return raw_texts, annotations
After Change
annotation["confidence"] = confidences
// prevent duplicate annotation edge case
if (annotation_start, annotation_end) not in annotation_ranges:
annotation_ranges.add((annotation_start, annotation_end))
doc_annotations.append(annotation)
doc_annotations = sorted([dict(items) for items in doc_annotations], key=lambda x: x["start"])
annotations.append(doc_annotations)
return raw_texts, annotations
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: IndicoDataSolutions/finetune
Commit Name: 5b1cfa22c1dc08e92f8a21311728397cfb84ffe1
Time: 2018-08-22
Author: madison@indico.io
File Name: finetune/utils.py
Class Name:
Method Name: finetune_to_indico_sequence
Project Name: stanford-mast/nn_dataflow
Commit Name: 4fb88fdc63292d93ce2fdbbf77a4043f18b2c769
Time: 2017-05-03
Author: mgao12@stanford.edu
File Name: nn_dataflow/Network.py
Class Name: Network
Method Name: add
Project Name: onnx/onnx-coreml
Commit Name: fb77632a28e3338cb7e5a0d0c0f2c7ba76cdb984
Time: 2018-03-29
Author: aseem.elec@gmail.com
File Name: onnx_coreml/_transformers.py
Class Name: ReshapeInitTensorFuser
Method Name: __call__