Updated to use threshold in image precoessing, removed tesseract dep