Template Matching in industrial inspection