only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolean arrays are valid indices

我的错误问题:

python问题:only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolea

因为x,y的型号不符合,所以出错。
加一个强制转换,问题解决。

python问题:only integers, slices (`:`), ellipsis (`...`), numpy.newaxis (`None`) and integer or boolea

程序正常运行。

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-08-06
  • 2021-10-26
  • 2021-09-03
猜你喜欢
  • 2021-04-11
  • 2022-12-23
  • 2022-12-23
  • 2021-11-07
  • 2021-05-20
  • 2022-12-23
相关资源
相似解决方案