Marthee commited on
Commit
d9d91e4
·
verified ·
1 Parent(s): d97dac4

Update Counting_Columns_2_1.py

Browse files
Files changed (1) hide show
  1. Counting_Columns_2_1.py +6 -0
Counting_Columns_2_1.py CHANGED
@@ -148,6 +148,9 @@ def mainfun(plan):
148
  # BROWN COLUMNS
149
  text_points = getTextsPoints(texts_from_pdf)
150
  nearby = getNearestText(text_points, column_points)
 
 
 
151
  columns_types = getColumnsTypes(nearby, texts_from_pdf)
152
  legend = generate_legend(columns_types)
153
  else:
@@ -158,6 +161,9 @@ def mainfun(plan):
158
  column_points,mask_clmns, mask_walls = get_columns_info(outsu, img)
159
  text_points = getTextsPoints(texts_from_pdf)
160
  nearby = getNearestText(text_points, column_points)
 
 
 
161
  columns_types = getColumnsTypes(nearby, texts_from_pdf)
162
  legend = generate_legend(columns_types)
163
  return legend
 
148
  # BROWN COLUMNS
149
  text_points = getTextsPoints(texts_from_pdf)
150
  nearby = getNearestText(text_points, column_points)
151
+ if rotation != 0:
152
+ if rotation ==90:
153
+ nearby = fix_rotation_90(pc_coordinates)
154
  columns_types = getColumnsTypes(nearby, texts_from_pdf)
155
  legend = generate_legend(columns_types)
156
  else:
 
161
  column_points,mask_clmns, mask_walls = get_columns_info(outsu, img)
162
  text_points = getTextsPoints(texts_from_pdf)
163
  nearby = getNearestText(text_points, column_points)
164
+ if rotation != 0:
165
+ if rotation ==90:
166
+ nearby = fix_rotation_90(pc_coordinates)
167
  columns_types = getColumnsTypes(nearby, texts_from_pdf)
168
  legend = generate_legend(columns_types)
169
  return legend