S2VT icon indicating copy to clipboard operation
S2VT copied to clipboard

TypeError: 'map' object is not subscriptable

Open holibert opened this issue 6 years ago • 1 comments

File "model_RGB.py", line 327, in train current_feats[ind][:len(current_feats_vals[ind])] = feat TypeError: 'map' object is not subscriptable

I can't fix it. Anyone can help?

holibert avatar Mar 21 '18 14:03 holibert

if use python3.x to compile, you need:

current_feats[ind][:len(current_feats_vals[ind])] = feat

change to

current_feats_vals = list(map(lambda vid: np.load(vid), current_videos))

Python 2.x return list。

Python 3.x return 'map' object。

holibert avatar Mar 22 '18 09:03 holibert