[Solved] MindSpore Error: “ValueError:invalid literal for int()with base10’the’

1 Error description

1.1 System Environment

Hardware Environment(Ascend/GPU/CPU): GPU
Software Environment:
– MindSpore version (source or binary): 1.2.0
– Python version (eg, Python 3.7.5): 3.7.5
– OS platform and distribution (eg, Linux Ubuntu 16.04): Ubuntu 4.15.0-74-generic
– GCC/Compiler version (if compiled from source):

1.2 Basic information

1.2.1 Source code


1.2.2 Error reporting

Error message: ValueError: invalid literal for int()with base10’the’.

2 Reason analysis

The data set is not processed according to the tutorial. The README states that a line needs to be added to the data set to read 400,000 words, each of which is represented by a 300-dimensional word vector.

3 Solutions

Insert a line before the first line of the glove.6B.300d.txt file: 400000 300

4 Summary

When running the model in the official tutorial, try to follow the steps in the README. Omitting the data processing steps may result in an error.

Read More:

Leave a Reply

Your email address will not be published. Required fields are marked *