From 1cd3e752def0ecbcb39a95d75e3c93fad3114ab9 Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Fri, 19 Aug 2022 02:01:40 +0200 Subject: [PATCH] Created using Colaboratory --- tutorial.ipynb | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/tutorial.ipynb b/tutorial.ipynb index 7a1edf7..a70887e 100644 --- a/tutorial.ipynb +++ b/tutorial.ipynb @@ -1112,8 +1112,8 @@ { "cell_type": "code", "source": [ - "# Classification\n", - "for m in [*(f'yolov5{x}-cls.pt' for x in 'nsmlx'), 'resnet50.pt', 'efficientnet_b0.pt']:\n", + "# Classification train\n", + "for m in [*(f'yolov5{x}-cls.pt' for x in 'nsmlx'), 'resnet50.pt', 'resnet101.pt', 'efficientnet_b0.pt', 'efficientnet_b1.pt']:\n", " for d in 'mnist', 'fashion-mnist', 'cifar10', 'cifar100', 'imagenette160', 'imagenette320', 'imagenette', 'imagewoof160', 'imagewoof320', 'imagewoof':\n", " !python classify/train.py --model {m} --data {d} --epochs 10 --project YOLOv5-cls --name {m}-{d}" ], @@ -1123,6 +1123,19 @@ "execution_count": null, "outputs": [] }, + { + "cell_type": "code", + "source": [ + "# Classification val\n", + "!bash data/scripts/get_imagenet.sh --val # download ImageNet val split (6.3G, 50000 images)\n", + "!python classify/val.py --weights yolov5m-cls.pt --data ../datasets/imagenet --img 224 # validate" + ], + "metadata": { + "id": "yYgOiFNHZx-1" + }, + "execution_count": null, + "outputs": [] + }, { "cell_type": "code", "metadata": {