wsu-casas / al-smarthome Goto Github PK
View Code? Open in Web Editor NEWAL Activity Learning for the Smarthome
AL Activity Learning for the Smarthome
Hi! I tried to run the code but got some issues. Can you help me how to run the code. I am interested to work in this area.
Version:
Python: Python 3.7.1
Scikit-learn : 0.23.2
Numpy: 1.19.2
Joblib: 0.17.0
Run command:
python al.py --data data files data
I tried python al.py --data data also
The data file I'm using is the same file given in repository
Error:
Traceback (most recent call last):
File "al.py", line 566, in
main(sys.argv)
File "al.py", line 561, in main
train_model()
File "al.py", line 442, in train_model
cf.clf.fit(cf.data, cf.labels)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\ensemble_forest.py", line 304, in fit
accept_sparse="csc", dtype=DTYPE)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\base.py", line 432, in _validate_data
X, y = check_X_y(X, y, **check_params)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\utils\validation.py", line 72, in inner_f
return f(**kwargs)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\utils\validation.py", line 802, in check_X_y
estimator=estimator)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\utils\validation.py", line 72, in inner_f
return f(**kwargs)
File "C:\Users\hp.conda\envs\tensorflow_env\lib\site-packages\sklearn\utils\validation.py", line 623, in check_array
"if it contains a single sample.".format(array))
ValueError: Expected 2D array, got 1D array instead:
array=[].
Reshape your data either using array.reshape(-1, 1) if your data has a single feature or array.reshape(1, -1) if it contains a single sample.
The error showing the data needs to be in 2D format. How to do that? Please help.
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.