在windows中运行正常,linux中报错
ValueError: Wrong number of items passed 2, placement implies 1。
可能是由于版本不对,
解决:
attr['Package'] = attr[['Width','Length']].apply(lambda x: str(x['Width'] +'X'+x['Length']), axis=1)
改为:
attr['Package'] = attr['Width'] +'X'+attr['Length']