educative.io

Educative

Name 'feature_dict' is not defined

When I’m running these lines in my PyCharm project these lines give me error: name ‘feature_dict’ is not defined. Tenserflow is imported correctly

print(feature_dict[‘Size’])
print(feature_dict[‘Store’])
print(feature_dict[‘Dept’])
print(feature_dict[‘IsHoliday’])

Hi @Piotr_Sliperski,

Thank you so much for reaching out to us. The feature_dict contains the following data which is extracted from eval_set from the previous lesson.

{'Size': int64_list {
  value: 151315
}
, 'Store': int64_list {
  value: 1
}
, 'Dept': int64_list {
  value: 81
}
, 'IsHoliday': int64_list {
  value: 0
}
}

You just need to extract that data and everything will run smoothly. If you still need any help do let me know. Thanks.