Merge branch 'dev/dev_xp' into dev/dev
This commit is contained in:
@@ -14,7 +14,6 @@ import com.ai.da.mapper.primary.entity.*;
|
||||
import com.ai.da.model.dto.*;
|
||||
import com.ai.da.model.enums.ModelType;
|
||||
import com.ai.da.model.enums.Sex;
|
||||
import com.ai.da.model.enums.StyleEnum;
|
||||
import com.ai.da.model.vo.*;
|
||||
import com.ai.da.python.PythonService;
|
||||
import com.ai.da.python.vo.DesignPythonItem;
|
||||
@@ -31,7 +30,6 @@ import com.google.gson.Gson;
|
||||
import io.netty.util.internal.StringUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
@@ -981,7 +979,7 @@ public class CollectionElementServiceImpl extends ServiceImpl<CollectionElementM
|
||||
String objectName = accountId + "/ImageSegment/input";
|
||||
for (MultipartFile file : files) {
|
||||
String md5 = MD5Utils.encryptFile(file);
|
||||
String segmentedResult = redisUtil.getFromString(RedisUtil.IMAGE_SEGMENTATION + md5);
|
||||
String segmentedResult = redisUtil.getFromString(RedisUtil.IMAGE_SEGMENTATION + type + ":" + md5);
|
||||
// 判断上传的图片是否有已分割的数据
|
||||
if (StringUtil.isNullOrEmpty(segmentedResult)) {
|
||||
String path = minioUtil.upload(userBucketName, objectName, file);
|
||||
@@ -1023,7 +1021,7 @@ public class CollectionElementServiceImpl extends ServiceImpl<CollectionElementM
|
||||
for (ImageSegmentation.ImageDate imageData : segmented) {
|
||||
if (isUploadMode) {
|
||||
// 上传的图片需要添加到redis中存一天
|
||||
String key = RedisUtil.IMAGE_SEGMENTATION +
|
||||
String key = RedisUtil.IMAGE_SEGMENTATION + type + ":" +
|
||||
MD5Utils.encryptFile
|
||||
(minioUtil.getPreSignedUrl
|
||||
(imageData.getImage_url(), CommonConstant.MINIO_IMAGE_EXPIRE_TIME), false);
|
||||
|
||||
Reference in New Issue
Block a user