1.新增是否推理获取特征判断
2.取消搭配不足异常逻辑
This commit is contained in:
@@ -86,8 +86,8 @@ class FashionDataset(object):
|
||||
outerwear = random.choice(self.cate2item['outerwear'])
|
||||
outfit.append(outerwear)
|
||||
outfit_list.append(tuple(outfit))
|
||||
if len(outfit_list) < topk:
|
||||
raise ValueError(f"Cannot generate more than {topk} outfits!")
|
||||
# if len(outfit_list) < topk:
|
||||
# raise ValueError(f"Cannot generate more than {topk} outfits!")
|
||||
|
||||
return outfit_list
|
||||
elif given_cate == 'outerwear':
|
||||
@@ -112,8 +112,8 @@ class FashionDataset(object):
|
||||
outfit = [query_item] + list(top_bottom)
|
||||
outfit_list.append(tuple(outfit))
|
||||
|
||||
if len(outfit_list) < topk:
|
||||
raise ValueError(f"Cannot generate more than {topk} outfits!")
|
||||
# if len(outfit_list) < topk:
|
||||
# raise ValueError(f"Cannot generate more than {topk} outfits!")
|
||||
|
||||
return outfit_list
|
||||
elif given_cate == 'all-body':
|
||||
|
||||
Reference in New Issue
Block a user