fixing floorplan detection and adding recalculation method

This commit is contained in:
Kadir 2024-03-18 00:56:39 +00:00
parent 335adc0856
commit 4dea766a12
4 changed files with 21 additions and 4 deletions

View file

@ -17,7 +17,7 @@ def inference(image_path):
def extract_total_sqm(deplot_input_str):
sqmregex = r'(\d+\.\d*) ?(sqm|sq.m|sq m|m)'
sqmregex = r'(\d+\.\d*) ?(sq ?m|sq. ?m)'
matches = re.findall(sqmregex, deplot_input_str.lower())
if len(matches) == 0:
return None