          """
          with self._cache["cropped_slices"][1]:
              if not self._cache["cropped_slices"][0].get(self._centering):
                  roi = self.get_cropped_roi(self._centering)
                  head_size = self._head_size
                  slice_in = [slice(max(roi[1], 0), max(roi[3], 0)),
                              slice(max(roi[0], 0), max(roi[2], 0))]
                  slice_out = [slice(max(roi[1] * -1, 0), self._size - max(0, roi[3] - head_size)),
                               slice(max(roi[0] * -1, 0), self._size - max(0, roi[2] - head_size))]
                  self._cache["cropped_slices"][0][self._centering] = {"in": slice_in,
 
</s> remove                 slice_out = [slice(max(roi[1] * -1, 0), self._size - max(0, roi[3] - head_size)),
                             slice(max(roi[0] * -1, 0), self._size - max(0, roi[2] - head_size))]
 </s> add                 slice_out = [slice(max(roi[1] * -1, 0),
                                   self._size - min(self._size, max(0, roi[3] - self._head_size))),
                             slice(max(roi[0] * -1, 0),
                                   self._size - min(self._size, max(0, roi[2] - self._head_size)))] </s> remove         self._sub_crop["slice_out"] = [slice(max(roi[1] * -1, 0),
                                             crop_size - max(0, roi[3] - self.stored_size)),
                                       slice(max(roi[0] * -1, 0),
                                             crop_size - max(0, roi[2] - self.stored_size))]
 </s> add         self._sub_crop["slice_out"] = [
            slice(max(roi[1] * -1, 0),
                  crop_size - min(crop_size, max(0, roi[3] - self.stored_size))),
            slice(max(roi[0] * -1, 0),
                  crop_size - min(crop_size, max(0, roi[2] - self.stored_size)))]
 </s> remove                 offset = self.pose.offset.get(centering, np.float32((0, 0)))  # legacy = 0,0
 </s> add                 offset = self.pose.offset.get(centering, np.float32((0, 0)))  # legacy = 0.0
          """
          with self._cache["cropped_slices"][1]:
              if not self._cache["cropped_slices"][0].get(self._centering):
                  roi = self.get_cropped_roi(self._centering)

                  slice_in = [slice(max(roi[1], 0), max(roi[3], 0)),
                              slice(max(roi[0], 0), max(roi[2], 0))]
                  slice_out = [slice(max(roi[1] * -1, 0), self._size - max(0, roi[3] - head_size)),
                               slice(max(roi[0] * -1, 0), self._size - max(0, roi[2] - head_size))]
                  self._cache["cropped_slices"][0][self._centering] = {"in": slice_in,
keep keep keep keep replace keep keep keep keep keep
 bugfix - lib.align - Fix edge case aligned face sub crop 
lib/align/aligned_face.py