Skip to content

Commit

Permalink
FEAT-modin-project#2553: add ability to run microbenchmarks for old M…
Browse files Browse the repository at this point in the history
…odin version

Signed-off-by: Anatoly Myachev <[email protected]>
  • Loading branch information
anmyachev committed Dec 17, 2020
1 parent d8d58bb commit 37aff6b
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions asv_bench/benchmarks/benchmarks.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,20 @@
import numpy as np
import pandas

from modin.config import TestDatasetSize, AsvImplementation
from .utils import generate_dataframe, RAND_LOW, RAND_HIGH, random_string

ASV_USE_IMPL = AsvImplementation.get()
try:
from modin.config import TestDatasetSize, AsvImplementation

if TestDatasetSize.get() == "Big":
ASV_USE_IMPL = AsvImplementation.get()
ASV_DATASET_SIZE = TestDatasetSize.get()
except ImportError:
# The same benchmarking code can be run for different versions of Modin, so in
# case of an error importing important variables, we'll just use predefined values
ASV_USE_IMPL = "modin"
ASV_DATASET_SIZE = "Big" if pd.DEFAULT_NPARTITIONS >= 32 else "Small"

if ASV_DATASET_SIZE == "Big":
BINARY_OP_DATA_SIZE = [
(5000, 5000, 5000, 5000),
# the case extremely inefficient
Expand Down

0 comments on commit 37aff6b

Please sign in to comment.