ValueError: setting an array element with a sequence

后端 未结 8 1306
萌比男神i
萌比男神i 2020-11-22 05:46

This Python code:

import numpy as p

def firstfunction():
    UnFilteredDuringExSummaryOfMeansArray = []
    MeanOutputHeader=[\'TestID\',\'         


        
8条回答
  •  庸人自扰
    2020-11-22 06:37

    In my case, the problem was another. I was trying convert lists of lists of int to array. The problem was that there was one list with a different length than others. If you want to prove it, you must do:

    print([i for i,x in enumerate(list) if len(x) != 560])
    

    In my case, the length reference was 560.

提交回复
热议问题