oskarastrom commited on
Commit
738002f
·
1 Parent(s): 72d01e6

Update pdf_handler.py

Browse files
Files changed (1) hide show
  1. gradio_scripts/pdf_handler.py +1 -1
gradio_scripts/pdf_handler.py CHANGED
@@ -149,7 +149,7 @@ def generate_fish_list(pdf, table_headers, fish_table):
149
  plt.plot([col_start*2, -col_start*2 + row_l], [y+0.05, y+0.05], color='black')
150
  for col_i, col in enumerate(row):
151
  x = col_start + row_l*(col_i+0.5)/len(row)
152
- if (col_i == dropout_i):
153
  col = str(int(col*100)) + "%"
154
  elif type(col) == float:
155
  col = "{:.4f}".format(col)
 
149
  plt.plot([col_start*2, -col_start*2 + row_l], [y+0.05, y+0.05], color='black')
150
  for col_i, col in enumerate(row):
151
  x = col_start + row_l*(col_i+0.5)/len(row)
152
+ if (col_i == dropout_i and type(col) is not str):
153
  col = str(int(col*100)) + "%"
154
  elif type(col) == float:
155
  col = "{:.4f}".format(col)