从plot_decision_regions导入mlxtend.plotting有问题。
我已经正确地安装了mlx趋向,并且我可以在python3中导入它,而不会出现问题。
从"/home/marianna/.local/lib/python3.5/site-packages/mlxtend/plotting/init.py",导入plot_decision_regions跟踪(最近一次调用):文件"",第1行,在文件mlxtend.plotting第15行,从.heatmap导入热图文件"/home/marianna/.local/lib/python3.5/site-packages/mlxtend/plotting/heatmap.py",第74行引发AssertionError(f'len(row_names) (got {len(row_names)})‘^ SyntaxError:无效语法
发布于 2019-09-23 10:12:21
我也有同样的错误,只需将您的python版本升级到3.7,读取错误就出现在mlxtend.plotting.heatmap.py文件中,在这里他们使用f-前缀进行格式化,这是一个3.7特性。
conda install -c anaconda python=3.7https://stackoverflow.com/questions/57922222
复制相似问题