{ "cells": [ { "cell_type": "markdown", "id": "8a4a74dc-5958-4c8c-abdb-784135994d35", "metadata": {}, "source": [ "\"Header\"" ] }, { "cell_type": "markdown", "id": "571b7f4d-d7d6-4a80-8288-b6eb5d76901c", "metadata": {}, "source": [ "## Assessment: Computer Vision for Industrial Inspection ##\n", "In this notebook, you will utilize what you've learned in this course to complete an assessment. The assessment has been divided into a couple of steps to guide your development. You will be graded based on the performance of your deep learning model. Note that this coding portion does not give partial credit - it shows up as either 0 or 60 points. \n", "
Step Points
0. The Problem
1. Data Curation
2. Prepare TAO Experiment
3. Model Training
4. Model Evaluation 60
" ] }, { "cell_type": "markdown", "id": "559c1a85-e36c-4396-93fb-524048c66684", "metadata": {}, "source": [ "

" ] }, { "cell_type": "markdown", "id": "43e4be02-6163-4282-ad82-892dee6d17a0", "metadata": {}, "source": [ "### Step 0: The Problem ###\n", "In this course, we made a binary classifier for the true/false defective units in our printed circuit board assembly dataset. For the asssesment we are asking you to create a model over the same dataset, but with a different purpose. Before we dealt with `capacitors` only, but the reference circuit boards have other components as well. In particular, we are interested in classifying the following four components based on their images: \n", "\n", "

\n", "\n", "The component types are marked by the first letter(s) of component identification numbers. \n", "* **C** - Capacitor\n", "* **Q** - Transistor\n", "* **R** - Resistor\n", "* **U** - Integrated Circuit\n", "\n", "Your task is to train and evaluate a classifier that accurately labels the four component types. We recommend using `VGG19` as the architecture in the spirit of experimenting with different backbones. \n", "\n", "**Instructions**:
\n", "0.1 Execute the below cell to import dependencies
\n", "0.2 Execute the cell below to unzip and load data" ] }, { "cell_type": "code", "execution_count": 1, "id": "6854c3b3-4640-4b5d-99dd-df66f1bb6226", "metadata": {}, "outputs": [], "source": [ "# 0.1\n", "# DO NOT CHANGE THIS CELL\n", "# import dependencies\n", "import os\n", "import warnings\n", "import pandas as pd\n", "import json\n", "import matplotlib.image as mpimg\n", "import matplotlib.pyplot as plt\n", "import math\n", "import shutil\n", "warnings.filterwarnings(\"ignore\")" ] }, { "cell_type": "code", "execution_count": 2, "id": "a3c9a2e4-9e8a-4031-b955-14a5c2f16f71", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "unzip: cannot find or open data/viz_BYD_new.zip, data/viz_BYD_new.zip.zip or data/viz_BYD_new.zip.ZIP.\n", "rm: cannot remove 'data/viz_BYD_new.zip': No such file or directory\n" ] } ], "source": [ "# 0.2\n", "# DO NOT CHANGE THIS CELL\n", "# unzip\n", "!unzip -qq data/viz_BYD_new.zip -d data\n", "\n", "# remove zip file\n", "!rm data/viz_BYD_new.zip" ] }, { "cell_type": "markdown", "id": "ac27c9b9-b8f9-4331-b6dd-f3a1c7da2058", "metadata": {}, "source": [ "### Step 1: Data Curation ###\n", "The first step is to curate the data. \n", "\n", "**Instructions**:
\n", "1.1 Execute the below cell to load the data into a `DataFrame` and preview.
\n", "1.2 Modify the `` only and execute the cell below to filter and keep only normal images as potential defective images may include missing parts.
\n", "1.3 Modify the `` only and execute the cell below to filter and keep only relevant images, i.e. `C`, `Q`, `R`, or `U`.
\n", "1.4 Execute the cell below to check the sample size. " ] }, { "cell_type": "code", "execution_count": 3, "id": "47f1a7e0-ed48-4378-8ddb-56d9ef8a1357", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
true_defectdefect_img_pathdateboardcomp_idimg_shapedefect_image_namecomp_type
0notdefect/dli/task/data/AOI_DL_data_0908/0423318026324/...908423318026324C1090(54, 27, 3)D0_C1090.jpgC
1notdefect/dli/task/data/AOI_DL_data_0908/0423318026269/...908423318026269C1090(54, 27, 3)D1_C1090.jpgC
2notdefect/dli/task/data/AOI_DL_data_0908/0423318026261/...908423318026261L503(347, 418, 3)D1_L503.jpgL
3notdefect/dli/task/data/AOI_DL_data_0908/0423318026523/...908423318026523L503(347, 418, 3)D1_L503.jpgL
4notdefect/dli/task/data/AOI_DL_data_0908/0423318026523/...908423318026523C1090(54, 27, 3)D1_C1090.jpgC
\n", "
" ], "text/plain": [ " true_defect defect_img_path date \\\n", "0 notdefect /dli/task/data/AOI_DL_data_0908/0423318026324/... 908 \n", "1 notdefect /dli/task/data/AOI_DL_data_0908/0423318026269/... 908 \n", "2 notdefect /dli/task/data/AOI_DL_data_0908/0423318026261/... 908 \n", "3 notdefect /dli/task/data/AOI_DL_data_0908/0423318026523/... 908 \n", "4 notdefect /dli/task/data/AOI_DL_data_0908/0423318026523/... 908 \n", "\n", " board comp_id img_shape defect_image_name comp_type \n", "0 423318026324 C1090 (54, 27, 3) D0_C1090.jpg C \n", "1 423318026269 C1090 (54, 27, 3) D1_C1090.jpg C \n", "2 423318026261 L503 (347, 418, 3) D1_L503.jpg L \n", "3 423318026523 L503 (347, 418, 3) D1_L503.jpg L \n", "4 423318026523 C1090 (54, 27, 3) D1_C1090.jpg C " ] }, "execution_count": 3, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# 1.1\n", "# DO NOT CHANGE THIS CELL\n", "# load from pcba_df.csv\n", "pcba_df=pd.read_csv('pcba_df.csv')\n", "pcba_df.head()" ] }, { "cell_type": "code", "execution_count": 4, "id": "1831b93c-deb5-40c6-a55b-4feb22c568fa", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
true_defectdefect_img_pathdateboardcomp_idimg_shapedefect_image_namecomp_type
77defect/dli/task/data/AOI_DL_data_0908/0423618041671/...908423618041671R511(132, 52, 3)D1_R511.jpgR
89defect/dli/task/data/AOI_DL_data_0908/0423618042253/...908423618042253R1318(88, 35, 3)D1_R1318.jpgR
122defect/dli/task/data/AOI_DL_data_0908/0423618039275/...908423618039275C517(387, 171, 3)D1_C517.jpgC
225defect/dli/task/data/AOI_DL_data_0908/0423618040901/...908423618040901R176(36, 87, 3)D0_R176.jpgR
227defect/dli/task/data/AOI_DL_data_0908/0423618039308/...908423618039308C107(84, 32, 3)D1_C107.jpgC
\n", "
" ], "text/plain": [ " true_defect defect_img_path date \\\n", "77 defect /dli/task/data/AOI_DL_data_0908/0423618041671/... 908 \n", "89 defect /dli/task/data/AOI_DL_data_0908/0423618042253/... 908 \n", "122 defect /dli/task/data/AOI_DL_data_0908/0423618039275/... 908 \n", "225 defect /dli/task/data/AOI_DL_data_0908/0423618040901/... 908 \n", "227 defect /dli/task/data/AOI_DL_data_0908/0423618039308/... 908 \n", "\n", " board comp_id img_shape defect_image_name comp_type \n", "77 423618041671 R511 (132, 52, 3) D1_R511.jpg R \n", "89 423618042253 R1318 (88, 35, 3) D1_R1318.jpg R \n", "122 423618039275 C517 (387, 171, 3) D1_C517.jpg C \n", "225 423618040901 R176 (36, 87, 3) D0_R176.jpg R \n", "227 423618039308 C107 (84, 32, 3) D1_C107.jpg C " ] }, "execution_count": 4, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# 1.2\n", "verified_df=pcba_df[pcba_df['true_defect']==\"defect\"]\n", "verified_df.head()" ] }, { "cell_type": "code", "execution_count": 5, "id": "ecb4e9ed-2d53-4d79-b67e-9e6da8fe2106", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
true_defectdefect_img_pathdateboardcomp_idimg_shapedefect_image_namecomp_type
77defect/dli/task/data/AOI_DL_data_0908/0423618041671/...908423618041671R511(132, 52, 3)D1_R511.jpgR
89defect/dli/task/data/AOI_DL_data_0908/0423618042253/...908423618042253R1318(88, 35, 3)D1_R1318.jpgR
122defect/dli/task/data/AOI_DL_data_0908/0423618039275/...908423618039275C517(387, 171, 3)D1_C517.jpgC
225defect/dli/task/data/AOI_DL_data_0908/0423618040901/...908423618040901R176(36, 87, 3)D0_R176.jpgR
227defect/dli/task/data/AOI_DL_data_0908/0423618039308/...908423618039308C107(84, 32, 3)D1_C107.jpgC
\n", "
" ], "text/plain": [ " true_defect defect_img_path date \\\n", "77 defect /dli/task/data/AOI_DL_data_0908/0423618041671/... 908 \n", "89 defect /dli/task/data/AOI_DL_data_0908/0423618042253/... 908 \n", "122 defect /dli/task/data/AOI_DL_data_0908/0423618039275/... 908 \n", "225 defect /dli/task/data/AOI_DL_data_0908/0423618040901/... 908 \n", "227 defect /dli/task/data/AOI_DL_data_0908/0423618039308/... 908 \n", "\n", " board comp_id img_shape defect_image_name comp_type \n", "77 423618041671 R511 (132, 52, 3) D1_R511.jpg R \n", "89 423618042253 R1318 (88, 35, 3) D1_R1318.jpg R \n", "122 423618039275 C517 (387, 171, 3) D1_C517.jpg C \n", "225 423618040901 R176 (36, 87, 3) D0_R176.jpg R \n", "227 423618039308 C107 (84, 32, 3) D1_C107.jpg C " ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# 1.3\n", "cqru_df=verified_df[verified_df['comp_type'].isin([\"C\", \"Q\", \"R\", \"U\"])]\n", "cqru_df.head()" ] }, { "cell_type": "code", "execution_count": 6, "id": "fa67e90e-876c-4280-81d6-13452b6bae82", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "comp_type\n", "C 99\n", "R 12\n", "U 8\n", "dtype: int64" ] }, "execution_count": 6, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# 1.4\n", "# DO NOT CHANGE THIS CELL\n", "# check sample size\n", "cqru_df.groupby('comp_type').size()" ] }, { "cell_type": "markdown", "id": "c569654d-7fe0-4af4-b8ea-d2326bb684a2", "metadata": {}, "source": [ "### Step 2: Prepare TAO Experiment ###\n", "Next we will prepare for the TAO experiment. \n", "\n", "**Instructions**:
\n", "2.1 Execute the below cell to set environment variables.
\n", "2.2 Execute the cell below to map up local directories to the TAO docker.
\n", "2.3 Execute the cell below to use the `ngc registry mode list` command that lists all available `classification` models.
\n", "2.4 Modify the `` only and execute the cell below to download the `VGG19` pre-trained weights.
\n", "2.5 Execute the cell below to view the pre-trained model.
\n", "2.6 Execute the cell below to create the required data directories.
\n", "2.7 Execute the cell below to create a 70%/30% split for train and val.
\n", "2.8 Execute the cell below to copy data from the source to the TAO experiment folder. " ] }, { "cell_type": "code", "execution_count": 7, "id": "e55f23d5-5509-4a22-8d8b-b2c9612d75c3", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "env: KEY=my_model_key\n", "env: LOCAL_PROJECT_DIR=/dli/task/tao_project\n", "env: LOCAL_DATA_DIR=/dli/task/tao_project/data\n", "env: LOCAL_SPECS_DIR=/dli/task/tao_project/spec_files\n", "env: TAO_PROJECT_DIR=/workspace/tao-experiments\n", "env: TAO_DATA_DIR=/workspace/tao-experiments/data\n", "env: TAO_SPECS_DIR=/workspace/tao-experiments/spec_files\n" ] } ], "source": [ "# 2.1\n", "# DO NOT CHANGE THIS CELL\n", "# set environment variables\n", "%set_env KEY=my_model_key\n", "\n", "%set_env LOCAL_PROJECT_DIR=/dli/task/tao_project\n", "%set_env LOCAL_DATA_DIR=/dli/task/tao_project/data\n", "%set_env LOCAL_SPECS_DIR=/dli/task/tao_project/spec_files\n", "os.environ[\"LOCAL_EXPERIMENT_DIR\"]=os.path.join(os.getenv(\"LOCAL_PROJECT_DIR\"), \"classification\")\n", "\n", "%set_env TAO_PROJECT_DIR=/workspace/tao-experiments\n", "%set_env TAO_DATA_DIR=/workspace/tao-experiments/data\n", "%set_env TAO_SPECS_DIR=/workspace/tao-experiments/spec_files\n", "os.environ['TAO_EXPERIMENT_DIR']=os.path.join(os.getenv(\"TAO_PROJECT_DIR\"), \"classification\")\n", "\n", "# make the data directory\n", "!mkdir -p $LOCAL_DATA_DIR" ] }, { "cell_type": "code", "execution_count": 8, "id": "bb3a6cbe-430d-4c54-8897-64aa5d41a2b4", "metadata": {}, "outputs": [], "source": [ "# 2.2\n", "# DO NOT CHANGE THIS CELL\n", "# map local directories to the TAO docker\n", "mounts_file = os.path.expanduser(\"~/.tao_mounts.json\")\n", "\n", "drive_map = {\n", " \"Mounts\": [\n", " # Mapping the data directory\n", " {\n", " \"source\": os.environ[\"LOCAL_PROJECT_DIR\"],\n", " \"destination\": \"/workspace/tao-experiments\"\n", " },\n", " # Mapping the specs directory.\n", " {\n", " \"source\": os.environ[\"LOCAL_SPECS_DIR\"],\n", " \"destination\": os.environ[\"TAO_SPECS_DIR\"]\n", " },\n", " # Mapping the data directory.\n", " {\n", " \"source\": os.environ[\"LOCAL_DATA_DIR\"],\n", " \"destination\": os.environ[\"TAO_DATA_DIR\"]\n", " },\n", " ],\n", " \"DockerOptions\": {\n", " \"user\": \"{}:{}\".format(os.getuid(), os.getgid())\n", " }\n", "}\n", "\n", "# writing the mounts file\n", "with open(mounts_file, \"w\") as mfile:\n", " json.dump(drive_map, mfile, indent=4)" ] }, { "cell_type": "code", "execution_count": 9, "id": "0ebc8c2a-bb02-4515-8923-1cb6f53b2bef", "metadata": { "scrolled": true, "tags": [] }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " \"versionId\": \"vgg19\"\n" ] } ], "source": [ "# 2.3\n", "# DO NOT CHANGE THIS CELL\n", "!ngc registry model list nvidia/tao/pretrained_classification:* | grep vgg19" ] }, { "cell_type": "code", "execution_count": 10, "id": "548bd5b4-0e54-48f7-82d1-549623cd92db", "metadata": { "tags": [] }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "{\n", " \"download_end\": \"2025-12-25 08:11:02\",\n", " \"download_start\": \"2025-12-25 08:11:00\",\n", " \"download_time\": \"2s\",\n", " \"files_downloaded\": 1,\n", " \"local_path\": \"/dli/task/tao_project/classification/pretrained_vgg19/pretrained_classification_vvgg19\",\n", " \"size_downloaded\": \"153.72 MB\",\n", " \"status\": \"COMPLETED\"\n", "}\n" ] } ], "source": [ "# 2.4\n", "# create directory to store the pre-trained model\n", "!mkdir -p $LOCAL_EXPERIMENT_DIR/pretrained_vgg19/\n", "\n", "# download the pre-trained vgg19 model from NGC\n", "!ngc registry model download-version nvidia/tao/pretrained_classification:vgg19 --dest $LOCAL_EXPERIMENT_DIR/pretrained_vgg19" ] }, { "cell_type": "markdown", "id": "b1cc0cf5-4c9d-476e-a302-6a175fc04d3a", "metadata": {}, "source": [ "

\n", "\n", "We designated the model to be downloaded to `tao_project/classification/pretrained_vgg19`, which is mapped to `/workspace/tao-experiments/classification/pretrained_vgg19` in the TAO container based on the mapping of `LOCAL_EXPERIMENT_DIR` to `TAO_EXPERIMENT_DIR`. Looking at the `local_path` and `transfer_id` keys of the output JSON, we can gather that the path of the pre-trained model should be in the `tao_project/classification/pretrained_vgg19/pretrained_classification_vvgg19` directory. When referencing paths for the TAO Toolkit, it's important to use paths based on the TAO container. In this case it would be `/workspace/tao-experiments/classification/pretrained_vgg19/pretrained_classification_vvgg19`. " ] }, { "cell_type": "code", "execution_count": 11, "id": "e7655abf-8c17-4c85-86cb-8f594e932f61", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "total 157416\n", "drwxr-xr-x 2 root root 4096 Dec 25 08:11 .\n", "drwxr-xr-x 3 root root 4096 Dec 25 08:11 ..\n", "-rw-r--r-- 1 root root 161183816 Dec 25 08:11 vgg_19.hdf5\n" ] } ], "source": [ "# 2.5\n", "# DO NOT CHANGE THIS CELL\n", "!ls -al tao_project/classification/pretrained_vgg19/pretrained_classification_vvgg19" ] }, { "cell_type": "code", "execution_count": 12, "id": "2538dd6b-51bb-4347-b48b-fe1c1ee69dda", "metadata": {}, "outputs": [], "source": [ "# 2.6\n", "# DO NOT CHANGE THIS CELL\n", "# remove existing data from previous experiment (if any)\n", "!rm -rf $LOCAL_DATA_DIR/*\n", "\n", "!mkdir -p $LOCAL_DATA_DIR/train/Q\n", "!mkdir -p $LOCAL_DATA_DIR/train/C\n", "!mkdir -p $LOCAL_DATA_DIR/train/U\n", "!mkdir -p $LOCAL_DATA_DIR/train/R\n", "!mkdir -p $LOCAL_DATA_DIR/val/Q\n", "!mkdir -p $LOCAL_DATA_DIR/val/C\n", "!mkdir -p $LOCAL_DATA_DIR/val/U\n", "!mkdir -p $LOCAL_DATA_DIR/val/R" ] }, { "cell_type": "code", "execution_count": 13, "id": "1521c5f5-3f0c-461e-a561-664dc68d8ef3", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "data_set comp_type\n", "train C 69\n", " R 8\n", " U 6\n", "val C 30\n", " R 4\n", " U 2\n", "dtype: int64" ] }, "execution_count": 13, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# 2.7\n", "# DO NOT CHANGE THIS CELL\n", "# set default as training set\n", "cqru_df['data_set']='train'\n", "\n", "# sample 30% and set as validation set\n", "val_set=cqru_df.groupby('comp_type', group_keys=False).apply(lambda x: x.sample(frac=0.3))\n", "cqru_df.loc[val_set.index, 'data_set']='val'\n", "cqru_df.groupby(['data_set', 'comp_type']).size()" ] }, { "cell_type": "code", "execution_count": 14, "id": "65f67e2b-0b15-4264-bc71-f08423236ff0", "metadata": {}, "outputs": [], "source": [ "# 2.8\n", "# DO NOT CHANGE THIS CELL\n", "# iterate through the DataFrame and copy images\n", "for idx, row in cqru_df.iterrows(): \n", " shutil.copyfile(row['defect_img_path'], f\"{os.environ['LOCAL_DATA_DIR']}/{row['data_set']}/{row['comp_type']}/{row['date']}_{row['board']}_{row['defect_image_name']}\")" ] }, { "cell_type": "markdown", "id": "455daecb-fbd1-4e1e-a831-68b4672f10ed", "metadata": {}, "source": [ "### Step 3: Model Training ###\n", "The next step is to modify the configuration file that will be used for `train`. You can create a new text file for this purpose manually and start from scratch or use the [template provided](tao_project/spec_files/vgg19/config.txt). You can also refer to sample applications and configuration files [here](https://docs.nvidia.com/tao/tao-toolkit/text/image_classification.html). \n", "\n", "**Instructions**:
\n", "3.1. Open and review the [configuration file](tao_project/spec_files/vgg19/config.txt).
\n", "3.2. Modify the ``s only in the configuration file with the correct values and **save changes**. We recommend starting with a very low epoch count (e.g. 5) in the interest of time as each epoch can take ~100s to complete.
\n", "* Recall that you don't need the `eval_config` section of the configuration file, which requires you to know the trained model path. Of course, if you know where you would like to place the model, you can go ahead and complete this section. \n", "3.3 Execute the cell below to initiate model training. \n", "\n", "

\n", "\n", "Based on how NGC names the pre-trained model downloaded, we should use `/workspace/tao-experiments/classification/pretrained_vgg19/pretrained_classification_vvgg19/resnet_19.hdf5` to reference the pre-trained model. Furthermore, we can choose where to store the trained model - in this case we use `/workspace/tao-experiments/classification/vgg19` inside of the TAO container, which is mapped to `tao_project/classification/vgg19` in our local drive. Furthermore, the trained model name will follow the format `_0.tlt`, unless specified otherwise. Therefore we should use `/workspace/tao-experiments/classification/vgg19/weights/vgg_XXX.tlt`, depending on `n_epochs` in the model configuration. " ] }, { "cell_type": "code", "execution_count": 15, "id": "b3fba5b6-ee35-48ab-9f09-6608c9388685", "metadata": { "scrolled": true, "tags": [] }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "2025-12-25 08:12:15,455 [TAO Toolkit] [INFO] root 160: Registry: ['nvcr.io']\n", "2025-12-25 08:12:15,571 [TAO Toolkit] [INFO] nvidia_tao_cli.components.instance_handler.local_instance 360: Running command in container: nvcr.io/nvidia/tao/tao-toolkit:5.0.0-tf1.15.5\n", "2025-12-25 08:12:15,585 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 301: Printing tty value True\n", "Using TensorFlow backend.\n", "2025-12-25 08:12:19.137732: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:12:19,192 [TAO Toolkit] [WARNING] tensorflow 40: Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "2025-12-25 08:12:20,435 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:12:20,480 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:12:20,485 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:12:22.915615: I tensorflow/core/platform/profile_utils/cpu_utils.cc:109] CPU Frequency: 2499995000 Hz\n", "2025-12-25 08:12:22.916044: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x94ff9c0 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:12:22.916081: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n", "2025-12-25 08:12:22.917680: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcuda.so.1\n", "2025-12-25 08:12:23.126385: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.128650: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x931ad70 initialized for platform CUDA (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:12:23.128691: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Tesla T4, Compute Capability 7.5\n", "2025-12-25 08:12:23.129062: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.131127: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1674] Found device 0 with properties: \n", "name: Tesla T4 major: 7 minor: 5 memoryClockRate(GHz): 1.59\n", "pciBusID: 0000:00:1e.0\n", "2025-12-25 08:12:23.131197: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:12:23.131354: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcublas.so.12\n", "2025-12-25 08:12:23.156801: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcufft.so.11\n", "2025-12-25 08:12:23.156994: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcurand.so.10\n", "2025-12-25 08:12:23.266050: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusolver.so.11\n", "2025-12-25 08:12:23.278372: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusparse.so.12\n", "2025-12-25 08:12:23.278549: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudnn.so.8\n", "2025-12-25 08:12:23.278734: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.281070: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.283097: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1802] Adding visible gpu devices: 0\n", "2025-12-25 08:12:23.283184: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:12:23.294084: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1214] Device interconnect StreamExecutor with strength 1 edge matrix:\n", "2025-12-25 08:12:23.294141: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1220] 0 \n", "2025-12-25 08:12:23.294170: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1233] 0: N \n", "2025-12-25 08:12:23.294526: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.296800: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:12:23.298874: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1359] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 13496 MB memory) -> physical GPU (device: 0, name: Tesla T4, pci bus id: 0000:00:1e.0, compute capability: 7.5)\n", "Using TensorFlow backend.\n", "WARNING:tensorflow:Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "WARNING:tensorflow:TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:12:25,095 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "WARNING:tensorflow:TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:12:25,137 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "WARNING:tensorflow:TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:12:25,140 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:12:26,694 [TAO Toolkit] [INFO] __main__ 388: Loading experiment spec at /workspace/tao-experiments/spec_files/vgg19/config.txt.\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:398: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n", "\n", "2025-12-25 08:12:26,697 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:398: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:407: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n", "\n", "2025-12-25 08:12:26,698 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:407: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.set_verbosity is deprecated. Please use tf.compat.v1.logging.set_verbosity instead.\n", "\n", "2025-12-25 08:12:27,054 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.set_verbosity is deprecated. Please use tf.compat.v1.logging.set_verbosity instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.INFO is deprecated. Please use tf.compat.v1.logging.INFO instead.\n", "\n", "2025-12-25 08:12:27,054 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.INFO is deprecated. Please use tf.compat.v1.logging.INFO instead.\n", "\n", "2025-12-25 08:12:27,055 [TAO Toolkit] [INFO] __main__ 478: Default image mean [103.939, 116.779, 123.68] will be used.\n", "Found 83 images belonging to 4 classes.\n", "2025-12-25 08:12:27,073 [TAO Toolkit] [INFO] __main__ 294: Processing dataset (train): /workspace/tao-experiments/data/train\n", "Found 36 images belonging to 4 classes.\n", "2025-12-25 08:12:27,078 [TAO Toolkit] [INFO] __main__ 311: Processing dataset (validation): /workspace/tao-experiments/data/val\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:74: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n", "\n", "2025-12-25 08:12:27,078 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:74: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:517: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n", "\n", "2025-12-25 08:12:27,079 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:517: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:4138: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n", "\n", "2025-12-25 08:12:27,083 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:4138: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/third_party/keras/tensorflow_backend.py:199: The name tf.nn.avg_pool is deprecated. Please use tf.nn.avg_pool2d instead.\n", "\n", "2025-12-25 08:12:27,215 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/third_party/keras/tensorflow_backend.py:199: The name tf.nn.avg_pool is deprecated. Please use tf.nn.avg_pool2d instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:174: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n", "\n", "2025-12-25 08:12:27,408 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:174: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:190: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n", "\n", "2025-12-25 08:12:27,408 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:190: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:199: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n", "\n", "2025-12-25 08:12:27,408 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:199: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:206: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n", "\n", "2025-12-25 08:12:27,493 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:206: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:1834: The name tf.nn.fused_batch_norm is deprecated. Please use tf.compat.v1.nn.fused_batch_norm instead.\n", "\n", "2025-12-25 08:12:27,907 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:1834: The name tf.nn.fused_batch_norm is deprecated. Please use tf.compat.v1.nn.fused_batch_norm instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:133: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n", "\n", "2025-12-25 08:12:27,913 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:133: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n", "\n", "_________________________________________________________________\n", "Layer (type) Output Shape Param # \n", "=================================================================\n", "input_1 (InputLayer) (None, 3, 224, 224) 0 \n", "_________________________________________________________________\n", "block_1a_conv_1 (Conv2D) (None, 64, 224, 224) 1728 \n", "_________________________________________________________________\n", "block_1a_relu (Activation) (None, 64, 224, 224) 0 \n", "_________________________________________________________________\n", "block_1b_conv_1 (Conv2D) (None, 64, 224, 224) 36864 \n", "_________________________________________________________________\n", "block_1b_relu (Activation) (None, 64, 224, 224) 0 \n", "_________________________________________________________________\n", "block_2a_conv_1 (Conv2D) (None, 128, 112, 112) 73728 \n", "_________________________________________________________________\n", "block_2a_relu (Activation) (None, 128, 112, 112) 0 \n", "_________________________________________________________________\n", "block_2b_conv_1 (Conv2D) (None, 128, 112, 112) 147456 \n", "_________________________________________________________________\n", "block_2b_relu (Activation) (None, 128, 112, 112) 0 \n", "_________________________________________________________________\n", "block_3a_conv_1 (Conv2D) (None, 256, 56, 56) 294912 \n", "_________________________________________________________________\n", "block_3a_relu (Activation) (None, 256, 56, 56) 0 \n", "_________________________________________________________________\n", "block_3b_conv_1 (Conv2D) (None, 256, 56, 56) 589824 \n", "_________________________________________________________________\n", "block_3b_relu (Activation) (None, 256, 56, 56) 0 \n", "_________________________________________________________________\n", "block_3c_conv_1 (Conv2D) (None, 256, 56, 56) 589824 \n", "_________________________________________________________________\n", "block_3c_relu (Activation) (None, 256, 56, 56) 0 \n", "_________________________________________________________________\n", "block_3d_conv_1 (Conv2D) (None, 256, 56, 56) 589824 \n", "_________________________________________________________________\n", "block_3d_relu (Activation) (None, 256, 56, 56) 0 \n", "_________________________________________________________________\n", "block_4a_conv_1 (Conv2D) (None, 512, 28, 28) 1179648 \n", "_________________________________________________________________\n", "block_4a_relu (Activation) (None, 512, 28, 28) 0 \n", "_________________________________________________________________\n", "block_4b_conv_1 (Conv2D) (None, 512, 28, 28) 2359296 \n", "_________________________________________________________________\n", "block_4b_relu (Activation) (None, 512, 28, 28) 0 \n", "_________________________________________________________________\n", "block_4c_conv_1 (Conv2D) (None, 512, 28, 28) 2359296 \n", "_________________________________________________________________\n", "block_4c_relu (Activation) (None, 512, 28, 28) 0 \n", "_________________________________________________________________\n", "block_4d_conv_1 (Conv2D) (None, 512, 28, 28) 2359296 \n", "_________________________________________________________________\n", "block_4d_relu (Activation) (None, 512, 28, 28) 0 \n", "_________________________________________________________________\n", "block_5a_conv_1 (Conv2D) (None, 512, 14, 14) 2359296 \n", "_________________________________________________________________\n", "block_5a_relu (Activation) (None, 512, 14, 14) 0 \n", "_________________________________________________________________\n", "block_5b_conv_1 (Conv2D) (None, 512, 14, 14) 2359296 \n", "_________________________________________________________________\n", "block_5b_relu (Activation) (None, 512, 14, 14) 0 \n", "_________________________________________________________________\n", "block_5c_conv_1 (Conv2D) (None, 512, 14, 14) 2359296 \n", "_________________________________________________________________\n", "block_5c_relu (Activation) (None, 512, 14, 14) 0 \n", "_________________________________________________________________\n", "block_5d_conv_1 (Conv2D) (None, 512, 14, 14) 2359296 \n", "_________________________________________________________________\n", "block_5d_relu (Activation) (None, 512, 14, 14) 0 \n", "_________________________________________________________________\n", "avg_pool (AveragePooling2D) (None, 512, 1, 1) 0 \n", "_________________________________________________________________\n", "flatten (Flatten) (None, 512) 0 \n", "_________________________________________________________________\n", "predictions (Dense) (None, 4) 2052 \n", "=================================================================\n", "Total params: 20,020,932\n", "Trainable params: 20,020,932\n", "Non-trainable params: 0\n", "_________________________________________________________________\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/optimizers.py:790: The name tf.train.Optimizer is deprecated. Please use tf.compat.v1.train.Optimizer instead.\n", "\n", "2025-12-25 08:12:31,681 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/optimizers.py:790: The name tf.train.Optimizer is deprecated. Please use tf.compat.v1.train.Optimizer instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:3295: The name tf.log is deprecated. Please use tf.math.log instead.\n", "\n", "2025-12-25 08:12:31,692 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:3295: The name tf.log is deprecated. Please use tf.math.log instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1133: The name tf.summary.FileWriter is deprecated. Please use tf.compat.v1.summary.FileWriter instead.\n", "\n", "2025-12-25 08:12:31,709 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1133: The name tf.summary.FileWriter is deprecated. Please use tf.compat.v1.summary.FileWriter instead.\n", "\n", "2025-12-25 08:12:31,710 [TAO Toolkit] [INFO] nvidia_tao_tf1.cv.common.logging.logging 197: Log file already exists at /workspace/tao-experiments/classification/vgg19/status.json\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:986: The name tf.assign_add is deprecated. Please use tf.compat.v1.assign_add instead.\n", "\n", "2025-12-25 08:12:32,115 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:986: The name tf.assign_add is deprecated. Please use tf.compat.v1.assign_add instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:973: The name tf.assign is deprecated. Please use tf.compat.v1.assign instead.\n", "\n", "2025-12-25 08:12:32,162 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:973: The name tf.assign is deprecated. Please use tf.compat.v1.assign instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1181: The name tf.summary.merge_all is deprecated. Please use tf.compat.v1.summary.merge_all instead.\n", "\n", "2025-12-25 08:12:32,684 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1181: The name tf.summary.merge_all is deprecated. Please use tf.compat.v1.summary.merge_all instead.\n", "\n", "2025-12-25 08:12:32,971 [TAO Toolkit] [INFO] root 2102: Starting Training Loop.\n", "Epoch 1/5\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:199: The name tf.Summary is deprecated. Please use tf.compat.v1.Summary instead.\n", "\n", "2025-12-25 08:13:12,841 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:199: The name tf.Summary is deprecated. Please use tf.compat.v1.Summary instead.\n", "\n", "3/3 [==============================] - 105s 35s/step - loss: 15.7107 - acc: 0.0378 - val_loss: 14.5815 - val_acc: 0.1111\n", "2025-12-25 08:14:21,408 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 2/5\n", "3/3 [==============================] - 19s 6s/step - loss: 15.3260 - acc: 0.0649 - val_loss: 14.5828 - val_acc: 0.1111\n", "2025-12-25 08:14:42,049 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 3/5\n", "3/3 [==============================] - 2s 563ms/step - loss: 14.8060 - acc: 0.0973 - val_loss: 14.5841 - val_acc: 0.1111\n", "2025-12-25 08:14:44,103 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 4/5\n", "3/3 [==============================] - 2s 565ms/step - loss: 14.8935 - acc: 0.0919 - val_loss: 14.5854 - val_acc: 0.1111\n", "2025-12-25 08:14:46,015 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 5/5\n", "3/3 [==============================] - 2s 568ms/step - loss: 14.8947 - acc: 0.0919 - val_loss: 14.5864 - val_acc: 0.1111\n", "2025-12-25 08:14:47,929 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "2025-12-25 08:14:47,933 [TAO Toolkit] [INFO] root 2102: Training loop complete.\n", "2025-12-25 08:14:47,937 [TAO Toolkit] [INFO] root 2102: Final model evaluation in progress.\n", "2025-12-25 08:14:48,449 [TAO Toolkit] [INFO] root 2102: Model evaluation is complete.\n", "2025-12-25 08:14:48,450 [TAO Toolkit] [INFO] __main__ 625: Total Val Loss: 14.586379051208496\n", "2025-12-25 08:14:48,450 [TAO Toolkit] [INFO] __main__ 626: Total Val accuracy: 0.1111111119389534\n", "2025-12-25 08:14:48,450 [TAO Toolkit] [INFO] root 2102: Training finished successfully.\n", "2025-12-25 08:14:48,450 [TAO Toolkit] [INFO] __main__ 651: Training finished successfully.\n", "Telemetry data couldn't be sent, but the command ran successfully.\n", "[WARNING]: \n", "Execution status: PASS\n", "2025-12-25 08:15:11,119 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 363: Stopping container.\n" ] } ], "source": [ "# 3.2\n", "# DO NOT CHANGE THIS CELL\n", "# train model\n", "!tao model classification_tf1 train -e $TAO_SPECS_DIR/vgg19/config.txt \\\n", " -r $TAO_EXPERIMENT_DIR/vgg19 \\\n", " -k $KEY" ] }, { "cell_type": "code", "execution_count": 16, "id": "9508c989-db0f-4f67-a2c0-bb36127e5e07", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "total 765M\n", "-rw-r--r-- 1 root root 153M Dec 25 08:14 vgg_001.hdf5\n", "-rw-r--r-- 1 root root 153M Dec 25 08:14 vgg_002.hdf5\n", "-rw-r--r-- 1 root root 153M Dec 25 08:14 vgg_003.hdf5\n", "-rw-r--r-- 1 root root 153M Dec 25 08:14 vgg_004.hdf5\n", "-rw-r--r-- 1 root root 153M Dec 25 08:14 vgg_005.hdf5\n" ] } ], "source": [ "!ls -ltrh $LOCAL_EXPERIMENT_DIR/vgg19/weights/" ] }, { "cell_type": "markdown", "id": "96d92840-c3cd-4b9a-b025-c47d1bbb2f32", "metadata": {}, "source": [ "### Step 4: Model Evaluation ###\n", "The last step for the assessment is to `evaluate` the model through the `eval_config` section of the configuration file. Once completed, you should submit the output log for assessment. \n", "\n", "**Instructions**:
\n", "4.1 Review the [configuration file](tao_project/spec_files/vgg19/config.txt) and modify the `eval_config` section if needed.
\n", "4.2 Execute the below cell to evaluate the model. A log file will be generated through the use of the `--log_file` option, which will be used for grading purposes.
\n", "4.3 Execute the cell below to submit the log for assessment. " ] }, { "cell_type": "code", "execution_count": 17, "id": "b637cba7-5394-4671-b6c9-49df0ff7303d", "metadata": { "scrolled": true, "tags": [] }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "2025-12-25 08:15:16,580 [TAO Toolkit] [INFO] root 160: Registry: ['nvcr.io']\n", "2025-12-25 08:15:16,702 [TAO Toolkit] [INFO] nvidia_tao_cli.components.instance_handler.local_instance 360: Running command in container: nvcr.io/nvidia/tao/tao-toolkit:5.0.0-tf1.15.5\n", "2025-12-25 08:15:16,723 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 301: Printing tty value True\n", "Using TensorFlow backend.\n", "2025-12-25 08:15:17.804692: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:15:17,864 [TAO Toolkit] [WARNING] tensorflow 40: Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "2025-12-25 08:15:20,106 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:15:20,215 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:15:20,229 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:15:22.911665: I tensorflow/core/platform/profile_utils/cpu_utils.cc:109] CPU Frequency: 2499995000 Hz\n", "2025-12-25 08:15:22.912129: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x7a28d60 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:15:22.912168: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n", "2025-12-25 08:15:22.913747: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcuda.so.1\n", "2025-12-25 08:15:23.117897: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.120230: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x7844110 initialized for platform CUDA (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:15:23.120272: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Tesla T4, Compute Capability 7.5\n", "2025-12-25 08:15:23.120634: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.122956: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1674] Found device 0 with properties: \n", "name: Tesla T4 major: 7 minor: 5 memoryClockRate(GHz): 1.59\n", "pciBusID: 0000:00:1e.0\n", "2025-12-25 08:15:23.123034: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:15:23.123156: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcublas.so.12\n", "2025-12-25 08:15:23.125305: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcufft.so.11\n", "2025-12-25 08:15:23.125472: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcurand.so.10\n", "2025-12-25 08:15:23.129061: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusolver.so.11\n", "2025-12-25 08:15:23.130332: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusparse.so.12\n", "2025-12-25 08:15:23.130431: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudnn.so.8\n", "2025-12-25 08:15:23.130597: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.132718: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.134652: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1802] Adding visible gpu devices: 0\n", "2025-12-25 08:15:23.134725: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:15:23.144179: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1214] Device interconnect StreamExecutor with strength 1 edge matrix:\n", "2025-12-25 08:15:23.144236: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1220] 0 \n", "2025-12-25 08:15:23.144251: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1233] 0: N \n", "2025-12-25 08:15:23.144583: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.146756: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:15:23.148724: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1359] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 13496 MB memory) -> physical GPU (device: 0, name: Tesla T4, pci bus id: 0000:00:1e.0, compute capability: 7.5)\n", "Telemetry data couldn't be sent, but the command ran successfully.\n", "[WARNING]: \n", "Execution status: PASS\n", "2025-12-25 08:16:16,727 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 363: Stopping container.\n" ] } ], "source": [ "# 4.1\n", "# DO NOT CHANGE THIS CELL\n", "# evaluate the model using the same validation set as training\n", "!tao model classification_tf1 evaluate -e $TAO_SPECS_DIR/vgg19/config.txt\\\n", " -k $KEY \\\n", " --log_file $TAO_PROJECT_DIR/log_file.txt" ] }, { "cell_type": "raw", "id": "da01ece6-6169-42a3-8738-155e82387854", "metadata": {}, "source": [ "Confusion Matrix\n", "[[ 0 30 0]\n", " [ 0 4 0]\n", " [ 0 2 0]]\n", "Classification Report\n", " precision recall f1-score support\n", "\n", " C 0.00 0.00 0.00 30\n", " Q 0.00 0.00 0.00 0\n", " R 0.11 1.00 0.20 4\n", " U 0.00 0.00 0.00 2\n", "\n", " micro avg 0.11 0.11 0.11 36\n", " macro avg 0.03 0.25 0.05 36\n", "weighted avg 0.01 0.11 0.02 36\n" ] }, { "cell_type": "code", "execution_count": 21, "id": "cd519ab8-32bb-468e-9741-38f8da66388e", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " \"versionId\": \"resnet50\"\n", " \"versionId\": \"resnet34\"\n", " \"versionId\": \"resnet18\"\n", " \"versionId\": \"resnet101\"\n", " \"versionId\": \"resnet10\"\n" ] } ], "source": [ "!ngc registry model list nvidia/tao/pretrained_classification:* | grep resnet" ] }, { "cell_type": "code", "execution_count": 22, "id": "60c26e8e-fc98-46ce-8aaa-ff976d64df6e", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "{\n", " \"download_end\": \"2025-12-25 08:25:07\",\n", " \"download_start\": \"2025-12-25 08:25:05\",\n", " \"download_time\": \"2s\",\n", " \"files_downloaded\": 1,\n", " \"local_path\": \"/dli/task/tao_project/classification/pretrained_resnet50/pretrained_classification_vresnet50\",\n", " \"size_downloaded\": \"294.2 MB\",\n", " \"status\": \"COMPLETED\"\n", "}\n" ] } ], "source": [ "!ngc registry model download-version nvidia/tao/pretrained_classification:resnet50 --dest $LOCAL_EXPERIMENT_DIR/pretrained_resnet50" ] }, { "cell_type": "code", "execution_count": 32, "id": "960997de-4756-4d76-9c3c-b9be2a0adff6", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "2025-12-25 08:44:12,756 [TAO Toolkit] [INFO] root 160: Registry: ['nvcr.io']\n", "2025-12-25 08:44:12,876 [TAO Toolkit] [INFO] nvidia_tao_cli.components.instance_handler.local_instance 360: Running command in container: nvcr.io/nvidia/tao/tao-toolkit:5.0.0-tf1.15.5\n", "2025-12-25 08:44:12,889 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 301: Printing tty value True\n", "Using TensorFlow backend.\n", "2025-12-25 08:44:13.844067: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:44:13,896 [TAO Toolkit] [WARNING] tensorflow 40: Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "2025-12-25 08:44:15,105 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:44:15,149 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:44:15,154 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:44:17.201067: I tensorflow/core/platform/profile_utils/cpu_utils.cc:109] CPU Frequency: 2499995000 Hz\n", "2025-12-25 08:44:17.201471: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x8b60d30 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:44:17.201505: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n", "2025-12-25 08:44:17.203226: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcuda.so.1\n", "2025-12-25 08:44:17.386188: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.388107: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x897c0e0 initialized for platform CUDA (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:44:17.388148: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Tesla T4, Compute Capability 7.5\n", "2025-12-25 08:44:17.388607: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.390410: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1674] Found device 0 with properties: \n", "name: Tesla T4 major: 7 minor: 5 memoryClockRate(GHz): 1.59\n", "pciBusID: 0000:00:1e.0\n", "2025-12-25 08:44:17.390475: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:44:17.390574: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcublas.so.12\n", "2025-12-25 08:44:17.392789: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcufft.so.11\n", "2025-12-25 08:44:17.392911: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcurand.so.10\n", "2025-12-25 08:44:17.396667: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusolver.so.11\n", "2025-12-25 08:44:17.398009: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusparse.so.12\n", "2025-12-25 08:44:17.398106: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudnn.so.8\n", "2025-12-25 08:44:17.398264: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.400147: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.401844: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1802] Adding visible gpu devices: 0\n", "2025-12-25 08:44:17.401923: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:44:17.411218: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1214] Device interconnect StreamExecutor with strength 1 edge matrix:\n", "2025-12-25 08:44:17.411285: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1220] 0 \n", "2025-12-25 08:44:17.411301: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1233] 0: N \n", "2025-12-25 08:44:17.411642: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.413618: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:44:17.415368: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1359] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 13496 MB memory) -> physical GPU (device: 0, name: Tesla T4, pci bus id: 0000:00:1e.0, compute capability: 7.5)\n", "Using TensorFlow backend.\n", "WARNING:tensorflow:Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "WARNING:tensorflow:TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:44:19,075 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "WARNING:tensorflow:TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:44:19,118 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "WARNING:tensorflow:TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:44:19,121 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:44:20,450 [TAO Toolkit] [INFO] __main__ 388: Loading experiment spec at /workspace/tao-experiments/spec_files/resnet50/config.txt.\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:398: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n", "\n", "2025-12-25 08:44:20,455 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:398: The name tf.ConfigProto is deprecated. Please use tf.compat.v1.ConfigProto instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:407: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n", "\n", "2025-12-25 08:44:20,455 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:407: The name tf.Session is deprecated. Please use tf.compat.v1.Session instead.\n", "\n", "2025-12-25 08:44:20,810 [TAO Toolkit] [INFO] nvidia_tao_tf1.cv.common.logging.logging 197: Log file already exists at /workspace/tao-experiments/classification/resnet50/status.json\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.set_verbosity is deprecated. Please use tf.compat.v1.logging.set_verbosity instead.\n", "\n", "2025-12-25 08:44:20,810 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.set_verbosity is deprecated. Please use tf.compat.v1.logging.set_verbosity instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.INFO is deprecated. Please use tf.compat.v1.logging.INFO instead.\n", "\n", "2025-12-25 08:44:20,810 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/scripts/train.py:431: The name tf.logging.INFO is deprecated. Please use tf.compat.v1.logging.INFO instead.\n", "\n", "2025-12-25 08:44:20,811 [TAO Toolkit] [INFO] __main__ 478: Default image mean [103.939, 116.779, 123.68] will be used.\n", "Found 83 images belonging to 4 classes.\n", "2025-12-25 08:44:20,819 [TAO Toolkit] [INFO] __main__ 294: Processing dataset (train): /workspace/tao-experiments/data/train\n", "Found 36 images belonging to 4 classes.\n", "2025-12-25 08:44:20,822 [TAO Toolkit] [INFO] __main__ 311: Processing dataset (validation): /workspace/tao-experiments/data/val\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:74: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n", "\n", "2025-12-25 08:44:20,823 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:74: The name tf.get_default_graph is deprecated. Please use tf.compat.v1.get_default_graph instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:517: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n", "\n", "2025-12-25 08:44:20,823 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:517: The name tf.placeholder is deprecated. Please use tf.compat.v1.placeholder instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:4138: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n", "\n", "2025-12-25 08:44:20,825 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:4138: The name tf.random_uniform is deprecated. Please use tf.random.uniform instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/third_party/keras/tensorflow_backend.py:199: The name tf.nn.avg_pool is deprecated. Please use tf.nn.avg_pool2d instead.\n", "\n", "2025-12-25 08:44:21,192 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/third_party/keras/tensorflow_backend.py:199: The name tf.nn.avg_pool is deprecated. Please use tf.nn.avg_pool2d instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:174: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n", "\n", "2025-12-25 08:44:21,852 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:174: The name tf.get_default_session is deprecated. Please use tf.compat.v1.get_default_session instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:190: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n", "\n", "2025-12-25 08:44:21,853 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:190: The name tf.global_variables is deprecated. Please use tf.compat.v1.global_variables instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:199: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n", "\n", "2025-12-25 08:44:21,853 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:199: The name tf.is_variable_initialized is deprecated. Please use tf.compat.v1.is_variable_initialized instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:206: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n", "\n", "2025-12-25 08:44:22,102 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:206: The name tf.variables_initializer is deprecated. Please use tf.compat.v1.variables_initializer instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:1834: The name tf.nn.fused_batch_norm is deprecated. Please use tf.compat.v1.nn.fused_batch_norm instead.\n", "\n", "2025-12-25 08:44:22,911 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:1834: The name tf.nn.fused_batch_norm is deprecated. Please use tf.compat.v1.nn.fused_batch_norm instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:133: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n", "\n", "2025-12-25 08:44:22,917 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:133: The name tf.placeholder_with_default is deprecated. Please use tf.compat.v1.placeholder_with_default instead.\n", "\n", "__________________________________________________________________________________________________\n", "Layer (type) Output Shape Param # Connected to \n", "==================================================================================================\n", "input_1 (InputLayer) (None, 3, 224, 224) 0 \n", "__________________________________________________________________________________________________\n", "conv1 (Conv2D) (None, 64, 112, 112) 9408 input_1[0][0] \n", "__________________________________________________________________________________________________\n", "activation_1 (Activation) (None, 64, 112, 112) 0 conv1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_conv_1 (Conv2D) (None, 64, 56, 56) 4096 activation_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_relu_1 (Activation) (None, 64, 56, 56) 0 block_1a_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_conv_2 (Conv2D) (None, 64, 56, 56) 36864 block_1a_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_relu_2 (Activation) (None, 64, 56, 56) 0 block_1a_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_conv_3 (Conv2D) (None, 256, 56, 56) 16384 block_1a_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_conv_shortcut (Conv2D) (None, 256, 56, 56) 16384 activation_1[0][0] \n", "__________________________________________________________________________________________________\n", "add_1 (Add) (None, 256, 56, 56) 0 block_1a_conv_3[0][0] \n", " block_1a_conv_shortcut[0][0] \n", "__________________________________________________________________________________________________\n", "block_1a_relu (Activation) (None, 256, 56, 56) 0 add_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_conv_1 (Conv2D) (None, 64, 56, 56) 16384 block_1a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_relu_1 (Activation) (None, 64, 56, 56) 0 block_1b_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_conv_2 (Conv2D) (None, 64, 56, 56) 36864 block_1b_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_relu_2 (Activation) (None, 64, 56, 56) 0 block_1b_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_conv_3 (Conv2D) (None, 256, 56, 56) 16384 block_1b_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_2 (Add) (None, 256, 56, 56) 0 block_1b_conv_3[0][0] \n", " block_1a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_1b_relu (Activation) (None, 256, 56, 56) 0 add_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_conv_1 (Conv2D) (None, 64, 56, 56) 16384 block_1b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_relu_1 (Activation) (None, 64, 56, 56) 0 block_1c_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_conv_2 (Conv2D) (None, 64, 56, 56) 36864 block_1c_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_relu_2 (Activation) (None, 64, 56, 56) 0 block_1c_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_conv_3 (Conv2D) (None, 256, 56, 56) 16384 block_1c_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_3 (Add) (None, 256, 56, 56) 0 block_1c_conv_3[0][0] \n", " block_1b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_1c_relu (Activation) (None, 256, 56, 56) 0 add_3[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_conv_1 (Conv2D) (None, 128, 28, 28) 32768 block_1c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_relu_1 (Activation) (None, 128, 28, 28) 0 block_2a_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_conv_2 (Conv2D) (None, 128, 28, 28) 147456 block_2a_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_relu_2 (Activation) (None, 128, 28, 28) 0 block_2a_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_conv_3 (Conv2D) (None, 512, 28, 28) 65536 block_2a_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_conv_shortcut (Conv2D) (None, 512, 28, 28) 131072 block_1c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "add_4 (Add) (None, 512, 28, 28) 0 block_2a_conv_3[0][0] \n", " block_2a_conv_shortcut[0][0] \n", "__________________________________________________________________________________________________\n", "block_2a_relu (Activation) (None, 512, 28, 28) 0 add_4[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_conv_1 (Conv2D) (None, 128, 28, 28) 65536 block_2a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_relu_1 (Activation) (None, 128, 28, 28) 0 block_2b_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_conv_2 (Conv2D) (None, 128, 28, 28) 147456 block_2b_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_relu_2 (Activation) (None, 128, 28, 28) 0 block_2b_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_conv_3 (Conv2D) (None, 512, 28, 28) 65536 block_2b_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_5 (Add) (None, 512, 28, 28) 0 block_2b_conv_3[0][0] \n", " block_2a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2b_relu (Activation) (None, 512, 28, 28) 0 add_5[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_conv_1 (Conv2D) (None, 128, 28, 28) 65536 block_2b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_relu_1 (Activation) (None, 128, 28, 28) 0 block_2c_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_conv_2 (Conv2D) (None, 128, 28, 28) 147456 block_2c_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_relu_2 (Activation) (None, 128, 28, 28) 0 block_2c_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_conv_3 (Conv2D) (None, 512, 28, 28) 65536 block_2c_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_6 (Add) (None, 512, 28, 28) 0 block_2c_conv_3[0][0] \n", " block_2b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2c_relu (Activation) (None, 512, 28, 28) 0 add_6[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_conv_1 (Conv2D) (None, 128, 28, 28) 65536 block_2c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_relu_1 (Activation) (None, 128, 28, 28) 0 block_2d_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_conv_2 (Conv2D) (None, 128, 28, 28) 147456 block_2d_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_relu_2 (Activation) (None, 128, 28, 28) 0 block_2d_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_conv_3 (Conv2D) (None, 512, 28, 28) 65536 block_2d_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_7 (Add) (None, 512, 28, 28) 0 block_2d_conv_3[0][0] \n", " block_2c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_2d_relu (Activation) (None, 512, 28, 28) 0 add_7[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_conv_1 (Conv2D) (None, 256, 14, 14) 131072 block_2d_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_relu_1 (Activation) (None, 256, 14, 14) 0 block_3a_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3a_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_relu_2 (Activation) (None, 256, 14, 14) 0 block_3a_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3a_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_conv_shortcut (Conv2D) (None, 1024, 14, 14) 524288 block_2d_relu[0][0] \n", "__________________________________________________________________________________________________\n", "add_8 (Add) (None, 1024, 14, 14) 0 block_3a_conv_3[0][0] \n", " block_3a_conv_shortcut[0][0] \n", "__________________________________________________________________________________________________\n", "block_3a_relu (Activation) (None, 1024, 14, 14) 0 add_8[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_conv_1 (Conv2D) (None, 256, 14, 14) 262144 block_3a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_relu_1 (Activation) (None, 256, 14, 14) 0 block_3b_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3b_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_relu_2 (Activation) (None, 256, 14, 14) 0 block_3b_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3b_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_9 (Add) (None, 1024, 14, 14) 0 block_3b_conv_3[0][0] \n", " block_3a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3b_relu (Activation) (None, 1024, 14, 14) 0 add_9[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_conv_1 (Conv2D) (None, 256, 14, 14) 262144 block_3b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_relu_1 (Activation) (None, 256, 14, 14) 0 block_3c_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3c_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_relu_2 (Activation) (None, 256, 14, 14) 0 block_3c_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3c_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_10 (Add) (None, 1024, 14, 14) 0 block_3c_conv_3[0][0] \n", " block_3b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3c_relu (Activation) (None, 1024, 14, 14) 0 add_10[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_conv_1 (Conv2D) (None, 256, 14, 14) 262144 block_3c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_relu_1 (Activation) (None, 256, 14, 14) 0 block_3d_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3d_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_relu_2 (Activation) (None, 256, 14, 14) 0 block_3d_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3d_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_11 (Add) (None, 1024, 14, 14) 0 block_3d_conv_3[0][0] \n", " block_3c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3d_relu (Activation) (None, 1024, 14, 14) 0 add_11[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_conv_1 (Conv2D) (None, 256, 14, 14) 262144 block_3d_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_relu_1 (Activation) (None, 256, 14, 14) 0 block_3e_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3e_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_relu_2 (Activation) (None, 256, 14, 14) 0 block_3e_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3e_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_12 (Add) (None, 1024, 14, 14) 0 block_3e_conv_3[0][0] \n", " block_3d_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3e_relu (Activation) (None, 1024, 14, 14) 0 add_12[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_conv_1 (Conv2D) (None, 256, 14, 14) 262144 block_3e_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_relu_1 (Activation) (None, 256, 14, 14) 0 block_3f_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_conv_2 (Conv2D) (None, 256, 14, 14) 589824 block_3f_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_relu_2 (Activation) (None, 256, 14, 14) 0 block_3f_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_conv_3 (Conv2D) (None, 1024, 14, 14) 262144 block_3f_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_13 (Add) (None, 1024, 14, 14) 0 block_3f_conv_3[0][0] \n", " block_3e_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_3f_relu (Activation) (None, 1024, 14, 14) 0 add_13[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_conv_1 (Conv2D) (None, 512, 14, 14) 524288 block_3f_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_relu_1 (Activation) (None, 512, 14, 14) 0 block_4a_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_conv_2 (Conv2D) (None, 512, 14, 14) 2359296 block_4a_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_relu_2 (Activation) (None, 512, 14, 14) 0 block_4a_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_conv_3 (Conv2D) (None, 2048, 14, 14) 1048576 block_4a_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_conv_shortcut (Conv2D) (None, 2048, 14, 14) 2097152 block_3f_relu[0][0] \n", "__________________________________________________________________________________________________\n", "add_14 (Add) (None, 2048, 14, 14) 0 block_4a_conv_3[0][0] \n", " block_4a_conv_shortcut[0][0] \n", "__________________________________________________________________________________________________\n", "block_4a_relu (Activation) (None, 2048, 14, 14) 0 add_14[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_conv_1 (Conv2D) (None, 512, 14, 14) 1048576 block_4a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_relu_1 (Activation) (None, 512, 14, 14) 0 block_4b_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_conv_2 (Conv2D) (None, 512, 14, 14) 2359296 block_4b_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_relu_2 (Activation) (None, 512, 14, 14) 0 block_4b_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_conv_3 (Conv2D) (None, 2048, 14, 14) 1048576 block_4b_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_15 (Add) (None, 2048, 14, 14) 0 block_4b_conv_3[0][0] \n", " block_4a_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_4b_relu (Activation) (None, 2048, 14, 14) 0 add_15[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_conv_1 (Conv2D) (None, 512, 14, 14) 1048576 block_4b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_relu_1 (Activation) (None, 512, 14, 14) 0 block_4c_conv_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_conv_2 (Conv2D) (None, 512, 14, 14) 2359296 block_4c_relu_1[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_relu_2 (Activation) (None, 512, 14, 14) 0 block_4c_conv_2[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_conv_3 (Conv2D) (None, 2048, 14, 14) 1048576 block_4c_relu_2[0][0] \n", "__________________________________________________________________________________________________\n", "add_16 (Add) (None, 2048, 14, 14) 0 block_4c_conv_3[0][0] \n", " block_4b_relu[0][0] \n", "__________________________________________________________________________________________________\n", "block_4c_relu (Activation) (None, 2048, 14, 14) 0 add_16[0][0] \n", "__________________________________________________________________________________________________\n", "avg_pool (AveragePooling2D) (None, 2048, 1, 1) 0 block_4c_relu[0][0] \n", "__________________________________________________________________________________________________\n", "flatten (Flatten) (None, 2048) 0 avg_pool[0][0] \n", "__________________________________________________________________________________________________\n", "predictions (Dense) (None, 4) 8196 flatten[0][0] \n", "==================================================================================================\n", "Total params: 23,463,108\n", "Trainable params: 23,453,700\n", "Non-trainable params: 9,408\n", "__________________________________________________________________________________________________\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/optimizers.py:790: The name tf.train.Optimizer is deprecated. Please use tf.compat.v1.train.Optimizer instead.\n", "\n", "2025-12-25 08:44:53,062 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/optimizers.py:790: The name tf.train.Optimizer is deprecated. Please use tf.compat.v1.train.Optimizer instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:3295: The name tf.log is deprecated. Please use tf.math.log instead.\n", "\n", "2025-12-25 08:44:53,073 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:3295: The name tf.log is deprecated. Please use tf.math.log instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1133: The name tf.summary.FileWriter is deprecated. Please use tf.compat.v1.summary.FileWriter instead.\n", "\n", "2025-12-25 08:44:53,100 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1133: The name tf.summary.FileWriter is deprecated. Please use tf.compat.v1.summary.FileWriter instead.\n", "\n", "2025-12-25 08:44:53,100 [TAO Toolkit] [INFO] nvidia_tao_tf1.cv.common.logging.logging 197: Log file already exists at /workspace/tao-experiments/classification/resnet50/status.json\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:986: The name tf.assign_add is deprecated. Please use tf.compat.v1.assign_add instead.\n", "\n", "2025-12-25 08:44:54,293 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:986: The name tf.assign_add is deprecated. Please use tf.compat.v1.assign_add instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:973: The name tf.assign is deprecated. Please use tf.compat.v1.assign instead.\n", "\n", "2025-12-25 08:44:54,436 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/keras/backend/tensorflow_backend.py:973: The name tf.assign is deprecated. Please use tf.compat.v1.assign instead.\n", "\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1181: The name tf.summary.merge_all is deprecated. Please use tf.compat.v1.summary.merge_all instead.\n", "\n", "2025-12-25 08:44:55,916 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:1181: The name tf.summary.merge_all is deprecated. Please use tf.compat.v1.summary.merge_all instead.\n", "\n", "2025-12-25 08:44:57,086 [TAO Toolkit] [INFO] root 2102: Starting Training Loop.\n", "Epoch 1/15\n", "WARNING:tensorflow:From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:199: The name tf.Summary is deprecated. Please use tf.compat.v1.Summary instead.\n", "\n", "2025-12-25 08:45:16,531 [TAO Toolkit] [WARNING] tensorflow 137: From /usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/common/utils.py:199: The name tf.Summary is deprecated. Please use tf.compat.v1.Summary instead.\n", "\n", "3/3 [==============================] - 30s 10s/step - loss: 2.5789 - acc: 0.5673 - val_loss: 2.8771 - val_acc: 0.8333\n", "2025-12-25 08:45:36,733 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 2/15\n", "3/3 [==============================] - 1s 313ms/step - loss: 3.0641 - acc: 0.8217 - val_loss: 2.8772 - val_acc: 0.8333\n", "2025-12-25 08:45:42,533 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 3/15\n", "3/3 [==============================] - 1s 310ms/step - loss: 2.8919 - acc: 0.8324 - val_loss: 2.8772 - val_acc: 0.8333\n", "2025-12-25 08:45:44,790 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 4/15\n", "3/3 [==============================] - 1s 287ms/step - loss: 2.7197 - acc: 0.8431 - val_loss: 2.8773 - val_acc: 0.8333\n", "2025-12-25 08:45:46,405 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 5/15\n", "3/3 [==============================] - 1s 289ms/step - loss: 2.7197 - acc: 0.8431 - val_loss: 2.8774 - val_acc: 0.8333\n", "2025-12-25 08:45:48,033 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 6/15\n", "3/3 [==============================] - 1s 286ms/step - loss: 2.8921 - acc: 0.8324 - val_loss: 2.8774 - val_acc: 0.8333\n", "2025-12-25 08:45:49,226 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 7/15\n", "3/3 [==============================] - 1s 289ms/step - loss: 3.1506 - acc: 0.8164 - val_loss: 2.8775 - val_acc: 0.8333\n", "2025-12-25 08:45:50,405 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 8/15\n", "3/3 [==============================] - 1s 283ms/step - loss: 3.0645 - acc: 0.8217 - val_loss: 2.8775 - val_acc: 0.8333\n", "2025-12-25 08:45:51,592 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 9/15\n", "3/3 [==============================] - 1s 289ms/step - loss: 2.9784 - acc: 0.8271 - val_loss: 2.8775 - val_acc: 0.8333\n", "2025-12-25 08:45:52,787 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 10/15\n", "3/3 [==============================] - 1s 283ms/step - loss: 2.6338 - acc: 0.8485 - val_loss: 2.8775 - val_acc: 0.8333\n", "2025-12-25 08:45:53,947 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 11/15\n", "3/3 [==============================] - 1s 286ms/step - loss: 3.0646 - acc: 0.8217 - val_loss: 2.8776 - val_acc: 0.8333\n", "2025-12-25 08:45:55,132 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 12/15\n", "3/3 [==============================] - 1s 286ms/step - loss: 2.9784 - acc: 0.8271 - val_loss: 2.8776 - val_acc: 0.8333\n", "2025-12-25 08:45:56,311 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 13/15\n", "3/3 [==============================] - 1s 284ms/step - loss: 2.9784 - acc: 0.8271 - val_loss: 2.8776 - val_acc: 0.8333\n", "2025-12-25 08:45:57,479 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 14/15\n", "3/3 [==============================] - 1s 284ms/step - loss: 2.7200 - acc: 0.8431 - val_loss: 2.8776 - val_acc: 0.8333\n", "2025-12-25 08:45:58,647 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "Epoch 15/15\n", "3/3 [==============================] - 1s 283ms/step - loss: 2.8061 - acc: 0.8378 - val_loss: 2.8776 - val_acc: 0.8333\n", "2025-12-25 08:45:59,816 [TAO Toolkit] [INFO] root 2102: Training loop in progress\n", "2025-12-25 08:45:59,833 [TAO Toolkit] [INFO] root 2102: Training loop complete.\n", "2025-12-25 08:45:59,839 [TAO Toolkit] [INFO] root 2102: Final model evaluation in progress.\n", "2025-12-25 08:46:00,696 [TAO Toolkit] [INFO] root 2102: Model evaluation is complete.\n", "2025-12-25 08:46:00,697 [TAO Toolkit] [INFO] __main__ 625: Total Val Loss: 2.8775815963745117\n", "2025-12-25 08:46:00,697 [TAO Toolkit] [INFO] __main__ 626: Total Val accuracy: 0.8333333134651184\n", "2025-12-25 08:46:00,697 [TAO Toolkit] [INFO] root 2102: Training finished successfully.\n", "2025-12-25 08:46:00,697 [TAO Toolkit] [INFO] __main__ 651: Training finished successfully.\n", "Telemetry data couldn't be sent, but the command ran successfully.\n", "[WARNING]: \n", "Execution status: PASS\n", "2025-12-25 08:46:22,952 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 363: Stopping container.\n" ] } ], "source": [ "!tao model classification_tf1 train -e $TAO_SPECS_DIR/resnet50/config.txt \\\n", " -r $TAO_EXPERIMENT_DIR/resnet50 \\\n", " -k $KEY" ] }, { "cell_type": "code", "execution_count": null, "id": "7c99eaa3-dc72-4833-b074-c4f250fd58a3", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "2025-12-25 08:47:26,493 [TAO Toolkit] [INFO] root 160: Registry: ['nvcr.io']\n", "2025-12-25 08:47:26,611 [TAO Toolkit] [INFO] nvidia_tao_cli.components.instance_handler.local_instance 360: Running command in container: nvcr.io/nvidia/tao/tao-toolkit:5.0.0-tf1.15.5\n", "2025-12-25 08:47:26,629 [TAO Toolkit] [INFO] nvidia_tao_cli.components.docker_handler.docker_handler 301: Printing tty value True\n", "Using TensorFlow backend.\n", "2025-12-25 08:47:27.758154: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:47:27,819 [TAO Toolkit] [WARNING] tensorflow 40: Deprecation warnings have been disabled. Set TF_ENABLE_DEPRECATION_WARNINGS=1 to re-enable them.\n", "2025-12-25 08:47:29,792 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use sklearn by default. This improves performance in some cases. To enable sklearn export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:47:29,836 [TAO Toolkit] [WARNING] tensorflow 42: TensorFlow will not use Dask by default. This improves performance in some cases. To enable Dask export the environment variable TF_ALLOW_IOLIBS=1.\n", "2025-12-25 08:47:29,841 [TAO Toolkit] [WARNING] tensorflow 43: TensorFlow will not use Pandas by default. This improves performance in some cases. To enable Pandas export the environment variable TF_ALLOW_IOLIBS=1.\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:150: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_hue(img, max_delta=10.0):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:173: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_saturation(img, max_shift):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:183: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_contrast(img, center, max_contrast_scale):\n", "/usr/local/lib/python3.8/dist-packages/nvidia_tao_tf1/cv/makenet/utils/helper.py:192: NumbaDeprecationWarning: The 'nopython' keyword argument was not supplied to the 'numba.jit' decorator. The implicit default value for this argument is currently False, but it will be changed to True in Numba 0.59.0. See https://numba.readthedocs.io/en/stable/reference/deprecation.html#deprecation-of-object-mode-fall-back-behaviour-when-using-jit for details.\n", " def random_shift(x_img, shift_stddev):\n", "2025-12-25 08:47:31.972455: I tensorflow/core/platform/profile_utils/cpu_utils.cc:109] CPU Frequency: 2499995000 Hz\n", "2025-12-25 08:47:31.972882: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x8a40100 initialized for platform Host (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:47:31.972930: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Host, Default Version\n", "2025-12-25 08:47:31.974821: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcuda.so.1\n", "2025-12-25 08:47:32.174011: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.176045: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x885b4b0 initialized for platform CUDA (this does not guarantee that XLA will be used). Devices:\n", "2025-12-25 08:47:32.176083: I tensorflow/compiler/xla/service/service.cc:176] StreamExecutor device (0): Tesla T4, Compute Capability 7.5\n", "2025-12-25 08:47:32.176402: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.178239: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1674] Found device 0 with properties: \n", "name: Tesla T4 major: 7 minor: 5 memoryClockRate(GHz): 1.59\n", "pciBusID: 0000:00:1e.0\n", "2025-12-25 08:47:32.178306: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:47:32.178428: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcublas.so.12\n", "2025-12-25 08:47:32.180627: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcufft.so.11\n", "2025-12-25 08:47:32.180744: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcurand.so.10\n", "2025-12-25 08:47:32.184414: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusolver.so.11\n", "2025-12-25 08:47:32.185675: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcusparse.so.12\n", "2025-12-25 08:47:32.185762: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudnn.so.8\n", "2025-12-25 08:47:32.185921: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.187870: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.189683: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1802] Adding visible gpu devices: 0\n", "2025-12-25 08:47:32.189744: I tensorflow/stream_executor/platform/default/dso_loader.cc:50] Successfully opened dynamic library libcudart.so.12\n", "2025-12-25 08:47:32.198735: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1214] Device interconnect StreamExecutor with strength 1 edge matrix:\n", "2025-12-25 08:47:32.198790: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1220] 0 \n", "2025-12-25 08:47:32.198805: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1233] 0: N \n", "2025-12-25 08:47:32.199111: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.201132: I tensorflow/stream_executor/cuda/cuda_gpu_executor.cc:1082] successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero\n", "2025-12-25 08:47:32.202987: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1359] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 13496 MB memory) -> physical GPU (device: 0, name: Tesla T4, pci bus id: 0000:00:1e.0, compute capability: 7.5)\n" ] } ], "source": [ "!tao model classification_tf1 evaluate -e $TAO_SPECS_DIR/resnet50/config.txt\\\n", " -k $KEY \\\n", " --log_file $TAO_PROJECT_DIR/log_file_resnet.txt" ] }, { "cell_type": "markdown", "id": "5384a9ac-c05b-4179-940a-9fdfab23337e", "metadata": {}, "source": [ "Click [here](tao_project/log_file.txt) to view the log file. " ] }, { "cell_type": "code", "execution_count": null, "id": "7a796eaf-3086-48fa-b18c-7d227ad410c8", "metadata": {}, "outputs": [], "source": [ "# 4.2\n", "# DO NOT CHANGE THIS CELL\n", "!cp $LOCAL_PROJECT_DIR/log_file.txt my_assessment/log_file.txt" ] }, { "cell_type": "markdown", "id": "aab7921b-734c-4cb1-8b91-7ab1b00892cb", "metadata": {}, "source": [ "### Grade Your Code ###\n", "If you have trained the model and completed model evaluation successfully, save changes to the notebook and revisit the webpage where you launched this interactive environment. Click on the \"**ASSESS TASK**\" button as shown in the screenshot below. Doing so will give you credit for this part of the lab that counts towards earning a certificate of competency for the entire course.\n", "

" ] }, { "cell_type": "markdown", "id": "e9e13c81-abd4-43a2-bfe8-774116b3257f", "metadata": {}, "source": [ "\"Header\"" ] } ], "metadata": { "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.10.12" } }, "nbformat": 4, "nbformat_minor": 5 }