Skip to content

Commit f228018

Browse files
committed
Update Tutorial2-Template_Augmentation.ipynb
1 parent 5af852a commit f228018

File tree

1 file changed

+16
-15
lines changed

1 file changed

+16
-15
lines changed

tutorials/Tutorial2-Template_Augmentation.ipynb

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -376,9 +376,16 @@
376376
},
377377
{
378378
"cell_type": "code",
379-
"execution_count": 11,
379+
"execution_count": 17,
380380
"metadata": {},
381381
"outputs": [
382+
{
383+
"name": "stdout",
384+
"output_type": "stream",
385+
"text": [
386+
"Wall time: 790 ms\n"
387+
]
388+
},
382389
{
383390
"data": {
384391
"text/html": [
@@ -416,19 +423,19 @@
416423
" <th>1</th>\n",
417424
" <td>180</td>\n",
418425
" <td>(1525, 968, 414, 400)</td>\n",
419-
" <td>0.591971</td>\n",
426+
" <td>0.591937</td>\n",
420427
" </tr>\n",
421428
" <tr>\n",
422429
" <th>2</th>\n",
423430
" <td>180</td>\n",
424431
" <td>(1173, 1354, 414, 400)</td>\n",
425-
" <td>0.551099</td>\n",
432+
" <td>0.551068</td>\n",
426433
" </tr>\n",
427434
" <tr>\n",
428435
" <th>3</th>\n",
429436
" <td>90</td>\n",
430437
" <td>(1459, 474, 400, 414)</td>\n",
431-
" <td>0.538119</td>\n",
438+
" <td>0.538105</td>\n",
432439
" </tr>\n",
433440
" </tbody>\n",
434441
"</table>\n",
@@ -437,12 +444,12 @@
437444
"text/plain": [
438445
" TemplateName BBox Score\n",
439446
"0 0 (946, 784, 414, 400) 1.000000\n",
440-
"1 180 (1525, 968, 414, 400) 0.591971\n",
441-
"2 180 (1173, 1354, 414, 400) 0.551099\n",
442-
"3 90 (1459, 474, 400, 414) 0.538119"
447+
"1 180 (1525, 968, 414, 400) 0.591937\n",
448+
"2 180 (1173, 1354, 414, 400) 0.551068\n",
449+
"3 90 (1459, 474, 400, 414) 0.538105"
443450
]
444451
},
445-
"execution_count": 11,
452+
"execution_count": 17,
446453
"metadata": {},
447454
"output_type": "execute_result"
448455
},
@@ -460,13 +467,7 @@
460467
}
461468
],
462469
"source": [
463-
"Hits = matchTemplates(listTemplate, \n",
464-
" image, \n",
465-
" N_object=4, \n",
466-
" score_threshold=0.4, \n",
467-
" method=cv2.TM_CCOEFF_NORMED, \n",
468-
" maxOverlap=0.3,\n",
469-
" useOpencl=True)\n",
470+
"%time Hits = matchTemplates(listTemplate, image,N_object=4, score_threshold=0.4, method=cv2.TM_CCOEFF_NORMED, maxOverlap=0.3, useOpencl=False)\n",
470471
"\n",
471472
"Overlay = drawBoxesOnRGB(image, Hits, boxThickness=5)\n",
472473
"plt.figure(figsize = (10,10))\n",

0 commit comments

Comments
 (0)