Text this: Object detection and near-miss analysis in traffic videos of high and low quality based on the YOLO model