我在Keras使用路透社数据集。
我想知道46个主题的名字。
如何在Keras中显示路透社数据集的主题?
https://keras.io/datasets/#reuters-newswire-topics-classification
答案 0 :(得分:2)
根据原始Reuters Dataset的主题标签与Keras版本中的主题索引的关联映射为:
['cocoa','grain','veg-oil','earn','acq','wheat','copper','housing','money-supply',
'coffee','sugar','trade','reserves','ship','cotton','carcass','crude','nat-gas',
'cpi','money-fx','interest','gnp','meal-feed','alum','oilseed','gold','tin',
'strategic-metal','livestock','retail','ipi','iron-steel','rubber','heat','jobs',
'lei','bop','zinc','orange','pet-chem','dlr','gas','silver','wpi','hog','lead']
要了解提取上述映射的方法,请遵循this thread comment。