logging for detection