dataquestio / loan-prediction Goto Github PK
View Code? Open in Web Editor NEWPredict which loans will be foreclosed on.
Predict which loans will be foreclosed on.
I am following your Machine learning project but get the following error when execute assemle.py. I know its index out of bound error but I cant figure out where?
python assemble.py
Traceback (most recent call last):
File "assemble.py", line 87, in
concatenate("Performance")
File "assemble.py", line 77, in concatenate
data = pd.read_csv(os.path.join(settings.DATA_DIR, f), sep="|", header=None, names=HEADERS[prefix], index_col=False)
File "/home/khan/anaconda3/envs/mllearn/lib/python3.6/site-packages/pandas/io/parsers.py", line 646, in parser_f
return _read(filepath_or_buffer, kwds)
File "/home/khan/anaconda3/envs/mllearn/lib/python3.6/site-packages/pandas/io/parsers.py", line 401, in _read
data = parser.read()
File "/home/khan/anaconda3/envs/mllearn/lib/python3.6/site-packages/pandas/io/parsers.py", line 939, in read
ret = self._engine.read(nrows)
File "/home/khan/anaconda3/envs/mllearn/lib/python3.6/site-packages/pandas/io/parsers.py", line 1508, in read
data = self._reader.read(nrows)
File "pandas/parser.pyx", line 848, in pandas.parser.TextReader.read (pandas/parser.c:10415)
File "pandas/parser.pyx", line 870, in pandas.parser.TextReader._read_low_memory (pandas/parser.c:10691)
File "pandas/parser.pyx", line 947, in pandas.parser.TextReader._read_rows (pandas/parser.c:11728)
File "pandas/parser.pyx", line 1023, in pandas.parser.TextReader._convert_column_data (pandas/parser.c:12805)
File "pandas/parser.pyx", line 1289, in pandas.parser.TextReader._get_column_name (pandas/parser.c:17512)
IndexError: list index out of range
Assembe.py was crashing when executing. Fixed the issue by changing the value of index_col=False to index_col=None when reading into pandas.
Like this:
data = pd.read_csv(os.path.join(settings.DATA_DIR, f), sep="|", header=None, names=HEADERS[pref
ix], index_col=None)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.