commit need complete detectedges function