From fb51ec7e1a570591ac92a71b32085c4f9494037c Mon Sep 17 00:00:00 2001 From: Yufeng Zhang <30943549+yufengzh@users.noreply.github.com> Date: Sat, 22 Jul 2023 21:56:13 -0400 Subject: [PATCH] change slider max index to be within the boundary The cell above generates 100 samples, 50 positive and 50 negative. The index here should be 49. --- lab2/Part2_FaceDetection.ipynb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lab2/Part2_FaceDetection.ipynb b/lab2/Part2_FaceDetection.ipynb index c877149c..0b22ad06 100644 --- a/lab2/Part2_FaceDetection.ipynb +++ b/lab2/Part2_FaceDetection.ipynb @@ -169,8 +169,8 @@ "face_images = images[np.where(labels==1)[0]]\n", "not_face_images = images[np.where(labels==0)[0]]\n", "\n", - "idx_face = 19 #@param {type:\"slider\", min:0, max:50, step:1}\n", - "idx_not_face = 8 #@param {type:\"slider\", min:0, max:50, step:1}\n", + "idx_face = 19 #@param {type:\"slider\", min:0, max:49, step:1}\n", + "idx_not_face = 8 #@param {type:\"slider\", min:0, max:49, step:1}\n", "\n", "plt.figure(figsize=(8,4))\n", "plt.subplot(1, 2, 1)\n",