A standalone vision-based counter that counts containers in a tray or tub in a few seconds. A camera and image-processing software count the vials, ampoules or cartridges, and the result is logged for reconciliation. It replaces slow manual counting and reduces counting errors.