File tree Expand file tree Collapse file tree 3 files changed +9
-1
lines changed
dedocutils/data_structures Expand file tree Collapse file tree 3 files changed +9
-1
lines changed Original file line number Diff line number Diff line change 11Changelog
22=========
33
4+ v0.3.8 (2024-09-05)
5+ -------------------
6+ * Add ` shift ` method to ` BBox ` class
7+
48v0.3.7 (2024-07-22)
59-------------------
610* Move ` doctr ` dependencies to a separate group
Original file line number Diff line number Diff line change 1- 0.3.7
1+ 0.3.8
Original file line number Diff line number Diff line change @@ -52,6 +52,10 @@ def y_bottom_right(self) -> int:
5252 def crop_image_by_box (image : np .ndarray , bbox : "BBox" ) -> np .ndarray :
5353 return image [bbox .y_top_left :bbox .y_bottom_right , bbox .x_top_left :bbox .x_bottom_right ]
5454
55+ def shift (self , shift_x : int , shift_y : int ) -> None :
56+ self .x_top_left += shift_x
57+ self .y_top_left += shift_y
58+
5559 def rotate_coordinates (self , angle_rotate : float , image_shape : Tuple [int ]) -> None :
5660 xb , yb = self .x_top_left , self .y_top_left
5761 xe , ye = self .x_bottom_right , self .y_bottom_right
You can’t perform that action at this time.
0 commit comments