smellslikeml / ActionAI

Real-Time Spatio-Temporally Localized Activity Detection by Tracking Body Keypoints
https://www.hackster.io/actionai/actionai-custom-tracking-multiperson-activity-recognition-fa5cb5
GNU General Public License v3.0
772 stars 193 forks source link

TypeError: 'dict' object is not callable while running train_legday.py #6

Closed EtainLove closed 4 years ago

EtainLove commented 4 years ago

Thanks for the wonderful code.

I have got this error while running yogai on Linux PC, not on Raspberry PI.

What I did:

Traceback (most recent call last):
  File "train_legday.py", line 61, in <module>
    X_train, X_test, y_train, y_test = load_data(args.data)
  File "train_legday.py", line 32, in load_data
    y_train = keras.utils.to_categorical(list(map(lbl_dict, y_train)), num_class)
TypeError: 'dict' object is not callable

I searched a little bit, I couldn't find any solution. The error is due to this part:

list(map(lbl_dict, y_train))

Any suggestion?

smellslikeml commented 4 years ago

Hi there, Thanks for opening an issue! Fixed train_legday.py and it should train correctly now. Cheers!