@@ -669,9 +669,8 @@ def _process_element(self, element, ignore, image, coords, element_id, file_id,
669
669
element_array [sepmask ] = np .amax (element_array ) # clip to white/bg
670
670
image_clipped = array2pil (element_array )
671
671
file_path = self .workspace .save_image_file (
672
- image_clipped , file_id + '.IMG-CLIP' ,
673
- page_id = page_id ,
674
- file_grp = self .output_file_grp )
672
+ image_clipped , file_id + '.IMG-CLIP' , self .output_file_grp ,
673
+ page_id = page_id )
675
674
element .add_AlternativeImage (AlternativeImageType (
676
675
filename = file_path , comments = coords ['features' ] + ',clipped' ))
677
676
else :
@@ -708,9 +707,8 @@ def _process_element(self, element, ignore, image, coords, element_id, file_id,
708
707
element_array [sep_bin ] = np .amax (element_array ) # clip to white/bg
709
708
image_clipped = array2pil (element_array )
710
709
file_path = self .workspace .save_image_file (
711
- image_clipped , file_id + '.IMG-CLIP' ,
712
- page_id = page_id ,
713
- file_grp = self .output_file_grp )
710
+ image_clipped , file_id + '.IMG-CLIP' , self .output_file_grp ,
711
+ page_id = page_id )
714
712
# update PAGE (reference the image file):
715
713
element .add_AlternativeImage (AlternativeImageType (
716
714
filename = file_path , comments = coords ['features' ] + ',clipped' ))
0 commit comments