bd3a1021d7d990d5d4a8a71cc0621485af2d09e4,perfkitbenchmarker/linux_virtual_machine.py,LsCpuResults,__init__,#LsCpuResults#Any#,1631

Before Change


      raise ValueError("Core(s) per socket could not be found in lscpu "
                       "value:\n%s" % lscpu)

    match = re.search(r"Socket\(s\):\s*(\d+)$", lscpu, re.MULTILINE)
    if match:
      self.socket_count = int(match.group(1))
    else:
      raise ValueError("Socket(s) count could not be found in lscpu "
                       "value:\n%s" % lscpu)


class JujuMixin(DebianMixin):
  Class to allow running Juju-deployed workloads.

  Bootstraps a Juju environment using the manual provider:

After Change


    self.data = {}
    for line in lscpu.splitlines():
      m = self._KEY_VALUE_RE.match(line)
      if m:
        self.data[m.group("key")] = m.group("value")
      else:
        logging.debug("Ignoring bad lscpu line "%s"", line)

    def GetInt(key):
      if key in self.data and self.data[key].isdigit():
        return int(self.data[key])
      raise ValueError("Could not find integer "{}" in {}".format(
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: bd3a1021d7d990d5d4a8a71cc0621485af2d09e4
Time: 2019-09-03
Author: chriswilkes@google.com
File Name: perfkitbenchmarker/linux_virtual_machine.py
Class Name: LsCpuResults
Method Name: __init__


Project Name: mlpack/benchmarks
Commit Name: a60c0d90de304b8d2768da0e2110527edea96910
Time: 2017-06-29
Author: ryan@ratml.org
File Name: methods/shogun/linear_ridge_regression.py
Class Name: LinearRidgeRegression
Method Name: RunMetrics


Project Name: mlpack/benchmarks
Commit Name: a60c0d90de304b8d2768da0e2110527edea96910
Time: 2017-06-29
Author: ryan@ratml.org
File Name: methods/scikit/linear_ridge_regression.py
Class Name: LinearRidgeRegression
Method Name: RunMetrics