<jupyter_start><jupyter_text>Benchmark and Bounds TestsThe purpose of this notebook is to benchmark all of the single GPU cuML algorithms against their skLearn counterparts, while also providing the ability to find and verify upper bounds.Each benchmark returns a Panda with the results, which can then be analyzed, manipulated, and stored to disk.   Notebook Credits**Authorship**Original Author: <NAME> Last Edit: <NAME>, 9/25/2019Last Edit: <NAME>, 10/04/2019     Test System SpecsTest System Hardware: DGX-1 Test System Software: Ubuntu 16.04  RAPIDS Version: 0.10.0pre - Conda Install  Driver: 410.48CUDA: 10.0   Known Working SystemsRAPIDS Versions: 0.10+<jupyter_code>import cuml

from cuml.benchmark.runners import SpeedupComparisonRunner
from cuml.benchmark.algorithms import algorithm_by_name


print(cuml.__version__)<jupyter_output><empty_output><jupyter_text>Neighbors  Nearest Neighbors<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("NearestNeighbors"), verbose=True)<jupyter_output><empty_output><jupyter_text>Clustering  DBSCAN<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("DBSCAN"), verbose=True)<jupyter_output><empty_output><jupyter_text>K-means Clustering<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(12, 22)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("KMeans"), verbose=True)<jupyter_output><empty_output><jupyter_text>Manifold Learning  UMAP<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("UMAP"), verbose=True)<jupyter_output><empty_output><jupyter_text>T-SNE<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("TSNE"), verbose=True)<jupyter_output><empty_output><jupyter_text>Linear Models  Linear Regression<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("LinearRegression"), verbose=True)<jupyter_output><empty_output><jupyter_text>Logistic Regression<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("LogisticRegression"), verbose=True)<jupyter_output><empty_output><jupyter_text>Ridge Regression<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("Ridge"), verbose=True)<jupyter_output><empty_output><jupyter_text>Lasso Regression<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("Lasso"), verbose=True)<jupyter_output><empty_output><jupyter_text>ElasticNet Regression<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("ElasticNet"), verbose=True)<jupyter_output><empty_output><jupyter_text>Mini-batch SGD Classifier<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("MBSGDClassifier"))<jupyter_output><empty_output><jupyter_text>Decomposition  PCA<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("PCA"), verbose=True)<jupyter_output><empty_output><jupyter_text>TSVD<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("TSVD"), verbose=True)<jupyter_output><empty_output><jupyter_text>Ensemble  Random Forest Classifier<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("RandomForestClassifier"), verbose=True)<jupyter_output><empty_output><jupyter_text>Random Forest Regressor<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(11, 24)], 
    bench_dims=[64, 128, 256],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("RandomForestClassifier"), verbose=True)<jupyter_output><empty_output><jupyter_text>Random Projection  Gaussian Random Projection<jupyter_code>runner = cuml.benchmark.runners.SpeedupComparisonRunner(
    bench_rows=[2**x for x in range(17, 24)], 
    bench_dims=[100, 500, 1000, 10000],
    dataset_name="blobs",
    input_type="numpy")

results = runner.run(algorithm_by_name("GaussianRandomProjection"), verbose=True)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.12835001614465613, 'fraction_numerical': 0.04036164029706167, 'mean_word_length': 6.8716645489199495, 'pattern_counts': {'":': 0, '<': 72, '<?xml version=': 0, '>': 72, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '17', 'dir': 'jupyter-structured-clean-dedup', 'id': '77945', 'license': 'Apache-2.0', 'n_tokens_mistral': 2404, 'n_tokens_neox': 2142, 'n_words': 360, 'path': 'intermediate_notebooks/benchmarks/cuml_benchmarks.ipynb', 'repo_name': 'ayushdg/notebooks-extended', 'size': '6210'}