更新一些配置与配置相关的代码
This commit is contained in:
@@ -4,6 +4,8 @@ import itertools
|
||||
import difflib
|
||||
from copy import deepcopy
|
||||
|
||||
from app.core.config import FASHION_CATEGORIES, FASHION_CATEGORIES_MAPPING
|
||||
|
||||
|
||||
# Helper function to calculate the edit distance similarity between two file names
|
||||
def sim_score(a, b):
|
||||
@@ -11,12 +13,8 @@ def sim_score(a, b):
|
||||
|
||||
|
||||
class FashionDataset(object):
|
||||
fashion_categories = json.load(open(r"app/service/outfit_matcher/config/fashion_categories.json", "r"))
|
||||
fashion_categories_mapping = json.load(open(r"app/service/outfit_matcher/config/fashion_category_mapping.json", "r"))
|
||||
|
||||
# service debug
|
||||
# fashion_categories = json.load(open(r"service/outfit_matcher/config/fashion_categories.json", "r"))
|
||||
# fashion_categories_mapping = json.load(open(r"service/outfit_matcher/config/fashion_category_mapping.json", "r"))
|
||||
fashion_categories = json.load(open(FASHION_CATEGORIES, "r"))
|
||||
fashion_categories_mapping = json.load(open(FASHION_CATEGORIES_MAPPING, "r"))
|
||||
|
||||
def __init__(self, item_metadata):
|
||||
self.item_metadat = item_metadata
|
||||
|
||||
Reference in New Issue
Block a user