511 lines
1.1 MiB
Plaintext
511 lines
1.1 MiB
Plaintext
|
{
|
||
|
"cells": [
|
||
|
{
|
||
|
"cell_type": "markdown",
|
||
|
"metadata": {},
|
||
|
"source": [
|
||
|
"## Object detection\n",
|
||
|
"\n",
|
||
|
"Tracking (following something over time) typically starts with object detection (localizing the thing in a given image)\n",
|
||
|
"\n",
|
||
|
"Background subtraction\n",
|
||
|
"\n",
|
||
|
"What is “background”?\n",
|
||
|
"\n",
|
||
|
"Thresholding for binarized images\n",
|
||
|
"\n",
|
||
|
"Connected component labeling\n",
|
||
|
"\n",
|
||
|
"![sensors-15-19369-g001.png](sensors-15-19369-g001.png)\n",
|
||
|
"Image: [Chao..Perán *Sensors* 2015](https://www.mdpi.com/1424-8220/15/8/19369)"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "markdown",
|
||
|
"metadata": {},
|
||
|
"source": [
|
||
|
"## Connected component labeling\n",
|
||
|
"\n",
|
||
|
"https://en.wikipedia.org/wiki/Connected-component_labeling\n",
|
||
|
"\n",
|
||
|
"![248px-Two-pass_connected_component_labeling.svg.png](248px-Two-pass_connected_component_labeling.svg.png)\n",
|
||
|
"Image: https://commons.wikimedia.org/wiki/File:Two-pass_connected_component_labeling.svg"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "markdown",
|
||
|
"metadata": {},
|
||
|
"source": [
|
||
|
"# Blur and erosion\n",
|
||
|
"\n",
|
||
|
"## Operations to help thresholding\n",
|
||
|
"\n",
|
||
|
"Before thresholding: Gaussian blur\n",
|
||
|
"\n",
|
||
|
"![image25.png](image25.png)\n",
|
||
|
"Image: Ronneberger..Joffe Chromosome Research 2008\n",
|
||
|
"\n",
|
||
|
"Note that this is an example of [kernel based image processing](https://en.wikipedia.org/wiki/Kernel_(image_processing)). This is also called \"convolution\".\n",
|
||
|
"\n",
|
||
|
"![image23.png](image23.png)\n",
|
||
|
"Image: https://de.m.wikipedia.org/wiki/Datei:Halftone,_Gaussian_Blur.jpg\n",
|
||
|
"\n",
|
||
|
"After thresholding: Erosion, dilation\n",
|
||
|
"\n",
|
||
|
"See [wikipedia on Erosion](https://en.wikipedia.org/wiki/Erosion_(morphology)). Note the similarities to the kernel operations.\n",
|
||
|
"\n",
|
||
|
"![image24.png](image24.png)\n",
|
||
|
"Image: Cereser, PhD thesis 2016"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 1,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"import numpy as np\n",
|
||
|
"import matplotlib.pyplot as plt\n",
|
||
|
"from scipy import ndimage\n",
|
||
|
"import imageio # \"pip install 'imageio[ffmpeg]'\""
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 8,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"# Here we define a helper function which we call below to make sure\n",
|
||
|
"# an image is an \"unsigned 8 bit integer\". This way, we know they\n",
|
||
|
"# take only a single byte per pixel and have a value from 0..255.\n",
|
||
|
"\n",
|
||
|
"def ensure_dtype_uint8(arr):\n",
|
||
|
" return arr.astype(np.uint8)"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 9,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"fname = 'short-movie20170810_182130.mp4'\n",
|
||
|
"reader = imageio.get_reader(fname)\n",
|
||
|
"for frame in reader:\n",
|
||
|
" frame0 = frame[:,:,1] # take only green channel\n",
|
||
|
" break"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 10,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"text/plain": [
|
||
|
"2"
|
||
|
]
|
||
|
},
|
||
|
"execution_count": 10,
|
||
|
"metadata": {},
|
||
|
"output_type": "execute_result"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"frame0.ndim"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 11,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"text/plain": [
|
||
|
"(1024, 1280)"
|
||
|
]
|
||
|
},
|
||
|
"execution_count": 11,
|
||
|
"metadata": {},
|
||
|
"output_type": "execute_result"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"frame0.shape"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 12,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAh0AAAGOCAYAAAAzerGXAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOy9a4xs2Vne/1RVd90vfb+cy5yZgTEJDEmIQRCUiwlgsEIIEMlIiaIQoSgRxoplEAnwIUMUMQIJiEL+QSJCEDAEvkAgApEYEZwgK5LjJAqGgG08l3Pr09fq6rp3V9X/Q+u3+tmrd8+MPTPH59TZr9Tq7qp9WXvttd71vM97WbnZbDZTJplkkkkmmWSSydss+c93AzLJJJNMMskkkydDMtCRSSaZZJJJJpk8FMlARyaZZJJJJplk8lAkAx2ZZJJJJplkkslDkQx0ZJJJJplkkkkmD0Uy0JFJJplkkkkmmTwUyUBHJplkkkkmmWTyUCQDHZlkkkkmmWSSyUORhc93AzLJJJNMMsnkSZHhcKjxePymr1MsFlUul9+CFj1cyUBHJplkkkkmmTwEGQ6HeuaZZ7Szs/Omr7W1taWXXnrpsQMeGejIJJNMMskkk4cg4/FYOzs7evXVV9VsNj/n63Q6HT311FMaj8cZ6Mgk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ATsye+rv1+zlDQ98uLi7qC7/wC1UqlXTv3r1LQDVNFhYWgrHlcwtAc3p6GtiYNGb1YYjrgCdR3izL8zj33SMLOiTpgx/8oP7e3/t7+vIv/3L9pb/0l/TTP/3TevXVV/WP//E/fsPXSKOL489RIm6FOav
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(frame0,cmap='gray')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 13,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAh0AAAGOCAYAAAAzerGXAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOz9a8ytWVbXDf/GnNdhHe7Tvve5uqqrC+hWHhvfaMODEvVB0VYSo4AJJCYmJMRogE54G2JUPgjG0NFEMSFiYmLAE+oXiBqJsQ2Cko7Pa/r1fRCQFrTprqquXbv26T6tta7DnPP9MOac11z33jTVXV3VVbvW2Llz73ut63yY8z/+4z/GkBBCYGc729nOdrazne3sTTbz5T6Ane1sZzvb2c529u6wHejY2c52trOd7Wxnb4ntQMfOdrazne1sZzt7S2wHOna2s53tbGc729lbYjvQsbOd7WxnO9vZzt4S24GOne1sZzvb2c529pbYDnTsbGc729nOdrazt8R2oGNnO9vZzna2s529JVZ9uQ9gZzvb2c52trN3i202G/q+f8PbaZqG2Wz2JTiit9Z2oGNnO9vZzna2s7fANpsNLzy/x5277g1v69atW3z6059+xwGPHejY2c52trOd7ewtsL7vuXPX8elPPs/B/hevb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p8HBBs8u4SQCk8njCxBMm2/y95oPPV5NXkAT3E5zwOeHliSxNGYgDSRHRpcvfx7mXvs/DkJIAvJ2MXvSuzzc7oACp5IJ6uhR6/GUP0Uqfj0XOI1y9
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(frame0)\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 14,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"name": "stdout",
|
||
|
"output_type": "stream",
|
||
|
"text": [
|
||
|
"(102, 1024, 1280)\n"
|
||
|
]
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"# get all frames into big 3D array\n",
|
||
|
"(height,width) = frame0.shape\n",
|
||
|
"all_frames = []\n",
|
||
|
"reader.set_image_index(0) # return to start of file\n",
|
||
|
"for frame in reader:\n",
|
||
|
" all_frames.append( frame[:,:,1] )\n",
|
||
|
"all_frames = np.array(all_frames)\n",
|
||
|
"print(all_frames.shape)\n",
|
||
|
"n_frames = len(all_frames)"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 15,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"mean_frame = np.mean(all_frames, axis=0)\n",
|
||
|
"median_frame = np.median(all_frames, axis=0)"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 16,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAh0AAAGOCAYAAAAzerGXAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOz9e5RcZ3XnjX9a53SdunaXutrdrZbaalmSZWQJy0hEji/YgMEOOGAuA0mGmWEmzI+8XCb8CO+syfCu35BZmZBkkkneCbkOGcjEITBhuIU4XBywsVEsItkyMrJlSVbbLbfUra5Wtaq6qk7VOd2/P/azn/NUSQYbX7Ct2mvVqqpzvz7P9/nu7967b2VlZYWe9axnPetZz3rWs+fYVv2kD6BnPetZz3rWs55dGNYDHT3rWc961rOe9ex5sR7o6FnPetaznvWsZ8+L9UBHz3rWs571rGc9e16sBzp61rOe9axnPevZ82I90NGznvWsZz3rWc+eF+uBjp71rGc961nPeva8WA909KxnPetZz3rWs+fF/J/0AfSsZz3rWc96dqFYs9mk1Wo94+2kUinS6fSzcETPr/VAR8961rOe9axnz4M1m00uymSoPQvbGhsb4/jx4y864NEDHT3rWc961rOePQ/WarWoAf83EDyD7YTAfz11ilar1QMdPetZz3rWs5717MktAF5cUOHZs56QtGc961nPetaz59H6n4XP07GPf/zjvPKVr6RQKDAyMsKtt97K4cOHO5Z597vfTV9fX8fnqquu6lgmDEM++MEPMjw8TC6X401vehMnTpx4WsfSAx0961nPetaznj2P5j8Ln6djd911F+9///u59957+eY3v0kURbz+9a9naWmpY7mbb76ZkydP2s/tt9/eMf9DH/oQX/ziF/nsZz/LPffcQ61W45ZbbiGO46d17j3rWc961rOe9ewlal/72tc6/n/qU59iZGSE/fv386pXvcpOD4KAsbGx825jcXGRP//zP+cv//IvufHGGwG47bbbmJiY4I477uCmm256SsfSYzp61rOe9axnPXsezeeZuVaULTh79mzHJwzDp7T/xcVFAIaGhjqm33nnnYyMjHDppZfyb//tv2Vubs7O279/P+12m9e//vV22vj4ONu2bWPPnj1P+dx7oKNnPetZz3rWs+fRni33ysTEBIODg/bz8Y9//Efue2VlhQ9/+MNce+21bNu2zU7/mZ/5Gf7qr/6Kb33rW/zu7/4u//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Ua1mWI49VfsxyMyUNd9QH6TZkzG+Qpz4toKaxKk0qFRIMtMgGLTyW8U2HkSUmS4sSdTyWCckDnjn8jO00A0Ky+Phk8cmZThJifFLU6cMjZTpRj1W0SduH1zcXqA+PZVJEeKzQxyBlilRpkWKeEg2G5RqY7Zwh4CzraBFQN4WmKwaYVCnYaTEeISm6LTZnqdYiYHp2guWHc/JsRXB2GNrXPE6dqu1gI1rUgCXqVKja9fVaqM2bfastE5OiQo6Ituni22ZegSojzBKbLjokRYvAAJ3ANnIxHj4eHj79wDIBaXPNAvos4PDNfkMCcvgE9BGTpo8UKQMc5ZhNR0yETz8+y6RpsZo6MT4N8oQERGYfLQIKrCJiFRAQk8MjpEhM3cAmD89AzQDP7icmRUyKFTxWKNLGw6dCkSYXkbHH0aIFzKTSLEce/ek+IM3SvGkD/BWI+1gJYSmEpVZbLkyfL2C6EAvonu/v7H8LbVb8mP50i2y+juf3sVxJ014agLUk77CPvH/alzbNR99Xfbcr5n/aWTdCnpuWuVk/DVz0cviTUeCTYO/2U7F+YD2wGSiQdPQg4OIJBHCcMN9tpNHyeG6tn+SEPeCFJynsueOfW3v
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(mean_frame, cmap=\"jet\")\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 17,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAh0AAAGOCAYAAAAzerGXAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAEAAElEQVR4nOz9e5RcZ3XnD39a53SdunaXutrdrZbaalmSZWQJy0hEji/YgMFOcIy5DCQZZoaZZF7y4zLhJfxmTYZZ75BZmZBkMhNmQi6TIQNJHAITwj2EiwM2NhqLSCAjI1uWZLXdckvd6mpVq6qr6lSd0/3+sZ/9nKdKMtj4gi3VXqtWVZ379Xm+z97f/d19KysrK/SsZz3rWc961rOePce26id9AD3rWc961rOe9ezisB7o6FnPetaznvWsZ8+L9UBHz3rWs571rGc9e16sBzp61rOe9axnPevZ82I90NGznvWsZz3rWc+eF+uBjp71rGc961nPeva8WA909KxnPetZz3rWs+fFeqCjZz3rWc961rOePS/m/6QPoGc961nPetazi8WazSatVusZbyeVSpFOp5+FI3p+rQc6etaznvWsZz17HqzZbHJJJkPtWdjW2NgYx48ff9EBjx7o6FnPetaznvXsebBWq0UN+H+B4BlsJwT+y6lTtFqtHujoWc961rOe9axnT24B8OKCCs+e9YikPetZz3rWs549j9b/LHyejn3oQx/i5S9/OYVCgZGREe644w4OHz7csczb3/52+vr6Oj7XXHNNxzJhGPKe97yH4eFhcrkct99+OydOnHhax9IDHT3rWc961rOePY/mPwufp2P33HMP73rXu7j//vv5+te/ThRFvPa1r2VpaaljuVtvvZWTJ0/az5e//OWO+e9973v57Gc/yyc/+Unuu+8+arUat912G3EcP61z71nPetaznvWsZxeofeUrX+n4/7GPfYyRkRH279/PK17xCjs9CALGxsbOu43FxUX+7M/+jL/8y7/k5ptvBuDOO+9kYmKCu+66i1tuueUpHUvP09GznvWsZz3r2fNoPs8stKLegrNnz3Z8wjB8SvtfXFwEYGhoqGP63XffzcjICJdffjn/+l//a+bm5uy8/fv30263ee1rX2unjY+Ps23bNvbs2fOUz70HOnrWs571rGc9ex7t2QqvTExMMDg4aD8f+tCHfuS+V1ZWeN/73sf111/Ptm3b7PSf+Zmf4a/+6q/4xje+wX/9r/+Vf/zHf+RVr3qVBTKnTp0ilUqxevXqju2Njo5y6tSpp3XuPetZz3rWs5717EVm09PTDAwM2P9B8KMTcd/97nfz/e9/n/vuu69j+lvf+lb7e9u2bezatYv169fzd3/3d7zxjW980u2trKzQ19f3lI+5Bzp61rOe9axnPXse7cfJQHEtMt8DAwMdoONH2Xve8x6+8IUv8K1vfYt169b90GXXrFnD+vXrOXLkCCBiZK1WizNnznR4O+bm5rj22muf8jH0wis961nPetaznj2P9nxnr6ysrPDud7+bz3zmM3zjG99gw4YNP3KdcrnM9PQ0a9asAWDnzp309/fz9a9/3S5z8uRJHnzwwacFOnqejp71rGc961nPnkdTIumPa+2nufy73vUuPvGJT/D5z3+eQqFgORiDg4NkMhlqtRof/OAHedOb3sSaNWuYmpri3//7f8/w8DBveMMb7LK/9Eu/xK/92q9RKpUYGhri/e9/P9u3b7fZLE/FeqCjZz3rWc961rML2P74j/8YgJtuuqlj+sc+9jHe/va343keBw8e5C/+4i+oVCqsWbOGV77ylXzqU5+iUCjY5X//938f3/d5y1veQqPR4NWvfjUf//jH8TzvKR9L38rKysqzclY961nPetaznvXsSe3s2bMMDg7yv4HsM9hOHfhXSOrr0+F0vBCs5+noWc961rOe9ex5tGdKJH0m6/6krUck7VnPetaznvWsZ8+L9TwdPetZz3rWs549j3Yxezp6oKNnPetZz3rWs+fRfpy01+71X6zWC6/0rGc961nPetaz58VezICpZz3rWc961rMXnT1TnY4Xc8f9Yj72nvWsZz3rWc9edNYLr/SsZz3rWc961rOePcf2ggcdf/RHf8SGDRtIp9Ps3LmTe++99yd9SD3rWc961rOe/djW/yx8Xqz2ggYdn/rUp3jve9/LBz7wAb73ve9xww038DM/8zM8/vjjP+lD61nPetaznvXsx7Lnu+DbC8le0DLou3fv5mUve5nVjQd4yUtewh133MGHPvShn+CR9axnPetZz3r29Exl0O8B8s9gOzXgRnoy6M+qtVot9u/fz7/7d/+uY/prX/ta9uzZc87yYRgShqH9v7y8zMLCAqVSib6+vuf8eHvWs571rGcvXltZWaFarTI+Ps6qVS/oIMCL2l6woGN+fp44jhkdHe2YPjo6asvyuvahD32I3/iN33i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2ynGRCSxccni0/OdJIQ45OiTh8eKdOJeqyiTdo+vL65QH14LJMiwmOFPgYpU6RKixTzlGgwLNfAbOcMAWdZR4uAuik0XTHApErBTovxCEnRbbE5S7UWAdOzEyw/nJNnK4Kzw9C+7nHqVG0HG9GiBixRp0LVrq/XQm3e7FttmZgUFXJEtE0X3zbzClQZYZbYdNEhKVoEBugEtpGL8fDx8PDpB5YJSJtrFtBnAYdv9hsSkMMnoI+YNH2kSBngKMdsOmIifPrxWSZNi9XUifFpkCckIDL7aBFQYBURq4CAmBweIUVi6gY2eXgGagZ4dj8xKWJSrOCxQpE2Hj4VijS5hIw9jhYtYCaVZjny6E/3AWmW5k0b4K9A3MdKCEshLLXacmH6fAHThVhA93x/Z/9baLPix/SnW2TzdTy/j+VKmvbSAKwleYd95P3TvrRpPvq+6rtdMf8DZ90IeW5a5mb9NHDJS+FPRoGPgr3bT8X6gfXAZqBA0tGDgIsnEMBxwny3kUbL47m1fpIT9oAXHqWwF45/bu0
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(median_frame, cmap=\"jet\")\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 18,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"start_row, stop_row = (750,950)\n",
|
||
|
"start_col, stop_col = (400,800)"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 19,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhQAAAGFCAYAAAClqGqeAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjku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ve9/Lt771rdeqSR06dOjQocPeoNlGX+nnALs8xra3t7dfixM/+OCDfM/3fA+/+Zu/WS1785vfzI//+I/zqU99qrHtYDBgMBhU/y9fvsyFCxdYWFhgbGzsmrW5Q4cOHTocPGxvb7OyssLRo0e57rpXR49eXl5mbm6OpV+G2Yk9HGcD5j4JS0tLzM7O7l8DrwFeE+PK5uYmjz/+OP/9f//fN5a/+93v5tFHHx3a/lOf+hQf//jHr1XzOnTo0KHDtyFOnz7NLbfc8uqeZK9ui6vc91Of+hT//t//e/7+7/+eyclJHnroIX7lV36Fe+65p9pme3ubj3/84/zWb/0WL7/8Mg8++CD/9t/+W77ru76r2mYwGPDRj36Uf/fv/h3r6+v80A/9EL/xG79xVf31mhCKl156ibIsWVxcbCxfXFzkxRdfHNr+l37pl/jwhz9c/V9aWuLWW2/ld4AN4FtAQX0x/lv/HbrfPWB9xHqHr5+x9RP2v4iflfgpGD5uG9SW3W7foUOHKyOnfjdzYDIuX4/fBc137lCybIswtuwHJoAj8XMDcD0wG5Xk4jKsEcaiLfsmnn8duBR/XwD+kTC+7Pach+L/S8A52q/J+2gm7jsZ23IotvfIdXD9HIxNASVsD4aPU5SwvgErm/U1zF4HeR4+RRE+y5dDZmQW18/PA98RPzcCN8VGVAeOF/9
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"frame = all_frames[0,:,:]\n",
|
||
|
"\n",
|
||
|
"plt.imshow(frame[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 20,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhQAAAGFCAYAAAClqGqeAA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9IGoqEhISEhIQDwivZKfMw1z0hISEhIeFlhTwDWlP7OH8bQHVg1bmhSIQiISEhISHhgJDnQP4KJRTJhyIhISEhISFh30gaioSEhISEhANCa58mj9b2wdXlRiMRioSEhISEhAPCgZg8DimSySMhISEhISFh30gaioSEhISEhANCKwNa+1iqt7YOri43GolQJCQkJCQkHBQy7E/3vw9zyUuNZPJISEhISEhI2DeShiIhISEhIeGgkGN/S/Vk8khISEhISEh4JROKZPJISEhISEhI2DeShiIhISEhIeGg8ArWUCRCkZCQkJCQcFA4Ahfp8QpEIhQJCQkJCQkHhRz7IxQpbDQhISEhISHhlYykoUhISEhISDgovII1FIlQJCQkJCQkHBQyvGJ9KJLJIyEhISEhIWHfSBqKhISEhISEg0IyeSQkJCQkJCTsGxlesZI1mTwSEhISEhIS9o1XKI9KSEhISEi4DtivU+b2QVXkxiMRioSEhISEhINCjlesZE0mj4SEhISEhIR94xXKoxISEhISEq4DXsEailfobSckJCQkJFwHJEKRkJCQkJCQsG/sd7fRQ7x9efKhSEhISEhISNg3koYiISEhISHhoLBfk0cKG01ISEhISEh4JROKZPJISEhISEhI2DeShiIhISEhIeGgsN9MmYfYKTMRioSEhISEhINCMnkkJCQkJCQkJFw7koYiISEhISHhoLDf7cuTySMhISEhISFh3z4U+zn3JUYyeSQkJCQkJCTsG0lDkZCQkJCQcFDYr1NmMnkkJCQkJCQkJEKRkJCQkJCQsH+8gglF8qFISEhISEhI2DeShiIhISEhIeGgsN/tyw/xMj8RioSEhISEhIPCfk0e1UFV5MbjEHOhhISEhISEhJcLkoYiISEhISHhoPAK1lAkQpGQkJCQkHBQSJkyExISEhISEhKuHS8pofiN3/gN3HbbbWi323jggQfwN3/zNy9ldRISEhISEvaH/ABehxQvGaH4gz/4A7z3ve/FBz/4QXzpS1/C61//erzlLW/BN77xjZeqSgkJCQkJCfsDdxu91tchNnlMbW9vb78UF37ooYfwXd/1XfjN3/zN+rfXvva1eOtb34qPfvSj0bGDwQCDwaD+vrW1hUuXLmFhYQFTU1M3rM4JCQkJCYcP29vbWFtbw8mTJ3HkyPVZR6+urmJubg4rvwTMtvdRTh+Y+wiwsrKC2dnZg6vgDcBLolwZDod4/PHH8e/+3b+Lfn/Tm96Exx57bOz4j370o/jQhz50o6qXkJCQkPBPEOfOncMtt9xyfS+yX7PFVZ770Y9+FH/4h3+I//2//zc6nQ4efvhhfOxjH8Pdd99dH7O9vY0PfehD+K3f+i28+OKLeOihh/Drv/7r+PZv//b6mMFggA984AP4/d//fWxubuKHfuiH8Bu/8RtX1V4vCaF44YUXUFUVlpaWot+Xlpbw/PPPjx3/i7/4i3jf+95Xf19ZWcFrXvMa/A6APoBvACgRbkY/87uCz7sFYHPC/wr9f0b+b8v30r/W/KvEeLlNYF32enxCQsLewHF6E4CTAO4G8P/432YAvIh4/BF9ACMc3Ji8CcDtAI7DzTk3AegcAcotYANxlGDbX7uCm5vWfD03/Xvf/7Yb2gAWARz1368AuOjPt2AbdODape0/t/z5NwFYPALcNAdMdV3ltgfj5ZQVsNkH1obuHgBg9giQ5+5Vlu61uuXuL/P/z88DeJV/3QzghK9EXTCAS74BLgFYl5ssAEz7z9P+9xcBDFw90QewBaxWwKkvAzMzM3tovX3iBkd5fO5zn8O73/1ufPd3fzfKssQHP/hBvOlNb8J
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(median_frame[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 21,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhQAAAGFCAYAAAClqGqeAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bG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sXLlzAwsICpqamrlubExISEhIOHra3t7G2tobjx4/j0KFro0evrq5ibm4OK78CzLb3cJw+MPdhYGVlBbOzs/vXwOuAG2JcGQ6HePzxx/Hv/t2/i35/05vehMcee2xs+4985CP44Ac/eL2al5CQkJDwbYgzZ87g1ltvvbYn2avb4gr3/chHPoI//uM/xv/+3/8bnU4HDz/8MD760Y/innvuqbfZ3t7GBz/4QfzO7/wOXnrpJTz00EP4zd/8TXznd35nvc1gMMD73/9+/OEf/iE2Nzfxwz/8w/it3/qtKxqvG0IoXnzxRVRVhaWlpej3paUlvPDCC2Pb//Iv/zLe+9731t9XVlbw6le/Gr8HoA/gGwBKhM7oZ35X8Hq3AGxO+F+h/8/I/235XvrXmn+VGD9uE9iW3W6fkJBweegzfhOAYwC+A8D/z/82A/ecthAszBWAkf99E25u0fnhap9Pnn/Rn/cwgNlDQLkFbCDOEmz7NgDAJd+WS3DbvSS/XQ5tf77DcqzzcH2y4Fh1fPva/nPL738TgMVDwE1zwFTXNXh7MH6csgI2+8DaMPRh9hCQ5+5Vlu61uuX6nPn/5+cBvMq/bvaDpRp+CeCCH4ALANalkwWAaf952v/+EoCBayf6ALaA1Qo48WVgZmZmF6O3R1znLI/Pfe5zeNe73oXv+Z7vQVmW+MAHPoA3velNeOqpp9D
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"plt.imshow(mean_frame[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 22,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhQAAAGOCAYAAADPb5pdAAAAOXRFWHRTb2Z0d2FyZQBNY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J8I7ON+jk+okS46IQQQggJC9RQEEIIIUHh1+TRF1RBBh8KFIQQQkhQFLFAQZMHIYQQQnxDDQUhhBASFEWcKTOvGoonnngCEyZMwNChQzF16lT88pe/zGdxCCGEEH+UBbBElLwJFM899xyamppw33334bXXXsNnPvMZzJs3D4cOHcpXkQghhBCSJXkTKFavXo1bb70Vf/3Xf41LLrkEjz32GBobG/Hkk08OeKxlWYjFYuDM64QQQgZiUPuMUvjTTkTY5JEX5Up3dzd2796Ne+65J2n93LlzsXPnzn77d3V1oaurK/G9ra0N48aNw+HDhyM3XzwhhJDBJRaLobGxER988AFqampyezG/ZosImzzyUvT33nsPfX19qKurS1pfV1eHlpaWfvuvWrUKDzzwQL/1jY2NOSsjIYSQwqK9vT33AkURk1dZqKSkJOm7ZVn91gHAvffei2XLliW+i4YC+AaAihyXkhASPcoAVAEYCuBPACoBTAWwI769CsDJ+P8yAO0AeuOfe9U5euGfKgBnxz//Kf5frlUJoFNdS18b8e1CD4DTAZSnGOkC8Ciqqqpyf6kijvLIi0AxatQolJaW9tNGtLa29tNaAEBFRQUqKtwEhwpQoCCE9KcctjAh7UkvgHMAjAPQCsCC3XZYsJvBs+P79MSP64mfA/HtnT7KIueujJ9bY8Exustnc7tQBrZ3/nAbsAZOEZs88uK
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"frame_absdiff = abs(frame - median_frame)\n",
|
||
|
"\n",
|
||
|
"plt.imshow(frame_absdiff[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 23,
|
||
|
"metadata": {},
|
||
|
"outputs": [],
|
||
|
"source": [
|
||
|
"threshold = 70"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 24,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"name": "stdout",
|
||
|
"output_type": "stream",
|
||
|
"text": [
|
||
|
"bool\n"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"data": {
|
||
|
"text/plain": [
|
||
|
"dtype('uint8')"
|
||
|
]
|
||
|
},
|
||
|
"execution_count": 24,
|
||
|
"metadata": {},
|
||
|
"output_type": "execute_result"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"tmp = frame_absdiff>threshold\n",
|
||
|
"print(tmp.dtype)\n",
|
||
|
"ensure_dtype_uint8(frame_absdiff>threshold).dtype"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 25,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhAAAAGTCAYAAAB5zCtiAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAq9ElEQVR4nO3df3BUZZ7v8U/nVweRtAKaTjTEjIMzaBDXZIREGQUlmBlQF+eSkSpBBy2zKG4M+CNSZSLlNYz3ijiLoI4g4uDArorXqckqsZQAi1ZBJigCu8us0QCbmCKD3QlCJ+mc+wek1yYJ5OScJH3S71fVU5U+P/o8T50Z+8v3+eUyDMMQAACACTGDXQEAAOA8BBAAAMA0AggAAGAaAQQAADCNAAIAAJhGAAEAAEwjgAAAAKYRQAAAANMIIAAAgGkEEAAAwDQCCAAAHGzbtm2aOXOmUlNT5XK59N57753znqqqKmVlZSkxMVE/+tGP9PLLL5t+LgEEAAAOdvz4cU2YMEErV67s1fW1tbX6xS9+ocmTJ6umpkZPPvmkHn74Yb3zzjumnutiMy0AAIYGl8ulzZs364477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NoAkPqpC+Oqq65SfX19qOzduzd07rnnntPy5cu1cuVK7dq1S16vV9OmTVNzc3N/VAWA011Q1ut/j7n2kH3A4ArGxlouTtEvXRhxcXFhWYdOhmFoxYoVWrJkiWbNmiVJeuONN5ScnKy33npLDzzwQH9UB4BTecu0qsGlbwe7HkAvdSh
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"binarized = ensure_dtype_uint8(frame_absdiff>threshold)\n",
|
||
|
"plt.imshow(binarized[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 26,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhQAAAGJCAYAAADSaqrlAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAADKgElEQVR4nO39f5RkVXkvDn96qrqqu4eZhplxuunLQCa5aCIzIQYNyksEBYcQEQkmoN5lUHlz8SJkTRjwR/x6GbMUhNwFeiFqsuIriovgWm+EaOJVhysM8k7IkkGuQlyKNyNCmHECDt3T091VXdX1/nFqn/Oc5zzPPvtUVf+omeezVnWfs88+++x9fuz92Z/n2XsPtFqtFgwGg8FgMBi6wKrlzoDBYDAYDIb+hxEKg8FgMBgMXcMIhcFgMBgMhq5hhMJgMBgMBkPXMEJhMBgMBoOhaxihMBgMBoPB0DWMUBgMBoPBYOga5eXOgMFgMBgMRwPm5uZQr9e7TqdSqWBoaKgHOVpaGKEwGAwGg6FLzM3N4WXDw5juQVrj4+PYt29f35EK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AUTOmjfccAPuuecezM7O4rzzzsNnPvMZbNq0KTjvRigMBoPBYOgSy0UoVhLM5GEwGAwGQ6/Q7fLl3Zy7zDBCYTAYDAZDr7DEPhQrCcs6yuMzn/kMNm/ejKGhIZxxxhn47ne/u5zZMRgMBoPB0CGWjVB85Stfwfbt2/GRj3wE3//+9/G7v/u7uPDCC/Hzn/98ubJkMBgMBkN3cMuXd/rrY5PHsjllnnnmmfjt3/5tfPazn43DfuM3fgO
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"blurred = ndimage.gaussian_filter(frame, sigma=6.0)\n",
|
||
|
"plt.imshow(blurred[start_row:stop_row,start_col:stop_col], cmap='jet')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 27,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhAAAAGTCAYAAAB5zCtiAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAr20lEQVR4nO3df3RU9Z3/8dfk1wSRjAKSHxrS1KJVg3RNtpBYqqAE04J1sUtazgpa7DFLxY0BK5GzBjiuoX5PkXYR1AoiLS7sVvHY06wQt/JrwXMgGxSBs8su0QCbmEMWMwFxkkzu9w/IlCEJ5ObeZO6deT7Ouedk7tzP3M/HG5l33p9fHsMwDAEAAJgQF+kKAAAA9yGAAAAAphFAAAAA0wggAACAaQQQAADANAIIAABgGgEEAAAwjQACAACYRgABAABMI4AAAACmEUAAAOBiO3fu1PTp05WRkSGPx6N33nnnimV27Nih3N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akdvsqNIBs78JYsmSJPB5P2JGWlhZ63zAMLVmyRBkZGRoyZIjuvvtuHTp0yO5qAHC5Ci0l+wA42ICMgbjtttvU0NAQOg4ePBh674UXXtCKFSu0atUq7du3T2lpaZoyZYpaW1sHoioAXMhq4EDggUgJxsdbPtxiQLowEhISwrIOXQzD0MqVK7V48WLNmDFDkvTGG28oNTVVb775ph577LGBqA4AF+HLH27WqXgF1f8ujE6XjH+QBigDcfToUWVkZCg7O1s/+tGPdOzYMUlSXV2dGhsbVVhYGLrW6/Xqrrvu0p49e3r9vEA
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"blurred_absdiff = abs(blurred - median_frame)\n",
|
||
|
"blur_threshold = 40\n",
|
||
|
"binarized_blurred = ensure_dtype_uint8(blurred_absdiff>blur_threshold)\n",
|
||
|
"plt.imshow(binarized_blurred[start_row:stop_row,start_col:stop_col], cmap='jet', interpolation='nearest')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"cell_type": "code",
|
||
|
"execution_count": 28,
|
||
|
"metadata": {},
|
||
|
"outputs": [
|
||
|
{
|
||
|
"data": {
|
||
|
"image/png": "iVBORw0KGgoAAAANSUhEUgAAAhAAAAGTCAYAAAB5zCtiAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjkuMiwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy8hTgPZAAAACXBIWXMAAA9hAAAPYQGoP6dpAAAog0lEQVR4nO3dcXBV5Z3/8c8lJDeI5FaI5uZqiFFBwSCuyQqJogISmhbUxR3S0hFs0TFLxY0BWyMzJWUcY92V0i6CtUKRFhd2qzh2mlZilQAbqSQbWoSMmy7RBDZpJlnMDYg3EM7vj27ur5ckkJM8cO/hvF8zZ4Z7znPveZ45jnz4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avXq21a9dq37598vv9mjVrljo7Oy9EVwBcAm644QZ9/PHHfYYHSaqvr7/IPQL611OFGMzmJBdkCmP48OERVYcelmVpzZo1WrFihebNmydJeu2115SSkqLXX39djz322IXoDgAHGz9+vA4ePKi4uLh+23z88ccXsUdA/5jCGKL6+noFAgFlZGToa1/7mg4fPixJamhoUEtLi/Ly8sJtvV6v7r77blVVVfX7e6FQSMFgMGIDcOm78cYb9dFHH2n48HP/W+emm266SD0C0MN4gJgyZYo2b96sd955Rz/96U/V0tKi3Nxctbe3q6WlRZKUkpIS8Z2UlJTwsb6UlZXJ5/OFt7S0NNPdBhBjbrrpJh04cEDx8fHnbFdXV3eRegSc31CmL5w2jWF8CiM/Pz/850mTJiknJ0fXX3+9XnvtNU2dOlVS71uuLMs656r
|
||
|
"text/plain": [
|
||
|
"<Figure size 640x480 with 2 Axes>"
|
||
|
]
|
||
|
},
|
||
|
"metadata": {},
|
||
|
"output_type": "display_data"
|
||
|
}
|
||
|
],
|
||
|
"source": [
|
||
|
"eroded = binarized_blurred\n",
|
||
|
"for i in range(4):\n",
|
||
|
" eroded = ndimage.binary_erosion(eroded)\n",
|
||
|
"plt.imshow(eroded.astype(np.uint8)[start_row:stop_row,start_col:stop_col], cmap='gray')\n",
|
||
|
"plt.colorbar();"
|
||
|
]
|
||
|
}
|
||
|
],
|
||
|
"metadata": {
|
||
|
"celltoolbar": "Create Assignment",
|
||
|
"kernelspec": {
|
||
|
"display_name": "Python 3 (ipykernel)",
|
||
|
"language": "python",
|
||
|
"name": "python3"
|
||
|
},
|
||
|
"language_info": {
|
||
|
"codemirror_mode": {
|
||
|
"name": "ipython",
|
||
|
"version": 3
|
||
|
},
|
||
|
"file_extension": ".py",
|
||
|
"mimetype": "text/x-python",
|
||
|
"name": "python",
|
||
|
"nbconvert_exporter": "python",
|
||
|
"pygments_lexer": "ipython3",
|
||
|
"version": "3.11.10"
|
||
|
}
|
||
|
},
|
||
|
"nbformat": 4,
|
||
|
"nbformat_minor": 4
|
||
|
}
|