fix bug for vesseldetector margin