Explore Courses Blog Tutorials Interview Questions
0 votes
1 view
in Python by (120 points)

This is the portion of the code where i am getting this error. Can you suggest a solution for this problem

f_TP = open("./result_analyze/BGRU/TP_filenames.txt","ab+")

    for i in range(len(str(result[1]))):

       TP_index = result[i]


The error is :

Traceback (most recent call last):

  File "", line 240, in <module>

    main(traindataSetPath, testdataSetPath, realtestdataSetPath, weightPath, resultPath, batchSize, maxLen, vectorDim, layers, dropout)

  File "", line 154, in main


TypeError: list indices must be integers, not numpy.float64

Please log in or register to answer this question.

Welcome to Intellipaat Community. Get your technical queries answered by top developers!

28.4k questions

29.7k answers


94.1k users

Browse Categories