Alex Strick van Linschoten commited on
Commit
02f3e99
1 Parent(s): a662dcb

update fpdf instruction

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -138,7 +138,6 @@ def predict(pdf, confidence, generate_file):
138
  font_size=16,
139
  label_color="#FF59D6",
140
  )
141
- # print(pred_dict)
142
 
143
  total_image_areas += pred_dict["width"] * pred_dict["height"]
144
  total_content_areas += get_content_area(pred_dict)
@@ -153,7 +152,9 @@ def predict(pdf, confidence, generate_file):
153
  pdf.image(
154
  os.path.join(
155
  tmp_dir, filename_without_extension, f"pred-{image}"
156
- )
 
 
157
  )
158
  pdf.output(report, "F")
159
 
138
  font_size=16,
139
  label_color="#FF59D6",
140
  )
 
141
 
142
  total_image_areas += pred_dict["width"] * pred_dict["height"]
143
  total_content_areas += get_content_area(pred_dict)
152
  pdf.image(
153
  os.path.join(
154
  tmp_dir, filename_without_extension, f"pred-{image}"
155
+ ),
156
+ w=pdf.w,
157
+ h=pdf.h,
158
  )
159
  pdf.output(report, "F")
160