working import of the image data and detection information
moved working input and output code to the testing loop as well, and got rid of log statements