7a5f3c1751bc31f0bd5406bab04845461dd8c88a,google/datalab/ml/_summary.py,Summary,get_events,#Summary#Any#,85

Before Change


              index = event_names.index(value.tag)
              dir_event_dict = ret_events[index]
              if dir not in dir_event_dict:
                dir_event_dict[dir] = pd.DataFrame(
                    [[event_time, event.step, value.simple_value]],
                    columns=["time", "step", "value"])
              else:
                df = dir_event_dict[dir]
                // Append a row.
                df.loc[len(df)] = [event_time, event.step, value.simple_value]

After Change


    for idx, dir_event_dict in enumerate(ret_events):
      for df in dir_event_dict.values():
        df.sort_values(by=["time"], inplace=True)
      ret_events[idx] = dict(dir_event_dict)

    return ret_events

  def plot(self, event_names, x_axis="step"):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: googledatalab/pydatalab
Commit Name: 7a5f3c1751bc31f0bd5406bab04845461dd8c88a
Time: 2017-08-08
Author: qimingj@users.noreply.github.com
File Name: google/datalab/ml/_summary.py
Class Name: Summary
Method Name: get_events


Project Name: quiltdata/quilt
Commit Name: f38c4b0ee0433ac0d6696566164fc680f05817af
Time: 2019-10-30
Author: dima@quiltdata.io
File Name: api/python/quilt3/formats.py
Class Name: FormatRegistry
Method Name: all_supported_formats


Project Name: gboeing/osmnx
Commit Name: b013b12999b16e11a5b965ae3ac0c9301c6888fa
Time: 2021-04-05
Author: boeing@usc.edu
File Name: osmnx/distance.py
Class Name:
Method Name: add_edge_lengths