andywu-kby commited on
Commit
2020ffa
1 Parent(s): 5c80046

Include area and perimeter

Browse files
Files changed (1) hide show
  1. app.py +8 -1
app.py CHANGED
@@ -23,7 +23,14 @@ def run(file):
23
  out_img = image_request.json()['image']
24
  door_json = image_request.json()['doors']
25
  wall_json = image_request.json()['walls']
26
- out_json = {'doors': door_json, 'walls': wall_json}
 
 
 
 
 
 
 
27
 
28
  decode_img = base64.b64decode(out_img.split(',')[1])
29
  decode_img = np.frombuffer(decode_img, dtype=np.uint8)
 
23
  out_img = image_request.json()['image']
24
  door_json = image_request.json()['doors']
25
  wall_json = image_request.json()['walls']
26
+ area = image_request.json()['area']
27
+ perimeter = image_request.json()['perimeter']
28
+ out_json = {
29
+ 'doors': door_json,
30
+ 'walls': wall_json,
31
+ 'area': area,
32
+ 'perimeter': perimeter
33
+ }
34
 
35
  decode_img = base64.b64decode(out_img.split(',')[1])
36
  decode_img = np.frombuffer(decode_img, dtype=np.uint8)