working now
detection preprocess added