root commited on
Commit
82c0486
1 Parent(s): 3cb1edf
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -132,7 +132,7 @@ def sr_request_images(img_str, idx):
132
  }
133
  idx = idx_map[idx]
134
  image_data = re.sub('^data:image/.+;base64,', '', img_str[idx])
135
- d = {"data":[image_data, 0]} # batch_size设置为0,
136
  url = "http://flagart.baai.ac.cn/api/general/"
137
  r = requests.post(url, json=d, headers={"Content-Type": "application/json", "Accept": "*/*", "Accept-Encoding": "gzip, deflate, br", "Connection": "keep-alive"})
138
  result_text = r.text
 
132
  }
133
  idx = idx_map[idx]
134
  image_data = re.sub('^data:image/.+;base64,', '', img_str[idx])
135
+ d = {"data":[image_data, 0, False]} # batch_size设置为0,sr_opt设置为False
136
  url = "http://flagart.baai.ac.cn/api/general/"
137
  r = requests.post(url, json=d, headers={"Content-Type": "application/json", "Accept": "*/*", "Accept-Encoding": "gzip, deflate, br", "Connection": "keep-alive"})
138
  result_text = r.text