multimodalart HF Staff commited on
Commit
f49bf45
·
verified ·
1 Parent(s): 940f90f

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -70,7 +70,8 @@ PROGRESS_STAGES = (3, 6) # attention heads active in round 1 / round 2
70
  CACHE_VERSION = 1
71
 
72
  with open(os.path.join(os.path.dirname(__file__), "imagenet_classes.json")) as f:
73
- IMAGENET_CLASSES = [json.load(f)[str(i)] for i in range(1000)]
 
74
 
75
  MODELS = {}
76
  TRANSFORMS = {}
 
70
  CACHE_VERSION = 1
71
 
72
  with open(os.path.join(os.path.dirname(__file__), "imagenet_classes.json")) as f:
73
+ _ID2LABEL = json.load(f)
74
+ IMAGENET_CLASSES = [_ID2LABEL[str(i)] for i in range(1000)]
75
 
76
  MODELS = {}
77
  TRANSFORMS = {}