Detects holes/cracks in defective vehicle welds. To use pre-trained model, use best.pt.
To train a different model, use the following file format:
- Create a folder in project directory titled "Data"
- Inside "Data", create an Annotations folder that includes XML labels with the formatting detailed below. The most important tag is the "bndbox" tag and its associated coordinates along with the "name" tag which indicates the class.
<annotation>
<size>
<width>416</width>
<height>416</height>
<depth>3</depth>
</size>
<segmented>0</segmented>
<object>
<name>hole</name>
<pose>Unspecified</pose>
<truncated>0</truncated>
<difficult>0</difficult>
<bndbox>
<xmin>239</xmin>
<ymin>218</ymin>
<xmax>295</xmax>
<ymax>280</ymax>
</bndbox>
</object>
</annotation>-
For each label, include another folder inside "Data" called "JPEGImages" which includes an image for each label in "Annotations". The image must be named as "__.jpg", keep in mind that the __ must match its associated label name in "Annotations".
-
Finally, create the following folder structure before running main2.py:

