Browsing index pages (2 articles)
↧
TypeError: 'float' object cannot be interpreted as an index
I am facing an issue which was not occurring before, maybe some rules have been changed. Traceback (most recent call last)<ipython-input-3-f47687e192a7> in <module>() 5 n_examples =...
View ArticleAnswer by Horia Coman for TypeError: 'float' object cannot be interpreted as...
The issue might be with the range function, which comes with Python. Its arguments must be integers. n_train gets turned to a float when n_examples is multiplied by 0.5. You just need to reconvert it...
View Article
Browsing index pages (2 articles)