225d31587eeb9aca226158e346c8e9730777913c,perfkitbenchmarker/publisher.py,,RepublishJSONSamples,#Any#,763

Before Change


        samples.append(raw_dict)
      except Exception as e:
        logging.info("Exception processing sample %s", line)
        logging.info("Exception was: %s", e)
        raise e

  // We can"t use a SampleCollector because SampleCollector.AddSamples depends on
  // having a benchmark and a benchmark_spec.

After Change


    // Chop "|" at the beginning and end of labels and split labels by "|,|"
    fields = sample.pop("labels")[1:-1].split("|,|")
    // Turn the fields into [[key, value], ...]
    key_values = [field.split(":", 1) for field in fields]
    sample["metadata"] = {k: v for k, v in key_values}

  // We can"t use a SampleCollector because SampleCollector.AddSamples depends on
  // having a benchmark and a benchmark_spec.
  publishers = SampleCollector._PublishersFromFlags()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 225d31587eeb9aca226158e346c8e9730777913c
Time: 2017-02-24
Author: nlavine@google.com
File Name: perfkitbenchmarker/publisher.py
Class Name:
Method Name: RepublishJSONSamples


Project Name: google/deepvariant
Commit Name: a8fadfa8f46090930a3dc2befcea1e502de04b91
Time: 2018-01-17
Author: mdepristo@google.com
File Name: deepvariant/make_examples.py
Class Name: OutputsWriter
Method Name: __init__


Project Name: regel/loudml
Commit Name: 55429b5b2799f2bdc27beb78cc10d2649e843cb5
Time: 2019-09-29
Author: sebastien.regel@gmail.com
File Name: loudml/loudml/mongo.py
Class Name: MongoDataSource
Method Name: save_timeseries_prediction


Project Name: allenai/allennlp
Commit Name: 8c2c5903e7f1bbd4bb8391393fec698d0e119dfe
Time: 2020-02-17
Author: sacastro@umich.edu
File Name: allennlp/data/batch.py
Class Name: Batch
Method Name: as_tensor_dict