From c561c92eeac1ab8a74e23ec1d0adc8262171c6d5 Mon Sep 17 00:00:00 2001 From: rasbt Date: Sat, 26 Apr 2014 14:48:28 -0400 Subject: [PATCH] row slice benchmark --- .ipynb_checkpoints/timeit_tests-checkpoint.ipynb | 4 +++- benchmarks/timeit_tests.ipynb | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.ipynb_checkpoints/timeit_tests-checkpoint.ipynb b/.ipynb_checkpoints/timeit_tests-checkpoint.ipynb index 59f4d7f..baf4bed 100644 --- a/.ipynb_checkpoints/timeit_tests-checkpoint.ipynb +++ b/.ipynb_checkpoints/timeit_tests-checkpoint.ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:08918c81301f699d85bfad155946f6e0102ce07bb31796cb9bdda23ffb2e22a6" + "signature": "sha256:ab74fdc9e8ae58388d1fc428599abc86a3d03938d0f51769cef38ab4028d516a" }, "nbformat": 3, "nbformat_minor": 0, @@ -1472,6 +1472,8 @@ "input": [ "import numpy as np\n", "\n", + "# 1st column, e.g., A[:,0,np.newaxis]\n", + "\n", "def colvec_method1(A):\n", " for col in A.T:\n", " colvec = row[:,np.newaxis]\n", diff --git a/benchmarks/timeit_tests.ipynb b/benchmarks/timeit_tests.ipynb index 59f4d7f..baf4bed 100644 --- a/benchmarks/timeit_tests.ipynb +++ b/benchmarks/timeit_tests.ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:08918c81301f699d85bfad155946f6e0102ce07bb31796cb9bdda23ffb2e22a6" + "signature": "sha256:ab74fdc9e8ae58388d1fc428599abc86a3d03938d0f51769cef38ab4028d516a" }, "nbformat": 3, "nbformat_minor": 0, @@ -1472,6 +1472,8 @@ "input": [ "import numpy as np\n", "\n", + "# 1st column, e.g., A[:,0,np.newaxis]\n", + "\n", "def colvec_method1(A):\n", " for col in A.T:\n", " colvec = row[:,np.newaxis]\n",