# Machine Learning-Based Highway Truck Commodity Classification Using Logo Data
## 4 Experiments
### Dataset Collection and Processing  
Benchmark DatasetsWe evaluated our logo detection and recognition approaches on video frames captured by roadside cameras provided by the Florida Department of Transportation (FDOT). Among all logos shown up in the recorded videos, We picked 26 logo classes based on frequency of occurrence, which contains several top carrier companies in the US ([[https://www.tnews.com/top100/for-hire/2019](https://www.tnews.com/top100/for-hire/2019)]([https://www.tnews.com/top100/for-hire/2019](https://www.tnews.com/top100/for-hire/2019)) Accessed: 10 June 2020). When choosing logo classes, we also diversify the classes by including styled text logos, shape-based logos, and logos shown on different types of trailers. The chosen 26 classes do not represent full coverage of all logo classes of interest but are illustrative to evaluate our proposed approach. On one of the roadside videos, we annotated all logos that belong to the 26 chosen logo classes as a dataset, referred to as the Annotated Logo Dataset (ALD). \begin{table}
\begin{tabular}{c l l l} \hline \hline
**NAICS Code** & **Description** & **NAICS Code** & **Description** \\ \hline
311919 & Other Snack Food Manufacturing & 485119 & Other Urban Transit Systems \\ \hline
337127 & Institutional Furniture Manufacturing & 488510 & Freight Transportation Arrangement \\ \hline
424490 & Other Grocery and Related Products & 484230 & Specialized Freight (except Used Goods) \\  & Merchant Wholesalers & 484230 & Trucking, Long-Distance \\ \hline
445110 & Supermarkets and Other Grocery & 532120 & Truck Utility Trailer and RV Rental and \\  & (except Convenience) Stores & 532120 & Leasing \\ \hline
484121 & General Freight Trucking & 551112 & Offices of Other Holding Companies \\  & Long-Distance Truckload & 551112 & \multicolumn{1}{c}{} \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Samples of the NAICS code searching. Each annotation consists of a bounding box around the target logo and the logo class. This dataset consists of 4486 images and 5020 logos and is used to evaluate logo detection and recognition performance. Detailed distributions of logo classes are shown in Table 2. In addition, we collected a gallery logo dataset (GLD) from the internet. For each logo class, we collected around 30 samples. This dataset is used in our feature-matching logo recognizer. Utilizing both datasets, we are able to execute and evaluate the logo detection and recognition pipeline for freight classification. To provide a more in-depth evaluation and analysis of our logo recognition pipeline, we divided the 26 logo classes into 3 groups ('easy','medium', and 'difficult') according to the recognition difficulty. The detailed division can be found in Table 2 and samples of each group can be found in Figure 5. Most of the 'easy' logos tend to have a relatively clean background and high contrast between texts and the background. For example, we can easily separate the Dollar General text of the dark color from its smooth and single background with the yellow color. The model can extract discriminative features from these logos. We define logos containing multiple text lines as the'medium' logos, which covers the typical cases such as Heartland Express and US Foods. The challenge mainly comes from the text arrangement. In addition, we have to handle logos of different colors and textures. The 'difficult' logos is very challenging due to their artistic fonts and figures (such as 'OD' and 'E'), extremely small text sizes, and low contrasts and reflective lighting conditions caused by logo and truck compartment materials. Training DatasetsTo train our universal logo detector and deep metric learning model, we exploited the existing large logo dataset called QMUL-OpenLogo [14] due to its rich annotations of logo instances with diverse appearances and background contexts. The QMUL-OpenLogo dataset consists of 27,083 images from 352 logo classes. Evaluation ProtocolsWe adopted a standard object detection evaluation protocols to evaluate our developed pipeline.