-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
PERF: asv for import #28239
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
PERF: asv for import #28239
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
very minor comment, merge on green.
def time_import(self): | ||
if PY37: | ||
cmd = [sys.executable, "-X", "importtime", "-c", "import pandas as pd"] | ||
p = subprocess.run(cmd, stderr=subprocess.PIPE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you add a comment for this as 3.7 actually does the timing, where for < 3.7 asv is doing the timing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comment added + green
asv_bench/benchmarks/package.py
Outdated
return total | ||
|
||
cmd = [sys.executable, "-c", "import pandas as pd"] | ||
p = subprocess.run(cmd, stderr=subprocess.PIPE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this a lint error to assign to p?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think it should be, no idea why it isn't. will fix anyway
Thanks @jbrockmendel |
for py37 this uses
-X importtime
to get a more precise number without subprocess overhead. Doesn't actually do anything with it, but what the heck.Couple of unrelated cleanups.