feat design 预处理接口迁移

This commit is contained in:
zhouchengrong
2024-05-30 09:48:13 +08:00
parent 13fec64125
commit 1f47d94431
7 changed files with 361 additions and 2 deletions

View File

@@ -37,7 +37,7 @@ def get_keypoint_result(image, site):
keypoint_result = None
try:
image, scale_factor = keypoint_preprocess(image)
client = httpclient.InferenceServerClient(url=KEYPOINT_MODEL_URL)
client = httpclient.InferenceServerClient(url=DESIGN_MODEL_URL)
transformed_img = image.astype(np.float32)
inputs = [httpclient.InferInput(f"input", transformed_img.shape, datatype="FP32")]
inputs[0].set_data_from_numpy(transformed_img, binary_data=True)