diff --git a/dedocutils/preprocessing/skew_corrector.py b/dedocutils/preprocessing/skew_corrector.py index 9c293ea..69d4ffb 100644 --- a/dedocutils/preprocessing/skew_corrector.py +++ b/dedocutils/preprocessing/skew_corrector.py @@ -40,7 +40,7 @@ def preprocess(self, image: np.ndarray, parameters: Optional[dict] = None) -> Tu best_angle = angles[scores.index(max(scores))] rotated = rotate_image(image, best_angle) - return rotated, {"rotated_angle": orientation_angle + best_angle} + return rotated, {"rotated_angle": float(orientation_angle + best_angle)} def __determine_score(self, arr: np.ndarray, angle: int) -> Tuple[np.ndarray, float]: data = rotate_image(arr, angle)