              temp_list = [[x, self.estimate_blur(cv2.imread(x))] for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout)]
          elif group_method == 'group_face':
              temp_list = [[x, face_recognition.face_encodings(cv2.imread(x))] for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout)]
          elif group_method == 'group_face_cnn':
              from lib import FaceLandmarksExtractor
              temp_list = []
              for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout):
                  d = FaceLandmarksExtractor.extract(cv2.imread(x), 'cnn', True, input_is_predetected_face=True)
                  temp_list.append([x, np.array(d[0][1]) if len(d) > 0 else np.zeros((68, 2))])
          elif group_method == 'group_hist':
 
</s> remove         from lib import FaceLandmarksExtractor
 </s> add         import_FaceLandmarksExtractor()
            import_FaceLandmarksExtractor()
              temp_list = [[x, self.estimate_blur(cv2.imread(x))] for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout)]
          elif group_method == 'group_face':
              temp_list = [[x, face_recognition.face_encodings(cv2.imread(x))] for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout)]
          elif group_method == 'group_face_cnn':
            import_FaceLandmarksExtractor()
              temp_list = []
              for x in tqdm(self.find_images(input_dir), desc="Reloading", file=sys.stdout):
                  d = FaceLandmarksExtractor.extract(cv2.imread(x), 'cnn', True, input_is_predetected_face=True)
                  temp_list.append([x, np.array(d[0][1]) if len(d) > 0 else np.zeros((68, 2))])
          elif group_method == 'group_hist':
keep keep keep keep replace keep keep keep keep keep
 Only import DLIB related modules when required and minor import relocations (#315)

* Move imports to top and add conditions to load modules requiring GPU

* Fix type

* Fix typo

* Import relocation and dlib import on demand

* refactor to remove extra code lines

* remove unnecessary sys import 
tools/sort.py