Skip to content

BLD: various test_perf fixes #6235

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
1 commit merged into from Feb 3, 2014
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions vb_suite/test_perf.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
class RevParseAction(argparse.Action):
def __call__(self, parser, namespace, values, option_string=None):
import subprocess
cmd = 'git rev-parse --short {0}'.format(values)
cmd = 'git rev-parse --short -verify {0}^{{commit}}'.format(values)
rev_parse = subprocess.check_output(cmd, shell=True)
setattr(namespace, self.dest, rev_parse.strip())

Expand Down Expand Up @@ -157,6 +157,11 @@ def __call__(self, parser, namespace, values, option_string=None):
action='store_true',
help='when specified with -N, prints the output of describe() per vbench results. ' )

parser.add_argument('--temp-dir',
metavar="PATH",
default=None,
help='Specify temp work dir to use. ccache depends on builds being invoked from consistent directory.' )

parser.add_argument('-q', '--quiet',
default=False,
action='store_true',
Expand Down Expand Up @@ -192,7 +197,8 @@ def profile_comparative(benchmarks):
from vbench.db import BenchmarkDB
from vbench.git import GitRepo
from suite import BUILD, DB_PATH, PREPARE, dependencies
TMP_DIR = tempfile.mkdtemp()

TMP_DIR = args.temp_dir or tempfile.mkdtemp()

try:

Expand Down Expand Up @@ -434,6 +440,10 @@ def print_report(df,h_head=None,h_msg="",h_baseline=None,b_msg=""):

stats_footer = "\n"
if args.stats :
try:
pd.options.display.expand_frame_repr=False
except:
pass
stats_footer += str(df.T.describe().T) + "\n\n"

s+= stats_footer
Expand Down